Skip to content

UWCubeSat/phat3_code

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

phat3_code

This Arduino code will run on the Heltec ESP32 LoRA V3 915h MHz (schematic) aboard the PHAT-3 mainboard. It will save data from PCB-mounted sensors to a micro SD card, as well as transmitting it over LoRA.

Sensor purchase requests:

Pinout for connecting to the Heltec board:

ESP 32 Pinout

Schematic of the PHAT-3 payload:

ESP 32 Pinout

Libraries

  • See idf_component.yml for dependencies.
  • esp-idf-lib libraries used for aht, bmp180, mpu6050, and scd4x.
  • igrr/libnmea used for parsing GPS output.
  • nopnop2002/sx126x used for controlling built-in radio. Here is example code. (TODO: This will hopefully replace the high-boilerplate driver we used to use in components/sx126x_driver).

I2C Bus

  • SCL - schematic pin 11 - GPIO 41
  • SDA - schematic pin 12 - GPIO 42

Troubleshooting

  • Make sure your chip is set to "esp32s3" with idf.py set-target esp32s3. Confirm it says "esp32s3" in the bottom bar of VSCode.

Sensors Documentation

U1: AHT21

Temperature and humidity sensor

U3: GY-68 BMP180

Temperature and pressure sensor

U4: GY-521 MPU-6050

Accelerometer

U6: GT-U7

GPS

U7: SCD41

CO2, temperature, humidity

U8: UCAM-III

Camera

  • Documentation
  • ESP -> UCAM - schematic pin 9 (U1TXD) - GPIO 39
  • UCAM -> ESP - schematic pin 10 (U1RXD) - GPIO 40

U9: SD Card Adapter

  • Purchase link
  • SPI SD Card Reader
  • MISO (sub -> main) - schematic pin 29 - GPIO 34
  • CLK (clock) - schematic pin 30 - GPIO 33
  • MOSI (main -> sub) - schematic pin 31 - GPIO 47
  • CS (chip select) - schematic pin 32 - GPIO 48

Built-in radio: SX1262

  • Built-in LoRa radio on the ESP board.
  • NSS - GPIO 8
  • SCK - GPIO 9
  • MOSI - GPIO 10
  • MISO - GPIO 11
  • RST - GPIO 12
  • Busy - GPIO 13
  • DIO1 - GPIO 14

About

ESP32 firmware for the PHAT-3 Mainboard

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published