Skip to content

osu-asdt/mark-1b

Repository files navigation

Mark 1B Hardware

The ASDT/Icarus Mark 1B is a small rocketry flight computer and tracker. It is dual-deploy and airstart capable, with advanced sensors and a high-quality GPS chipset coupled with a powerful wifi- and bluetooth-capable microcontroller.

Features

  • 4 pyro channels with continuity detection and short circuit protection
  • Wide 3.3-15V input range
  • Long-range LoRa radio on the license-free 915 MHz band
  • High-quality GPS
  • Accelerometer and gyroscope up to 200 G
  • Buzzer and five RGB LEDs for status indication
  • USB-C for data transfer
  • Wi-Fi/bluetooth connectivity
  • Expansion headers

Design goals

  • At least 4 pyro channels, with enough current for ignitors
  • Full sensor suite
  • High-power radio
  • Small form factor
  • Run on a 1S lipo battery
  • User friendly
    • No common pins for pyro
    • Reverse polarity protection
    • Easy communication (USB/wifi/bluetooth)
  • Long battery life on the pad and after landing
  • Expandable
  • Sub $100 total cost

Specifications

  • +22 dBm LoRa radio
  • Advanced u-blox GPS reciever
  • +/- 200G, +/- 2000 deg/s accelerometer/gyro range
  • Barometer (standard range -2300-30000 ft ASL, extended range -20000-85000 ft)
  • Magnetometer
  • Buzzer
  • 5x RGB LED (one for each pyro channel + one for status)
  • USB-C
  • 16 MiB of storage for logging
  • Sleep mode consumption should be <100 uA (not yet tested)
  • Mostly JLCPCB assembleable

Parts used

  • ESP32-S3 microcontroller
  • SX1262 radio
  • u-blox MAX-M10S GPS/GLONASS/galileo/BeiDou/QZSS reciever
  • BMI088 low-G IMU (+/- 24G, +/- 2000 deg/s)
  • ADXL375 high-G accelerometer (+/- 200G)
  • MS5607 barometer
  • LIS2MDL magnetometer
  • TPS259470ARPW current limiter for pyro

Detailed design explanation

Microcontroller

The Mark 1B uses an ESP32-S3 microcontroller. ESP32-S3 was chosen for its low sleep power consumption, small form factor, support for Wi-Fi/bluetooth (useful for user configuration), and easy programmability through USB. The microcontroller schematic is near-verbatim from the reference schematic, though the parallel resistor is omitted from the RTC crystal (it was validated on a previous revision) and the antenna matching is entirely absent (good Wi-Fi/bluetooth performance is not needed). Every single pin is used, either for peripherals or for expansion, with the sole exception of SPICS1. The previous revision of the board used ESP32-S3-FH4R2, which incorporates 2 MiB of PSRAM and 4 MiB of flash in-package, but the PSRAM was not needed and the small flash size was limiting. For this reason, this revision uses the base ESP32-S3 with no internal PSRAM or flash, and includes a W25Q128JVS flash chip. This flash chip is cheap and readily available (a basic part at JLCPCB!), known to work with ESP32-S3, and has quadruple the capacity of the previous version. If PSRAM is needed, ESP32-S3R2 can be used, because the included 2 MiB of PSRAM shares pins with the flash (the larger PSRAM variants use octal SPI, and those pins are in use). If more flash is needed, the W25Q256JVS can be used, though it requires extra configuration on the ESP32.

ESP32-S3 includes a powerful GPIO mux, so pins can be chosen for convenient positioning. The only pins that needed special consideration are the ADC pins (pyro sense and battery voltage input), the pyro control pins, and the accelerometer interrupts. The ADC inputs were chosen to be on GPIOs 1-10, because this corresponds to ADC1, which is usable while Wi-Fi/bluetooth is running (unlike ADC2). The pyro control and arming pins were chosen to not have high-level glitches on startup (see ESP32-S3 series datasheet, table 2-2), because these would potentially fire the connected charges. They were additionally selected from the RTC IO bank (GPIOs 0-21), because these pins can be held low in sleep. The accelerometer interrupts were chosen to be RTC GPIOs as well, because these can be set as a wakeup source from deep sleep (see ESP32-S3 technical reference manual table 10.4-3, note 2). This is done because the computer could be configured to go into deep sleep mode until launch is detected through an accelerometer interrupt, which would allow it to sit on the pad before launch for long periods without draining the battery much.

The JTAG interface is pinned out to a standard 2x5 pin 1.27mm pitch connector. Because the chip supports JTAG over USB, this is not expected to be used as JTAG unless something is terribly wrong, but it does make a usable expansion header, because the JTAG pins can be reconfigured as GPIO. There are thus four usable GPIOs on this header, enough to run four wire SPI.

The 32.768 kHz crystal was used because ESP32-S3 is known to have high clock drift in deep sleep mode, and accurate wakeup times could be useful for some radio protocols. The specific crystal (Q13FC13500004) was chosen because it is a basic part at JLCPCB. For additional timing accuracy, the GPS timepulse pin is connected to GPIO47, which can be used to set the system clock with an interrupt.

Power

A TI TPS62162 step-down converter is used. This converter was chosen for its acceptable output current (1A), low cost, small form factor, and low quiescent current. The design is identical to the reference schematic, and the inductor is from the list of recommended parts. This combination was validated on the Mark 1. The power good pin is connected to the microcontroller reset line. PG is pulled low when the voltage is below usable levels, which means the reset RC circuit probably doesn't need tuning for the microcontroller to work reliably.

The Mark 1B features reverse polarity protection on the battery connector, using a single P channel MOSFET and a pulldown. Because the MOSFET's gate is pulled down, the gate voltage could be up to 15V, so care was taken to select a MOSFET that can tolerate this, the 15V drain-source voltage, supports high (>4A) current, and has an acceptably low on resistance even at ~3.3V gate voltage. AOSS21311C was chosen, which can switch 4.3A and has reasonable on resistance (85 milliohm at 3.3V). The circuit is taken from typical Adafruit feather boards (ones without charging circuitry). This circuit also cuts off the battery if the USB is higher voltage than the battery, preventing overcharging. Additionally, a schottkey diode is used to prevent high battery voltages from damaging connected USB devices.

The power for the pyro MOSFETs is not switched through the reverse polarity protection circuit, because the current limiting chip is reverse polarity protected.

Indication

Five individually addressable BB-2020BGR-TRB RGB LEDs are used for status indication, one per pyro channel to show continuity, plus one for general status. These LEDs, while rated for 5V, have been tested to work at 3.3V. It is not clear how much current these LEDs consume in sleep mode, so a cuttable solder jumper is included in case it is found to be excessive. These LEDs use effectively a SPI interface, but lack a chip select pin. A TI SN74LVC1G125DCK non-inverting buffer is used to gate the clock to the LEDs when the 'chip select' pin is high. This saves a pin, and allows the SPI2 interface to be reused (freeing up SPI3 for communication with an expansion board). The LEDs are designed to operate at up to a 10 MHz clock, so they should work fine at the 5 MHz this bus is limited to, even at 3.3V.

A small magnetic buzzer is also included, closely mirroring its reference schematic, and controlled by one of the same MOSFETs used in the pyro circuitry.

Sensors

The Mark 1B includes four sensors: the BMI088 low-G accelerometer and gyroscope, the ADXL375 high-G accelerometer, the MS5607 barometer, and the LIS2MDL magnetometer. The BMI088 is highly accurate in its +/- 24G range, and is relatively inexpensive. It is connected over SPI according to its reference schematic. Only one accelerometer interrupt is connected, which as mentioned in the microcontroller section, could be used to wake the computer on launch. The ADXL375 is included because many rockets exceed 24G. It is much less accurate at low G loads, and lacks a gyroscope, hence the inclusion of the BMI088 as well. It similarly is connected over SPI, and has a single interrupt connected as well. The datasheet includes a note about SPI messages being interpreted as I2C, and it recommends an OR gate to hold the data line high when CS is high. Several other flight computers using the ADXL375 omit this, and the SPI bus will be run at several megahertz, which will hopefully keep the commands from being misinterpreted. The MS5607 is commonly used in rocketry due to its very wide extended pressure range: down to 10 millibars (though at questionable accuracy). It is connected over I2C. The LIS2MDL magnetometer is connected exactly according to the datasheet, in 4 line SPI mode.

The BMI088 is placed close to a mounting hole, because its measurements are highly sensitive to vibration. The ADXL375, being less sensitive, is placed further away.

GPS

The Mark 1B uses a u-blox MAX-M10S GPS reciever, a Murata SAFEA1G58KA0F00R15 SAW filter, and a Quectel YG0043AA ceramic patch antenna. The previous version of the board used a u-blox SAM-M10Q, which has an integrated antenna of similar gain. This version switches to the standalone reciever + antenna to save about $8 per board, or more in quantity, and to add the filter. The filter was added because the reciver requires below -17 dBm of 915 MHz radio power to perform optimally. An application note gives sample attenuation values for antenna selectivity and distance (10 dB for distance/orientation and 4 dB for antenna selectivity), which at the +22 dBm transmission level lies far above -17 dBm. The integration manual recommends adding a SAW filter in front of the GPS input in this situation. The SAFEA1G58KA0F00 was chosen because it is assembleable by JLCPCB and only attenuates the GNSS signals by 1.3 dB typically. The filter attenuates the 915 MHz signal by at least 32 dB, which leaves the final 915 MHz power reaching the reciver at -24 dBm using the earlier assumptions, well below -17 dBm. The reciever is otherwise connected according to the reference design, in I2C mode for faster communication. EXTINT is connected to the microcontroller so that it can wake up the reciver after putting it into sleep mode if needed. The antenna trace is a 50 ohm line, calculated on JLCPCB's website for their standard 1.6mm stackup. The area directly underneath the GPS antenna is almost fully intact groundplane.

Rocket avionics bays are sometimes poor environments for GPS, often including metal rods. Sometimes the GPS antenna faces into a metal launch rail, and interferrence from other radios is commonplace. Slow time-to-first-fix is a common cause of scrubs for high-performance flights, and sometimes it even leads to flights without functional tracking. For these reasons, GPS assistance should be provided to the reciver to improve its sensitivity and speed up its first fix. This is largely the job of the software, but due to its close coupling with the hardware it bears discussing here. The reciver benefits from knowledge of satellite orbits (long term 'alamanac' and short term 'ephemeris' information), which can be downloaded from an identical UBX-M10050-KB chip in a groundstation, then uploaded to the reciever. It can also be downloaded from NASA and reprocessed into the format the reciever expects. This data should also be downloaded and reuploaded whenever a power loss is expected, because the hardware does not incorporate a power supply for the reciver's backup domain. The reciver benefits from accurate knowledge of the current time, provided over I2C with an optional pulse at EXTINT for higher accuracy. This too can be sent over radio from the groundstation's GPS. Finally, the reciver benefits from a rough estimate of its position. This can be provided from the groundstation's position, but caution must be taken here. The groundstation and flight computer may not be near each other, and incorrect position information can be worse than no information at all. The maximum distance can be roughly bounded by the radio range, so the maximum radio range (and then a little more) should be provided to the GPS reciver as the accuracy of the initial position.

Radio

A Semtech SX1262 radio is used for the downlink. The SX1262 is capable of high output power (+22 dBm, around 160 mW) in the unlicensed 868/900 MHz band, so a HAM license is not required. The Johnson 0900FM15K0039 IPD is used, which includes most of the matching and filtering in one small (and more importantly easy to design for) package. The radio circuitry is identical to the reference design, with the exception that the antenna matching is omitted (it's supposedly included in the IPD). The BGS12WN6E RF switch is used, again because of its inclusion in the SX1262 IPD reference design. The switch's power supply is connected to a microcontroller pin, because it would otherwise significantly increase the sleep power consumption.

The radio is operated in LDO mode, which is slightly less efficient than the DC-DC switching mode that it also supports. This was chosen because the DC-DC mode is chiefly useful for reducing the power consumption while recieving, which the computer will spend little time doing. LDO mode allows for skipping a component.

The radio uses a small 32 MHz TCXO, the OW7EL89CENUYO3YLC-32M. The use of a TCXO is important because the flight computer is expected to perform well in a variety of weather conditions, and the board is very small so it is likely to heat up, which would disturb the frequency of a regular crystal. The 220 ohm resistor and 10 pF capacitor are included from the SX1262 datasheet.

All of the RF lines are carefully kept as short and straight as possible, with special focus on the TX lines. The trace impedance is probably not perfect (especially on the RX side), and keeping the traces short helps mitigate this.

Pyro

Each channel consists of a pair of contacts in a block of screw terminals. A charge or ignitor may be connected across these two contacts. Charges have a resistance of about 1 ohm, and fire if a few hundred milliamps are passed through them. To verify that the charge is present and correctly connected, the computer must be able to check for continuity across the contacts, by passing a small current.

One lead of each pyro channel is held high, through a current limiter IC. The other end is connected to both an N channel MOSFET to ground (for firing the charge) and to a voltage divider (for checking continuity). When a charge is present, the two terminals are bridged with only an ohm or so of resistance. The MOSFET terminal is thus pulled high when continuity is present, which can be read through the voltage divider. To fire the charge, the computer activates the MOSFET, allowing current to flow from the current-limited battery voltage to ground through the charge.

Sometimes charges are damaged during construction and become shorted. On computers without short circuit protection, this generally results in magic smoke release. On the Mark 1B, the TPS259470ARPW current limiter's fast trip limit cuts the current within 500 nanoseconds of it exceeding 10 amps, and then reduces the voltage such that around 5 amps flow. The current limiter's enable/UVLO pin is connected to the microcontroller, as an arming switch. To allow for continuity measurements when disarmed, a 5.1k resistor is connected between the battery voltage and the pyro rail. This is easily a high enough value that charges will not fire if the other lead is somehow shorted to ground (only 3.3 mA flow at 17V). This is also high enough to not defeat the reverse polarity protection; the MOSFET body diodes conduct in this direction under reverse polarity, but the current flow is tiny and will not cause damage. The 5.1k resistor is still very small compared to the 510k+100k voltage divider for continuity measurement, so it does not affect the functionality. The TPS259470ARPW's reverse polarity protection is rated to -15V, but as long as the battery is connected the right way around the computer can actually run on up to 17V (the maximum voltage supported by the 3.3V regulator).

The pyro subsystem does not feature shunts to short the charges when not in use, but a pin header is provided so that an expansion board can add this functionality.

Acknowledgements

The Mark 1B is closely based off of the design of the Mark 1, which is itself a re-layout of Anthony Rubio's, Alaxander Nutt's, Abdulrahman Almutairi's, and Devasis Aryal's senior capstone project, advised by Joe Fitz. Many of the broad design decisions were based on Project Icarus's LDRC, and much of the software is reused directly (though that is not included in this repository).

About

Redesigned flight computer

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors