EmotiBit / EmotiBit_FeatherWing

Firmware to run Emotibit with Adafruit feather M0 WiFi and Feather ESP32
MIT License
19 stars 8 forks source link

Add support for v6 #309

Open nitin710 opened 1 month ago

nitin710 commented 1 month ago

Describe the feature

nitin710 commented 1 month ago

Design

Questions

  1. Who should own the address information?

    • Option 1: We could add the second address in the EmotiBit_NCP class
      • by changing being to have a version input, .begin(*TwoWire, enum EmotiBItVersion), we can pass hte version from emotibit class on sensor init and set the correct address.
    • Option 2: We could create a new class LedController that stores this metadata. This class can have wrapper functions for all NCP deriver member_functions.
  2. If we are using a LedController class, should it initialize hw settings based on version sent by emotibit class?

    • Option 1: the LedController class can have the if() block on the emotibit version. But then, this controller class must be aware of the versionController class.
    • Option 2: If we don't want to create version based if blocks, then the hw information must come from the NVM. We would have to (1)change how the information is written on the NVM, (2)store sensor hw details and (3)grant the controller NVM access.

LedController class design

image