BleuLlama / TinyBasicPlus

A C implementation of Tiny Basic, with a focus on support for Arduino
401 stars 117 forks source link

ELIST failed when program is not loaded in EEPROM #47

Open ercanersoy opened 6 years ago

ercanersoy commented 6 years ago

ELIST failed when program is not loaded in EEPROM. This statement prints a lot of character. This problem occurs on non-format EEPROMs.

BleuLlama commented 6 years ago

I don't believe there's any good way to find out if eeprom is formatted.

Although, I could reserve the first one or two bytes of the EE for a sentinel of some kind. If it's 'T' 'B' or somesuch, I know it's programmed, and elist is ok to do, otherwise print an error.

A lot of the niceties like this do take space to add though, which we're trying to avoid doing in TB.... one of the reasons that we have lots of #ifdefs for configuration. ;)

Then again, you can just tap the reset button on your arduino and then eformat. problem solved. (or just save something. ;)