[PLUG] Arduino issue

Neal nsedell at gmail.com
Sun Sep 25 05:09:35 UTC 2016


OS? Language? SD card access library? Version numbers? :-)

It's been too long since I Arduio-anything'ed to have any specific hints up
my sleeve regarding environment etc. I'll take a stab or two from a
hardware point of view. I have no clue as to what SD card read/erase/write
cycle times might be, so some of the following may not apply.

Is it at all possible you (or another thread) is polling the RTC or
servicing RTC interrupts while the read/modify/write is occurring? Assuming
the RTC is also an SPI device it might disrupt the SD card update
operation, likely made up of discrete read + modify/erase + write
operations. This will typically take on the order of milliseconds, at least
with "classic" SPI/I2C EEPROM/NVRAM chips.

Even if it worked as-is I'd strongly suggest keeping the string in RAM, and
only write a copy of it to the SD card after each update. Take proper care
to re-init the RAM copy from SD card at start-up, etc.

NealS



More information about the PLUG mailing list