-
Notifications
You must be signed in to change notification settings - Fork 23
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
Use Write
trait in prerendered
module.
#23
Comments
On most mikrocontrollers, the HAL implementations wait for each byte to be received before sending the next one. This is a bit too slow for this code and thus leads to issues, which is why we deliberately introduce the offset using Does using the |
Yes, with |
Mmh, I think it may make more sense to split it into yet another module, since the long low time at the end (and possibly at the start) won't work as a separate call on all linux platforms, but it would take a lot of ram on MCUs to add it in the buffer. I think a separate backend based on Perhaps even with @reitermarkus Does that sound reasonable to you? |
Sorry to jump on this with a bit of a sidetrack, I've been trying to use ws-2812-spi with https://crates.io/crates/esp-idf-hal which lacks a FullDuplex implementation - would the |
@D1plo1d That could work, there might be various factors (slow transmit function, interrupts during sending) that mean it doesn't. The only way to find out is trying it. |
I had a similar issue on STM32F0 devices: FullDuplex is not implemented, however blocking::spi::Write and others are. I created a patch #28 that converts everything to write, however I am not sure if that has sideffects in other implementations. It does work on a STM32F030C8Tx and I would expect it to work on ESP and RPI (Those devices should be fast). Unsure what sideffects it would have on slower devices. Maybe creating a feature that chooses between fullduplex and write would help. |
Hi,
I had quite some difficulty getting this to work on a Raspberry Pi using
rppal
. I finally figured out it was becauseFullDuplex
is too slow since it sends every byte individually. Since theembedded_hal::blocking::spi::Write
trait allows sending a complete byte slice, it works well with the prerendered approach. Should theprerendered
module also use theWrite
trait?The text was updated successfully, but these errors were encountered: