1
0
Fork 0
qmk_firmware/tmk_core/common/eeprom.h
yiancar 2bfac351ed Final HS60v2 changes. (#4790)
* initial commit, this now mostly works

- RGB controls work
- Dynamic keymap still broken due to eeprom
- Via works

* STM32 eeprom update

- Update EEPROM emulation library to handle 8bit data like AVR.
- This library also allows for multiple page pairs resulting in greater EEPROM size flexibility

* hs60 changes

* HS60 hhkb added

* Update keyboards/hs60/v2/config.h

Co-Authored-By: yiancar <yiangosyiangou@cytanet.com.cy>
2019-01-06 17:22:19 -08:00

23 lines
911 B
C

#ifndef TMK_CORE_COMMON_EEPROM_H_
#define TMK_CORE_COMMON_EEPROM_H_
#if defined(__AVR__)
#include <avr/eeprom.h>
#else
#include <stdint.h>
uint8_t eeprom_read_byte (const uint8_t *__p);
uint16_t eeprom_read_word (const uint16_t *__p);
uint32_t eeprom_read_dword (const uint32_t *__p);
void eeprom_read_block (void *__dst, const void *__src, uint32_t __n);
void eeprom_write_byte (uint8_t *__p, uint8_t __value);
void eeprom_write_word (uint16_t *__p, uint16_t __value);
void eeprom_write_dword (uint32_t *__p, uint32_t __value);
void eeprom_write_block (const void *__src, void *__dst, uint32_t __n);
void eeprom_update_byte (uint8_t *__p, uint8_t __value);
void eeprom_update_word (uint16_t *__p, uint16_t __value);
void eeprom_update_dword (uint32_t *__p, uint32_t __value);
void eeprom_update_block (const void *__src, void *__dst, uint32_t __n);
#endif
#endif /* TMK_CORE_COMMON_EEPROM_H_ */