-
Notifications
You must be signed in to change notification settings - Fork 64
Boards and Pins
These boards have been successfully tested with ttn-esp32:
The pin configuration of each board is shown for each one.
Version 1 boards can be recognized by the metal WiFi antenna along the pins.
PIN configuration
#define TTN_SPI_HOST HSPI_HOST
#define TTN_SPI_DMA_CHAN 1
#define TTN_PIN_SPI_SCLK 5
#define TTN_PIN_SPI_MOSI 27
#define TTN_PIN_SPI_MISO 19
#define TTN_PIN_NSS 18
#define TTN_PIN_RXTX TTN_NOT_CONNECTED
#define TTN_PIN_RST 14
#define TTN_PIN_DIO0 26
#define TTN_PIN_DIO1 33
menuconfig
The default TTN values should work fine:
- TTN radio chip: Semtech SX1276 / SX1277 / SX1278 / SX1279
- SPI frequency: 10,000,000 (10 MHz)
However, these boards usually have a XTAL frequency of 26 MHz (instead of the default 40 MHz). The correct XTAL frequency can be found on the quartz on the back of the board between the pins 19 and SRT (a magnifying glass will be helpful). The XTAL frequency needs to be set with menuconfig
at Component config / ESP-32 specific / Main XTAL frequency
Version 2 boards can be recognized by the improved placement of the metal WiFi antenna on the short side of the board while still retaining the tiny U.FL/IPEX connector.
PIN configuration
#define TTN_SPI_HOST HSPI_HOST
#define TTN_SPI_DMA_CHAN 1
#define TTN_PIN_SPI_SCLK 5
#define TTN_PIN_SPI_MOSI 27
#define TTN_PIN_SPI_MISO 19
#define TTN_PIN_NSS 18
#define TTN_PIN_RXTX TTN_NOT_CONNECTED
#define TTN_PIN_RST TTN_NOT_CONNECTED
#define TTN_PIN_DIO0 26
#define TTN_PIN_DIO1 33 †
† DIO1 of SX127x must be manually wired to a free GPIO of the ESP32. Otherwise it will not work. In the above configuration, GPIO 33 has been chosen. See this LilyGO issue for a pinout of the board. DIO1 (labelled LoRa_DIO1) and GPIOs can be found as pin holes (or as pins if pin headers have been soldered) on the long sides of the board.
menuconfig
The default values should work fine:
- TTN radio chip: Semtech SX1276 / SX1277 / SX1278 / SX1279
- SPI frequency: 10,000,000 (10 MHz)
The v2.1 boards can be recognized by the bigger SMA antenna connector (instead of the tiny U.FL/IPEX connector).
The below information has been verified with a board that was marked: T3_V1.5 20180523. Other versions of the v2.1 boards seem to exist. Also note that the RST pin of the shielded LoRa module (third one from top left) is not connected.
PIN configuration
#define TTN_SPI_HOST HSPI_HOST
#define TTN_SPI_DMA_CHAN 1
#define TTN_PIN_SPI_SCLK 5
#define TTN_PIN_SPI_MOSI 27
#define TTN_PIN_SPI_MISO 19
#define TTN_PIN_NSS 18
#define TTN_PIN_RXTX TTN_NOT_CONNECTED
#define TTN_PIN_RST TTN_NOT_CONNECTED
#define TTN_PIN_DIO0 26
#define TTN_PIN_DIO1 33
menuconfig
The default values should work fine:
- TTN radio chip: Semtech SX1276 / SX1277 / SX1278 / SX1279
- SPI frequency: 10,000,000 (10 MHz)