Mike Singer wrote: >> ...What I thought was the special trick is to use a >> 3-byte counter, write only changed cells back, and move the counter over >> only by 1 byte once the lifetime is over (because it's only the lowest byte >> that gets written on every count, the higher bytes get written considerably >> less often and can be re-used for the next counter position). > > There is exact number for "considerably less often", ... Yes, there is -- I just thought this was enough to get started :) > ... it's 256 for the next byte. This would be if you use a 2-byte counter and only write 65k events to the counter. If you use a 3-byte counter and write 100k events, the number is higher than 256: you write 1 time to it while it's the 3rd byte of counter N and 390 times while it's the 2nd byte of counter N+1. > Not that much if we are talking about getting tens of millions out of > 100K device. Not sure where the tens of millions come in, but the whole deal was to not pass 100k writes for one byte. Which, after what I've read about EEPROM endurance, is not good enough if you really want to go safe. Gerhard -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist