On 8/17/06, Harold Hallikainen wrote: > > >> I'm getting "System reset by" messages with nothing following, which > >> seems > >> to indicate that none of the bits in the RCON register were cleared by > >> the > >> reset, nor were the stack overflow or underflow bits set. > > > > How are you reading the message back? It looks like you'll have extra > > null characters. For example, in the event of a brownout: > > \r\nSystem reset by \0brownout, \0 > > > > So software that is expecting the C convention of null-terminated > > strings won't read the second part. > > > > > > THANKS for the several responses so far! I'll comment on them all here. > > First off, I wrote the PrintRomString() (or whatever I called it) before > MCC18 had a printf(). It just sends strings from flash to the uart > terminating on a null. I just cycled power to the unit and this is what I > get: > > 00> > System reset by brownout, power up, > OK, I guess it looked odd to me because C compilers give you a '\0' at the end of string constants anyway. But I an extra one won't hurt, except for code space. Regards, Mark markrages@gmail -- You think that it is a secret, but it never has been one. - fortune cookie -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist