Skip to content

Implement pins_v2.zig for stm32f429 and extend support for stm32l479#939

Open
JAicewizard wants to merge 9 commits intoZigEmbeddedGroup:mainfrom
JAicewizard:main
Open

Implement pins_v2.zig for stm32f429 and extend support for stm32l479#939
JAicewizard wants to merge 9 commits intoZigEmbeddedGroup:mainfrom
JAicewizard:main

Conversation

@JAicewizard
Copy link
Copy Markdown

@JAicewizard JAicewizard commented Apr 27, 2026

fixes #938

This mostly makes comon/pins_v2.zig generic to the number of GPIO ports available on a chip.

I have looked into other methods, like having a function that determins the number of ports in pins_v2.zig itself, but found that it was very cumbersome to implement and it would be easier to pass it down when importing. Since the only files importing this are from microzig itself, this seems like a reasonable option.

JAicewizard and others added 8 commits April 27, 2026 16:32
They were tightly coupled together, but had different types for the same
concept. This introduced unneeded enum casts from and to int, and added
complexity.
Previously pins_v2 was only available on the F303 and L47x, and only
implemented for 7 GPIO ports on the later.

This makes the pins api available to any number of pins (soft limited to
11 due to comptime LUT size). Importer can provide the available number
of ports.

This also makes the api available for stm32f429
@JAicewizard JAicewizard changed the title Enable (and fix) hal for stm32f429 DISC1 board Implement pins_v2.zig for stm32f429 and extend support for stm32l479 Apr 29, 2026
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.

microzig.hal is void for stm32f429idiscovery

1 participant