Skip to content
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

Hardware STM32 SPI2 support for addressable LEDs #14

Open
technobly opened this issue Dec 31, 2019 · 3 comments
Open

Hardware STM32 SPI2 support for addressable LEDs #14

technobly opened this issue Dec 31, 2019 · 3 comments
Assignees
Labels
feature New feature request

Comments

@technobly
Copy link
Owner

Feature

Currently the addressable LEDs are bit-banged with software SPI. Ideally we'd like to support HW SPI2 so that we can do fancy things like DMA control of the LEDs. To enable that, we'll likely have to shuffle some pins around.

Notes:

  • Move V-HALT and V-CE to different pins and fix SDAT and SCLK so they are on SPI2 for hardware control.
  • V-CE might be optimized for MSB (seems like it is in romemu.S), so move to PA15 which bumps CSn to some other pin?
  • CSn should likely be on SPI1_SS, but it might not matter (check). PB01 is used in an optimized way as well though.
@technobly technobly added feature New feature request confirmed We have confirmed the issue and are tracking it for a fix labels Dec 31, 2019
@technobly technobly added this to the v0.3 milestone Dec 31, 2019
@technobly technobly self-assigned this Jan 3, 2020
@Alterac
Copy link

Alterac commented Mar 3, 2020

What about changing the part your using for RGB Leds to something simpler (and easy to source from lcsc) like the WS2812B and then you can use only 1 Pin, say PB8 - SPI5_MOSI to control them?

@technobly
Copy link
Owner Author

Thanks for the idea @Alterac! WS2812B/13's are very timing dependent... so these would not be as flexible and resilient as Clock&Data IMO, which can be done very slowly if necessary. We have tons of pins available... so it's just an exercise of juggling resources at this point. WS2812B/13's are quite large as well. I do agree on the sourcing issue though... there must be an easier/cheaper place to get these LEDs from than Digi-Key.

@Alterac
Copy link

Alterac commented Mar 3, 2020

The PCB has lots of room, so i wouldnt be too worried about that, but 10 RGB leds is still quite extravigant imho, I think 4 would be more than enough (but whatever, i can just not solder on the rest, hah). But the point about clocking them is much easyier since you dont need to babysit the timing code.

@technobly technobly removed this from the v0.3 milestone Sep 24, 2020
@technobly technobly removed the confirmed We have confirmed the issue and are tracking it for a fix label Sep 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature request
Projects
None yet
Development

No branches or pull requests

2 participants