You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Kaleidoscope/storage.cpp

17 lines
375 B

#include "storage.h"
void KeyboardStorage::save_primary_keymap(uint8_t keymap) {
EEPROM.write(EEPROM_KEYMAP_LOCATION, keymap);
}
uint8_t KeyboardStorage::load_primary_keymap() {
uint8_t keymap = EEPROM.read(EEPROM_KEYMAP_LOCATION);
if (keymap >= KEYMAPS ) {
return 0; // undefined positions get saved as 255
}
return 0; // return keymap;
}