- I have a TTGO LoRa32 V2.1_1.6 version 915Mhz ESP32 LoRa OLED: lilygo.cn/prod_view.aspx?TypeId=50003&Id=1270&FId=t3:50003:3
- I also have a TTGO ESP32 SX1276 LoRa 915MHz (non OLED): lilygo.cn/prod_view.aspx?TypeId=50003&Id=1139&FId=t3:50003:3
I cannot get either one to inicialize Lora. I am using the code (excerpt below) but all I get are the “.” in the serial window . The pin setting in the code below are for the non OLED board and for the OLED board I am using LoRa.setPins(18, 23, 26); . I think they are the correct pin settings according to websites?
The boards suppose to be a 915, but I have also tried 433E6 and 866E6. I loaded the code using the “ESP32 Dev Module” board setting.
Perhaps the pins are wrong, or I missed another detail?
Please help.
#include <SPI.h> #include <LoRa.h> //define the pins used by the transceiver module #define ss 18 #define rst 14 #define dio0 26 void setup() { //initialize Serial Monitor Serial.begin(115200); while (!Serial); Serial.println("LoRa Receiver"); //setup LoRa transceiver module LoRa.setPins(ss, rst, dio0); while (!LoRa.begin(915E6)) { Serial.println("."); delay(500); }
Hi.
You probably don’t have the right pin definition.
Accordingly to the product page, the first board uses the following pins:
- SS: 18
- SCK: 5
- MOSI: 27
- MISO: 19
- DI0: 26
- RST: 23
The second board uses the following pins shown in the next figure:
I hope this helps.
Regards,
Sara
Sara, thank you for your response
I was using your code in the book and on the web page https://randomnerdtutorials.com/ttgo-lora32-sx1276-arduino-ide/
I was also referencing the code from the Lora.h Github page. https://github.com/sandeepmistry/arduino-LoRa
None of these pages mention the board selection of “TTGO” (perhaps I missed it?). I then searched the internet again and found https://randomnerdtutorials.com/ttgo-lora32-sx1276-arduino-ide/ that showed in a large picture I had to select “TTGO LoRa32-OLED V1” board (pictures are great). But I have a question below……..
I will eventually connect an generic ESP32 board to a RFM95 module as outlined in https://randomnerdtutorials.com/esp32-lora-rfm95-transceiver-arduino-ide/ . When I do that will I select “ESP 32 Dev Board” or “TTGO” variants, or is there a special set of custom board settings for this setting up?