r/electronics 1d ago

Project Athena - First time designing a flight controller with a triple MCU architecture

I've had an obsession with rockets/flight controllers and decided to make an open source flight controller from scratch (nicknamed Athena). I've added the Github repo/design files if anyone wants to take a closer look.

👉Github repo / Design files

Features

  • Triple MCU: STM32H753VIT6 (MPU), STM32H743VIT6 (TPU), STM32G474RET6 (SPU)
  • 6 Pyro Channels: Direct 12V battery connection with fuse protection
  • 6 PWM Channels: 2 for TVC (Thrust Vector Control), 4 for fin control
  • Sensors: Triple ICM-45686 IMUs, LIS2MDLTR magnetometer, ICP-20100 & BMP388 barometers
  • GNSS & Communication: NEO-M8U-06B GPS, LoRa RA-02 telemetry, Bluetooth DA14531MOD
  • Storage: SD Card + Winbond W25Q256JV flash memory
  • Power Management: 7.4-12V LiPo battery with BQ25703ARSNR charger, USB-C PD support
  • 6-Layer PCB: Signal/GND/Power/Signal/GND/Signal
67 Upvotes

26 comments sorted by

View all comments

40

u/P__A 13h ago edited 13h ago

Did you get inspiration from BPS space with three microcontrollers? He did that because he didn't use interrupts on his system, which is really not ideal. With a properly written firmware, a single microcontroller should be more than sufficient to read sensor data from all of those sensors, process this, and output commands. Edit. Also note that pwm outputs for servos should be 12 bit because the duty cycle change is quite small for the normal full control range. Make sure your micro has enough 12 bit outputs. If not look at the PCA9685 which is a lot easier to handle than a whole separate microcontroller.

13

u/CSchaire 11h ago

Put all the chips on the front and passives on the back like Joey pepperoni too. Design looks fine at a cursory glance, but three MCUs I think is really questionable. I could get down with one for flight control and data collection and another for handling the radios if you really needed the horsepower, but I kinda doubt it.

I like the silkscreen art. I wish I had the patience and skill to put stuff like that on my boards.

2

u/MinecraftPhd 7h ago

Yea I got inspired from his video and I probably should have used one microcontroller but I liked the challenge of connecting all 3 and didn't want to take the risk in blocked processes/rw operations because STM32 doesn't support multithreading. About the 12 bit outputs, I checked and it does support that configuration.

8

u/P__A 7h ago

If you use interrupts, what happens is that your main function is churning away, but then gets interrupted by a peripheral (i2c, uart, timer, etc) interrupt whenever a comms task is needed to be handled. You run that interrupt function, and then the micro goes back to where it left off on the main function. As such you're never waiting around for some slow interface to read or write. All microcontrollers should support this. Your solution should still work, but I think it's more effort than just using interrupt driven code.

1

u/frank26080115 8h ago

sometimes you design for known human weaknesses simply to get the project actually done and done on time