Software progress

Just a quick update. I have some software now running. The basic system is operational on the MAX32630FTHR board communicating with all sensors and radio. SD-card logging is not yet implemented, nor is being able to mount the device as a remote USB storage device. It uses a number of mbed-os features including threads and event queues, as well as a bunch of libraries. I also have a very simple sketch on the Teensy-LC base station to communicate with the rocket. Communication appears as a serial channel and can occur either over the LoRa radio or the DAPlink debugger serial port. There is a simple command set to control the system.


In the picture, CoolTerm_0 is connected to the DAPlink debugger serial port and CoolTerm_1 is connected to the Teensy-LC. I typed "help" and "status" commands into CoolTerm_0 and turned on and off various sensor data streams in CoolTerm_1 using the "send" command. I am thinking that I will only "send gps on" during flight and record all other sensor data to the Micro-SD card.

I've run into a couple of issues so far (aside from own cluelessness). The MAX32630 implementation for the hardware SPI seems to require using only the three hardware slave select pins (as opposed to allowing software to control them using GPIO). One is brought out and available but the other two are double-mapped to the I2C bus. Since I need two slave selects (RF95 LoRa radio and MAX31865 temperature chip) and also the built-in I2C bus (BMI160 accel chip and PMIC chip) I had to implement a software (bit-banged) SPI implementation. I can get about 1 Mbps out of it. I also attempted to catch the RX Interrupt for the hardware serial port used by the debugger serial interface using the serial object's built-in attach function. Unfortunately that seems to hang the software whenever there is an incoming character. I haven't tried to debug that but instead put polling the debugger serial interface into its own thread which should be fine since it will be unused during flight (it's really only for debug).

Up next, a simple PC application to control and display data and also distance testing for the LoRa radio. I'm also going to replace the magnetic reed switch with a more robust type of switch because the more I think about it, the more nervous I get that acceleration or the parachute ejection might cause it to close which would reset the system (The power switch input is mapped to both reset and power-control on the PMIC).

Blog entry information

Last update

More entries in General

More entries from djdesigns

Share this entry