Fix bug with eeprom code - wrong address for brightness
This commit is contained in:
parent
a25262ad5f
commit
7a0ff89c28
|
@ -224,7 +224,7 @@ void dmenu_loop() {
|
|||
}
|
||||
brightness = 10 * cursor;
|
||||
M5.Axp.ScreenBreath(brightness);
|
||||
EEPROM.write(3, brightness);
|
||||
EEPROM.write(2, brightness);
|
||||
EEPROM.commit();
|
||||
rstOverride = false;
|
||||
isSwitching = true;
|
||||
|
@ -839,7 +839,10 @@ void setup() {
|
|||
//EEPROM.write(0, 255);
|
||||
//EEPROM.write(1, 255);
|
||||
//EEPROM.write(2, 255);
|
||||
EEPROM.commit();
|
||||
//EEPROM.commit();
|
||||
Serial.printf("EEPROM 0: %d\n", EEPROM.read(0));
|
||||
Serial.printf("EEPROM 1: %d\n", EEPROM.read(1));
|
||||
Serial.printf("EEPROM 2: %d\n", EEPROM.read(2));
|
||||
if(EEPROM.read(0) <= 3){
|
||||
rotation = EEPROM.read(0);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue