envy / esp-knx-ip

A KNX/IP library for the ESP8266 with Arduino
MIT License
136 stars 49 forks source link

Don't store function pointers in EEPROM #1

Closed envy closed 7 years ago

envy commented 7 years ago

Instead of saving functions pointers in ga_callbacks, store the id of the callback. That way we need a second lookup inside __loop_knx but gain the ability to reuse the stored EEPROM config even if the code layout changes. Also we need to store less (8 bit vs pointer-type, so probably 32 bit).

Also define a callback_id_t type for callback ids.