SparkFun LoRa Gateway 1-Channel Hookup Guide

Pages
Contributors: jimblom, Liquid Soulder
Favorited Favorite 3

Programming the ESP32 With Arduino

Note: This example assumes you are using the latest version of the Arduino IDE on your desktop. If this is your first time using Arduino, please review our tutorial on installing the Arduino IDE. If you have not previously installed an Arduino library, please check out our installation guide.

We will be using the Arduino IDE to upload new code to the Gateway. To get everything working the way it oughtta you'll have to install the ESP32 Arduino core - a set of tools and code that translates Arduino code to something that the ESP32 understands. You can also make life a little bit easier by installing a custom board definition for the LoRa Gateway 1-Channel.

Install ESP32 Arduino Core

The ESP32's relationship with Arduino is growing and now it is very easy to install the core - the Arduino IDE can handle it nearly on its own. All you need to do is make sure you have Arduino IDE version 1.8 or later, then paste

language:c
https://dl.espressif.com/dl/package_esp32_index.json

into the Additional Board Manager URLs field of the preferences window, like this:

Adding ESP Board Manager JSON File to Arduino

Hard time seeing? Click on the image for a closer look!

Now accept the changes and restart the Arduino IDE. Next open the Board Manager from the top of Tools > Board and search for ESP32. Click "Install" on the search result, after a little while the text besides the name should change to "Installed." Re-start the IDE for good measure.

The remaining portions of this guide will focus on sending a "Hello world!" message from a LoRa device to the internet.