EEprom help negative and decimal numbers?
grasshopper
Posts: 438
Has any one put a negative number in EEprom using the Bs2 object? Along with negative numbers I wish to use decimals too.
Comments
The Propeller doesn't normally do decimals even though the compiler can do floating point constant expressions. All arithmetic is integer. If you use the floating point library from the Object Exchange, then you can use floating point arithmetic on variables using the methods in the library. These are just 32 bit values. As long as you read/write long values (4 bytes), the floating point values in the longs can be written and read back from EEPROM.