Ok, so I have a structure variable "EPD" declared before setup, so that should make it a global variable should it not ?
// Create the EEPROM data structure
struct udt_EPD {
unsigned long eeprom_writes;
uint16_t cal_min;
uint16_t cal_max;
uint8_t minutes_run;
unsigned long hours_run;
uint8_t id; // this is last to catch structure changes
};
//Create the EEPROM data of type udt_EPD
udt_EPD EPD;
// **********************************************************************
void setup()
{
This from the help - " any variable declared outside of a function (e.g. setup(), loop(), etc. ), is a global variable."
now I've written a function to update the contents of the EEPROM, and it automatically increments the number of writes member before writing the EEPROM data, this function follows the end of void loop() ...
void update_EPD()
(
EPD.eeprom_writes++;
EEPROM.put(EPA, EPD);
}
I'm confused why I'm getting "update_EPD" was not declared in this scope" errors whenever I call the function.
pRojeCt_Compressor_Nano:168:5: error: 'update_EPD' was not declared in this scope
update_EPD();
^~~~~~~~~~
Similar topics have not been helpful.... so far ...
Any help would be appreciated...