sparkfun / SparkFun_Qwiic_OLED_Arduino_Library

Arduino Library for SparkFun's OLED Qwiic (I²C) boards
https://docs.sparkfun.com/SparkFun_Qwiic_OLED_Arduino_Library/introduction/
Other
6 stars 7 forks source link

Add QwiicCustomOLED #12

Closed PaulZC closed 8 months ago

PaulZC commented 8 months ago

This release adds the QwiicCustomOLED class:

PaulZC commented 8 months ago

Sweet. Thanks!

gigapod commented 8 months ago

Thinking on this -- the one way to get around setting m_device public, is to create accessor methods on the device for the parameters needed. So QwOLEDCustom would have set[value] methods, which would stash the values in the instance data and use them on init. The QwiicCustomOLED class also implement the same methods and just call the same methods on m_device. ... In this case, m_device would need to be protected, not private.

PaulZC commented 8 months ago

Okie dokie. I'll get on this tomorrow! (I don't think we need to revert anything today. The changes and example work - and haven't been released. We can safely finesse them tomorrow.)

gigapod commented 8 months ago

Thanks Paul. In a way, this is just object oriented syntactical sugar :), but it's the correct way to proceed.