LoRa Feather (Estop) - Autonomous-Motorsports-Purdue/Electrical_Documentation GitHub Wiki
LoRa Feather (Estop) Guide
The ADAFRUIT Feather M0 is a microcontroller that uses RFM95 LoRa Radio to transmit packets at a frequency of 900MHz. It uses an ATSAMD21G18 ARM Cortex M0 processor, clocked at 48 MHz and at 3.3V logic. This chip has 256K of FLASH and 32K of RAM along with a built in USB with USB-to-Serial program & debug capability. The feather has an optional connector for 3.7V Lithium polymer batteries, but will run just fine with a micro USB connector. It has 20 GPIO pins, 8 PWM pins, 10 analog inputs, 1 analog output, 1 power/enable pin, 4 mounting holes, and 1 reset button. Pin 13 is used as an LED for blinking. The Feather LoRa module is great for small data packet transmission over a large range. It has the following features:
- SX127x LoRa based module with SPI interface
- Packet radio with ready-to-go Arduino libraries
- (+5 to +20) dBm up to 100 mW Power Output Capability
Pinout
Power Pins:
- GND - Common ground for all power and logic
- BAT - Positive voltage to/from the JST jack (for optional lipoly battery)
- USB - Positive voltage to/from micro USB jack
- EN - 3.3V regulator's enable pin. It's pulled up, so connect to ground to disable the 3.3V regulator
- 3V - output from the 3.3V regulator, it can supply 500mA peak
Logic Pins:
All logic is 3.3V All pins can be interrupt inputs Nearly all pins can do PWM output
- Pin 0/RX - GPIO #0, also receive (input) pin for Serial1 (hardware UART), also can be analog input
- Pin 1/TX - GPIO #1, also transmit (output) pin for Serial1, also can be analog input
- Pin 20/SDA - GPIO #20, also the I2C (Wire) data pin. There's no pull up on this pin by default so when using with I2C, you may need a 2.2K-10K pullup.
- Pin 21/SCL - GPIO #21, also the I2C (Wire) clock pin. There's no pull up on this pin by default so when using with I2C, you may need a 2.2K-10K pullup.
- Pin 5 - GPIO #5
- Pin 6 - GPIO #6
- Pin 9 - GPIO #9, also analog input A7. This analog input is connected to a voltage divider for the lipoly battery so be aware that this pin naturally 'sits' at around 2VDC due to the resistor divider
- Pin 10 - GPIO #10
- Pin 11 - GPIO #11
- Pin 12 - GPIO #12
- Pin 13 - GPIO #13 and is connected to the red LED next to the USB jack
- A0 - This pin is analog input A0 but is also an analog output due to having a DAC (digital-to-analog converter). You can set the raw voltage to anything from 0 to 3.3V, unlike PWM outputs this is a true analog output
- A1 to A5 - These are each analog input as well as digital I/O pins.
- SCK/MOSI/MISO (GPIO 24/23/22)- These are the hardware SPI pins, you can use them as everyday GPIO pins (but recommend keeping them free as they are best used for hardware SPI connections for high speed.
Radio Module pins:
- Pin 8 - used as the radio CS (Chip Select) pin
- Pin 3 - used as the radio GPIO0 / IRQ (interrupt request) pin
- Pin 4 - used as the radio Reset pin
The CS Pin (#8) does not have a pullup built in so be sure to set this pin HIGH when not using the radio
Other Pins:
- RST - this is the Reset pin, tie to ground to manually reset the AVR, as well as launch the bootloader manually
- ARef - the analog reference pin. Normally the reference voltage is the same as the chip logic voltage (3.3V) but if you need an alternative analog reference, connect it to this pin and select the external AREF in your firmware. Can't go higher than 3.3V!