hydrabus / hydrafw

HydraBus HydraFW official firmware for open source multi-tool for anyone interested in learning/developping/debugging/hacking/Penetration Testing for basic or advanced embedded hardware
https://hydrabus.com/hydrabus-1-0-specifications
Apache License 2.0
362 stars 92 forks source link

[WIP] STM32F411CE (blackpill) port #159

Closed sarg closed 7 months ago

sarg commented 7 months ago

Hi there! I've got myself a Blackpill board which is based on the same STM32F4-family MCU. Given it's the same architecture, I thought it'll be easy to port hydrafw to this board. F411CE has lower speed (100Mhz) and less peripherals, so I had to adjust the code a bit to make it work. I've tested the firmware on the device and it works fine. I wasn't able to verify all modes, but UART, ADC, GPIO seem to work. flashrom recognizes the device as well, but I haven't yet read a flash chip over SPI, probably due to bad contact when using a test clip. debug timing command hangs the MCU, not sure what to make of it.

If you're willing to accept such addition to your project, we can work on cleaning this WIP branch and making the code open to run on other boards.

bvernoux commented 7 months ago

Thank you for your contribution, However, these modifications will cause issues with the HydraBus HW (lot of things are broken and will requires a better abstraction layer). Unfortunately, supporting BlackPill requires ownership and time investment, which I do not currently plan on doing due to its limitations compared to the dedicated HydraBus platform designed specifically for HydraFW.

sarg commented 7 months ago

Fair enough.

Check this commit though, it's just a small clean up of the existing code: https://github.com/hydrabus/hydrafw/pull/159/commits/d17cff9c2edbc315cc9f5521b793129970551823

bvernoux commented 7 months ago

Your project is very interesting anyway, if you want to maintain your own fork it is probably the best we could also add a link to it on the Wiki if you want... Other contribution to hydrafw are welcome of course

bvernoux commented 7 months ago

Fair enough.

Check this commit though, it's just a small clean up of the existing code: d17cff9

You are welcome to do a new PR with that cleanup to be merged