2024-11-27 07:06 PM
Hi.
I have a project that involves using an STM32U535 to control the LEDs shown in the picture.
I feel it should be possible to control the COL-x signals with synchronized timers that also trigger DMA transfers to control the ROW-y signals, but I can't figure out how to go about doing that, can I have some help?
The picture also includes a rough sketch of the signal timing. I want each phase to be a different length to control the brightness and I think that dead time between phases might be nice to have.
2024-11-27 07:23 PM
It seems to be similar to 7-segment LED display. You may search internet for corresponding documents.
2024-11-27 11:53 PM
The simplest thing to start with is to use one single timer in which yellow is one channel in PWM1 mode, red other channel in PWM2, and green in Combined mode of two remaining channels.
You can of course pull it out also as a cascade of three timers in master-slave configuration, circularly, triggering each other, all in One-pulse mode. Dead time would be almost inevitable there.
Triggering DMA may be a another challenge in either case, depending on the details of implementation.
JW
2024-12-04 05:49 PM
Hi. I think the three timers in master-slave configuration will be easier to hook DMA into, but my main problem (which I should have been clearer about) is that I find the naming of the various options unintuitive and can't figure out how to set up my .ioc to do the things I want it to.
2024-12-04 08:39 PM
> I find the naming of the various options unintuitive and can't figure out how to set up my .ioc to do the things I want it to.
They don't need to be intuitive, whatever that would mean. They are described in the RM together with exact description of their functionality. CubeMX for whatever reason doesn't always match the nomenclature of RM, and its convenience also caters only for a miniscule subset of what the hardware allows - just the"typical" usage cases - so if you want anything beyond what can be easily clicked in CubeMX you may be better off simply by ignoring it and programming directly the registers.
JW