Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove redundant libraries (FirebaseJson and Crypto) #958

Merged
merged 2 commits into from
May 6, 2024

Commits on May 5, 2024

  1. remove FirebaseJson lib from firmware (save 17.5k of flash)

    we used this library solely to interpret the answer of an HTTP web
    server as JSON and find a particular value using a path expression in
    the HTTP power meter implementation.
    
    since we ran out of flash memory on non-S3 ESP32, we need to cut some
    corners. removing FirebaseJson is the last low-hanging fruit that we
    currently know of. we can get rid of it by using ArduinoJson (which is
    already integral part of the firmware) and implementing a custom logic
    to extract a value based on a path expression.
    
    other than the FirebaseJson path "finder", the new implementation
    only knows how to access sub-keys delimited by a forward slash. in
    particular, accessing array members is not supported any more. I am
    hoping that this is simply not an issue. if so, we will have users
    complaining and we can add this functionality in a later release.
    schlimmchen committed May 5, 2024
    Configuration menu
    Copy the full SHA
    6746455 View commit details
    Browse the repository at this point in the history
  2. remove rweather/Crypt lib from firmware (save 2.1k of flash)

    mbedtls is already integral part of the firmware. use it in favor of
    rweather/Crypto library to calculate a sha256 checksum of a string, as
    used in the HTTP power meter implementation.
    schlimmchen committed May 5, 2024
    Configuration menu
    Copy the full SHA
    638f636 View commit details
    Browse the repository at this point in the history