modm-io / modm-devices

Curated device data for all AVR and ARM Cortex-M devices
https://blog.salkinium.com/modm-devices
Mozilla Public License 2.0
49 stars 28 forks source link

STM32G4 #28

Closed rleh closed 4 years ago

rleh commented 5 years ago

~STM32G4 u(s)art has no tcbgt~

For the STM32G4 series only USART1/2/3 support TCBGT, UART4/5 and LPUART do not support it.

salkinium commented 5 years ago

You should check all of them with care, I did this best-effort only!

salkinium commented 5 years ago

Ready for merging? Or do you have more fixes?

rleh commented 5 years ago

I don't know what tcbgt means. It was introduced here: modm-io/modm@6cc4ac4316 Can you explain that?

I removed it because it fixed compilation errors.

Currently the modm-io/modm#287 builds successfully on CircleCI without this changes merged.

salkinium commented 5 years ago

The "tcbgt" feature refers to the availablility of the TCBGT bit in the USART_ ISR registers:

The feature descriptions in modm-devices only operate on a comparison of register maps, so that compatible subsets of one larger map can be distiguished. The SPI driver in modm uses this info much better than the UART driver.

rleh commented 5 years ago

STM32G4 Reference Manual (RM0440 Rev 1)

36.7.9 USART interrupt and status register [alternate] (USART_ISR)


grafik

salkinium commented 5 years ago

Ugh. #7 is coming to get me. All this data needs to become an order of magnitude better and there needs to be unit tests (or assumption tests) built into this repo.

salkinium commented 4 years ago

This can be closed, right?

rleh commented 4 years ago

Only UART1/2/3 have the TCBGT feature. This is currentyl not representable in modm-devices, see #7.