This is the code which runs on the Feather M0 board to send temperature sensor data to the base station.
- Install the required libraries from the Arduino IDE
- Copy
conf.h.example->conf.hand add your 16 bit radio encryption key - Upload code to Feather M0 LoRa board with temperature sensor
- Install the Arduino CLI (instructions here)
- Run the setup script with
sh arduino_cli_setup.shorarduino_cli_setup.bat(Windows) - Ensure all libraries are in the
Arduino/librariespath - (On MacOS) run
brew install gnu-sed - Run the upload script with
sh mac_sensor_upload.shorwindows_sensor_upload.bat - Plug in a device and double tap reset button to allow upload
- Add the additional board manager url
https://adafruit.github.io/arduino-board-index/package_adafruit_index.json - Install the
Arduino SAMD Boardsfrom the boards manager. - Install the
Adafruit SAMD Boardsfrom the boards manager. - Select the matching board:
Adafruit Feather M0 (SAMD21).
- Verify installation with
arduino-cli version - Initialize the Arduino CLI config with
arduino-cli config init - Add the Adafruit board manager url with
arduino-cli config add board_manager.additional_urls https://adafruit.github.io/arduino-board-index/package_adafruit_index.json - Install the Arduino SAMD Boards with
arduino-cli core install arduino:samd - Install the Adafruit SAMD Boards with
arduino-cli core install arduino:samd