sensor read enhanced, writes to eeprom enhanced, defines cleared up a bit, debug cleared up a bit