thorrak / tiltbridge

Tilt Hydrometer to WiFi Bridge
http://www.tiltbridge.com/
Other
61 stars 27 forks source link

Modify parsing of load_tilt_from_advert_hex function #35

Closed pletch closed 3 years ago

pletch commented 3 years ago

These changes modify the load_tilt_from_advert_hex function to eliminate use of NimBLEUtils::buildHexData.

As an alternative, the advert_hex_string is directly iterated to place the color,temperature, and sp gravity data into char arrays.

These changes appear to reduce heap thrashing when monitored via debugging output from esp_get_free_heap_size().