Skip to content

Science Controller STM

Guthrie edited this page Oct 6, 2023 · 5 revisions

Context

The science system, which is designed for the science mission at URC, uses sensors, heaters, LEDs (think what is inside of ISH system). We want to control all of these with one STM chip on a science PCB.

Look at the following diagram to get an idea of how this PCB fits in with the rest of hardware and software: ESW System 2024 drawio

Take a look at last year's code. Notice how the code continuously updates sensor values inside of the while(1) loop in main. This version also uses a UART "bridge" to communicate with the Jetson.

Problem

ISH is iterating their system, and want to use different components, which we have to write code for.

Solution

  • Develop STM32 software (firmware) using the CubeIDE in C
  • The firmware should be able to receive CAN messages and process them
  • The CAN messages should be consistent with whatever the corresponding ROS program is sending (see the Science ROS project)
  • The CAN messages interface should be defined
  • The firmware should be able to communicate with sensors, LEDs, and servos (hardware specifics are defined by ISH)

Interfaces

  • For sensors: STM32 chip should read in and update values constantly, and send them to the Jetson when requested via CAN
  • For other actions, the STM32 chip should be able to process commands for LEDs, and states for heaters

Getting started

  • Review code from last year's science system
  • Start with the interface between the STM32 and the sensors (spectral and thermistor), LEDs, heaters
  • Add in the CAN communication (this has not been finalized yet)
Clone this wiki locally