adafruit / Adafruit-PWM-Servo-Driver-Library

Adafruit PWM Servo Driver Library
Other
477 stars 311 forks source link

Fix getPWM method and overload getPWM in header #84

Closed driscollta closed 1 year ago

driscollta commented 3 years ago

This merge will fix broken getPWM method to actually read two bytes from PWM register, combine into 16 bit value and return. A parameter is needed to specify either the "ON" or "OFF" registers

An example is provided to test the new getPWM method by writing a value to the register, reading back and comparing the two values.

ladyada commented 3 years ago

hi please remove the main.cpp file (or you can rename it to a valid arduino example)

driscollta commented 3 years ago

Changed example name to testGetPWM.ino

driscollta commented 3 years ago

Changed main.cpp to testGetPWM.ino

On Wed, Feb 17, 2021, 7:24 AM ladyada notifications@github.com wrote:

hi please remove the main.cpp file

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/adafruit/Adafruit-PWM-Servo-Driver-Library/pull/84#issuecomment-780631118, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACSALE3TD4KXBR7XQFCCS2LS7PNSJANCNFSM4XXL5OLA .

ladyada commented 3 years ago

the eample has to go in a folder with the same name like all other examples

ladyada commented 3 years ago

ok now you need to run clang-format

caternuson commented 1 year ago

Closing. I think this was fixed as part of BusIO update. See #56 for more discussion.