G
Guy Macon
Guest
Ken Smith wrote:
I think I can do even better.
Fill memory with instructions that XOR a preloaded random values
into the accumulator then outputs the result (or XORs the preloaded
random value with the context of the output port if the chip allows).
Tweak a bit here and a bit there so that each time it goes through
the loop the accumulator is Decimal 149 / Hex 95 / Binary 10010101
larger (with overflow modulo 256). 149 is a prime, so it won't
repeat until the 256th loop.
Here are the first 8 values that will be XORed into the results
on the first 8 loops through memory:
10010101
00101010
10111111
01010100
11101001
01111110
00010011
10111011
(This is all off the top of my head, so forgive me if I made an error.)
That's a nice trick!In article <10pdphldufn0mb0@corp.supernews.com>,
Guy Macon <http://www.guymacon.com> wrote:
[...]
I had just hit send when it occured to me that your application is
a perfect match for filling all of memory with output instructions,
each putting out a pre-chosen random number.
This sort of idea works quite well. I've used it. There is a little
trick that makes the sequence even longer. If instead of simply
outputting the value from the memory, the values are used in a running
sum the sequence length can be at least doubled.
I think I can do even better.
Fill memory with instructions that XOR a preloaded random values
into the accumulator then outputs the result (or XORs the preloaded
random value with the context of the output port if the chip allows).
Tweak a bit here and a bit there so that each time it goes through
the loop the accumulator is Decimal 149 / Hex 95 / Binary 10010101
larger (with overflow modulo 256). 149 is a prime, so it won't
repeat until the 256th loop.
Here are the first 8 values that will be XORed into the results
on the first 8 loops through memory:
10010101
00101010
10111111
01010100
11101001
01111110
00010011
10111011
(This is all off the top of my head, so forgive me if I made an error.)