This commit is contained in:
e2002
2022-08-02 11:45:22 +03:00
parent d4b5771005
commit 2aa2fe3dda
7 changed files with 32 additions and 13 deletions

View File

@@ -98,13 +98,13 @@ void Config::saveIR(){
}
#endif
byte Config::setVolume(byte val, bool dosave) {
void Config::saveVolume(){
EEPROM.write(EEPROM_START + sizeof(store.config_set), store.volume);
EEPROM.commit();
}
byte Config::setVolume(byte val) {
store.volume = val;
if (dosave) {
//save();
EEPROM.write(EEPROM_START + sizeof(store.config_set), store.volume);
EEPROM.commit();
}
return store.volume;
}