-
-
Notifications
You must be signed in to change notification settings - Fork 32
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
Examples won't compile on ESP32 ? #13
Comments
I left this as a comment around its usage: // In avr/libraries/Wire.h and avr/libraries/utility/twi.h, BUFFER_LENGTH controls Since you're not using the AVR libraries (you're using ESP32) you'll probably have to self-define this. Still may be worth coding in a default to use in any case. |
Thank you for the hint, For me, I've added the marked (#) lines here in PCA9685.h |
Fixed on version 1.2.11. Pushed to master. No worries =). It was a good catch for an odd side case. Let me know if the new version helps or not. =) |
Runs fine now 'out of the box' also in the ESP32 environment. Good job and have a nice day. |
I'am using an ESP32 and want to use the setChannelsPWM to set 6 Servos at one I2C-write.
But the BatchingExample producing compile-errors:
no matching function for call to 'PCA9685::setChannelsPWM(int, int, word [12])'
and also other examples fail:
S:\arduino-1.8.10_ESP32\portable\sketchbook\libraries\PCA9685-Arduino\PCA9685.cpp:208:45: error: 'BUFFER_LENGTH' was not declared in this scope
int maxChannels = min(numChannels, (BUFFER_LENGTH - 1) / 4);
Any Idea ?
Edit:
By replacing "word pwms[12];" --> "uint16_t pwms[12];" in example the 1st error is gone :-)
Only the missing BUFFER_LENGTH remains in moment.
The text was updated successfully, but these errors were encountered: