Make functions static, save 270B of flash.

This commit is contained in:
Marek Bel 2018-08-03 14:44:56 +02:00
parent bd907aec86
commit f7f4ba2512

View File

@ -14,7 +14,7 @@
#else //DEBUG_EEPROM_WRITE #else //DEBUG_EEPROM_WRITE
#define EEPROM_WRITE_VAR(pos, value) _EEPROM_writeData(pos, (uint8_t*)&value, sizeof(value), 0) #define EEPROM_WRITE_VAR(pos, value) _EEPROM_writeData(pos, (uint8_t*)&value, sizeof(value), 0)
#endif //DEBUG_EEPROM_WRITE #endif //DEBUG_EEPROM_WRITE
void _EEPROM_writeData(int &pos, uint8_t* value, uint8_t size, char* name) static void _EEPROM_writeData(int &pos, uint8_t* value, uint8_t size, char* name)
{ {
#ifdef DEBUG_EEPROM_WRITE #ifdef DEBUG_EEPROM_WRITE
printf_P(PSTR("EEPROM_WRITE_VAR addr=0x%04x size=0x%02hhx name=%s\n"), pos, size, name); printf_P(PSTR("EEPROM_WRITE_VAR addr=0x%04x size=0x%02hhx name=%s\n"), pos, size, name);
@ -42,7 +42,7 @@ void _EEPROM_writeData(int &pos, uint8_t* value, uint8_t size, char* name)
#else //DEBUG_EEPROM_READ #else //DEBUG_EEPROM_READ
#define EEPROM_READ_VAR(pos, value) _EEPROM_readData(pos, (uint8_t*)&value, sizeof(value), 0) #define EEPROM_READ_VAR(pos, value) _EEPROM_readData(pos, (uint8_t*)&value, sizeof(value), 0)
#endif //DEBUG_EEPROM_READ #endif //DEBUG_EEPROM_READ
void _EEPROM_readData(int &pos, uint8_t* value, uint8_t size, char* name) static void _EEPROM_readData(int &pos, uint8_t* value, uint8_t size, char* name)
{ {
#ifdef DEBUG_EEPROM_READ #ifdef DEBUG_EEPROM_READ
printf_P(PSTR("EEPROM_READ_VAR addr=0x%04x size=0x%02hhx name=%s\n"), pos, size, name); printf_P(PSTR("EEPROM_READ_VAR addr=0x%04x size=0x%02hhx name=%s\n"), pos, size, name);