-
Notifications
You must be signed in to change notification settings - Fork 33
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
Address up to 256 LED per channel #2
base: pro
Are you sure you want to change the base?
Conversation
128 LED push the memory limits of the t85, so have removed a few globals where possible
This allows the device to address twice as many LED. Useful for large number of LED where the device would otherwise run out of memory
@@ -48,6 +48,8 @@ void ws2812_setleds_pin(struct cRGB *ledarray, uint16_t number_of_leds,uint8_t p | |||
|
|||
void ws2812_sendarray (uint8_t *array,uint16_t length); | |||
void ws2812_sendarray_mask(uint8_t *array,uint16_t length, uint8_t pinmask); | |||
void ws2812_sendarraylow_mask(uint8_t *array,uint16_t length, uint8_t pinmask); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple variants of the sendarray function to send low and high 4 bits
main.cpp
Outdated
'\x96', '\x81', '\x01', // REPORT_COUNT (385) | ||
'\x09', '\x00', // USAGE (Undefined) | ||
'\xb2', '\x02', '\x01', // FEATURE (Data,Var,Abs,Buf) | ||
'\xc0' // END_COLLECTION |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes c+11 warnings and adds report_id 10
Thanks for submitting this! I will give it a go and run tests on my rig. What OS have you been testing this on? |
I've mainly been testing on a Raspberry PI using the Python API. I can send a PR with my changes to the Python API. I've got a WS2812 strip with 300 LED and it's controlling up to 256 nicely. For the 12 bit mode I've only tried it with reports 6-10. Not sure it will work well with report 5. I did find that compiling the firmware using the avr-gcc (4.8.1) that is available in the raspbian repos doesn't work the best. It works, but the device seems a bit flaky and I see some errors from the driver under dmesg. I get good results compiling with the avr-gcc (4.9.2) from the Atmel website on Windows or Linux. I get that same flaky behavior with the unmodified pro firmware too, so it seems related to the compiler version and not my changes. |
Report 20 allows setting the repeat on the frame. Default is one
Not sure if this is of interest to you, but I've adapted the pro firmware to support up to 256 LED on a single strip. I added two features to accomplish this:
I've also adapted the python api to support these features and can submit a PR if you like. The updated firmware should be backwards compatible with old API code since it only adds new modes. I tested this on a BS-pro that I built as well as a Flex I bought from you.