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

Support the NUCLEO-STM32F429ZI board. #1917

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

jonathanpallant
Copy link

On this new board, we get the user-led task to drive the LEDs via the stm32xx-sys task, like it did on the STM32H7 based boards.

This PR also updates the existing STM32F4-DISCOVERY support in the user-led task (which uses the STM32F407) to also use the stm32xx-sys task for driving LEDs. This leaves just the STM32F3-DISCOVERY using the direct-access approach.

The STM32 UART support also now understands both the F429 and F407, but I didn't yet hook up a terminal to see if it works.

The demo was tested on a NUCLEO-STM32F429ZI. Unfortunately I don't have a STM32F4-DISCOVERY to hand to check I didn't break anything there.

This was literally my first introduction to Hubris, so hopefully I got it all mostly right. The changes took about five hours, all told. Much of that was diagnosing the stm32xx-sys constantly restarting - it was because it didn't have permission to write to the GPIO address range.

Drives the LEDs through the stm32xx-sys task.
drv/stm32xx-gpio-common/src/server.rs Outdated Show resolved Hide resolved
Comment on lines +540 to +541
///////////////////////////////////////////////////////////////////////////////
// The STM32F4 specific bits.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Take it or leave it: I wonder if we might want to move the board-specific bits into submodules with #[cfg(feature = <board feature>] on them, instead of sticking a cfg attribute on each function and constant? We could do the same for the existing F3 stuff. The code might read a little nicer that way. But, it's up to you.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That sounds like a good follow-up PR. I just wanted to share what I'd done to make it run on the board I had.

Typo s/distinguish/distinguishes

Co-authored-by: Eliza Weisman <eliza@elizas.website>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants