David-OConnor / stm32-hal

This library provides access to STM32 peripherals in Rust.
MIT License
147 stars 44 forks source link

CAN read_status() support for fdCAN and bxCAN #98

Closed revilo196 closed 5 months ago

revilo196 commented 5 months ago

Here just a quick idea for a fix for my issue #97

the bxCAN hardware uses a different status register maybe its just as easy as to check for the feature and use MSR instead.

bxCAN has the following status registers. msr master status register

just tested it with my L431. Where I did build a 4.7Kb custom CAN-Bootloader.

David-OConnor commented 5 months ago

Great stuff! I use the FDCAN functionality alot on H7 and G4, but have never used the BxCan. LMK if it works?