Re: POST(Power On Self Test)

"Paul G. Tobey [eMVP]" <p space tobey no spam AT no instrument no
spam DOT com> wrote in news:eJ5WaMBJJHA.468@xxxxxxxxxxxxxxxxxxxx:

It's pretty hardware-dependent, as I said, generally. You might
need to know how much RAM there is or actually change RAM control
registers to find out. Whipping up something to step through a
given size range of addresses and write a pattern to all the
locations, then read back through and make sure they're all
correct shouldn't take more than five minutes to write. You could
do that right after entry to your bootloader.

unsigned char *p = 0x00000000;
unsigned long i;
for ( i = 0; i < 0x10000000; i++ )
*(p+i) = <pattern>;
if ( *(p+i) != <pattern> )
// You have a RAM failure. Indicate somehow (flash an LED

It's better to test with two patterns (0xAA,0x55 for example) to check
that each bit can change its state.
And maybe it's also better to do all the writes and after that the
reads (ensuring also that you disabled the cache).

Valter Minute
Training, support and development for Windows CE
(the reply address of this message is invalid)