Hi all, I am pretty new to LoRa and I want to use a Dragino shield with an arduino to create a gateway to which my multiple LoRa nodes can send. I am in the initial stage of trying to get communication between a single Heltec LoRa 32 and an arduino. I used the Heltec LoRaSender example sketch, and the generic LoRaReceiver sketch on my arduino. The ESP is successfully sending bytes but the arduino is not receiving them. I had a look at the libraries, and it seems that both sketches make use of the LoRa.h library. Has someone tried this before and what did they do to make it work? Or what would you advise me to look at or what documentation to read to try and solve this issue?
On the pictures above, the similarities between the HeltecLoRaReceiver sketch and the generic LoRaReceiver sketch are quite clear. With the exception of initialization of the Heltec, both sketches use the LoRa library to parse and read incoming data.
[code]
#include “heltec.h”
#define BAND 433E6 //you can set band here directly,e.g. 868E6,915E6
int counter = 0;
void setup() {
//WIFI Kit series V1 not support Vext control
Heltec.begin(true /DisplayEnable Enable/, true /Heltec.LoRa Disable/, true /Serial Enable/, true /PABOOST Enable/, BAND /long BAND/);
}
void loop() {
Serial.print("Sending packet: ");
Serial.println(counter);
// send packet
LoRa.beginPacket();
/*
- LoRa.setTxPower(txPower,RFOUT_pin);
- txPower – 0 ~ 20
- RFOUT_pin could be RF_PACONFIG_PASELECT_PABOOST or RF_PACONFIG_PASELECT_RFO
-
- RF_PACONFIG_PASELECT_PABOOST – LoRa single output via PABOOST, maximum output 20dBm
-
- RF_PACONFIG_PASELECT_RFO – LoRa single output via RFO_HF / RFO_LF, maximum output 14dBm
*/
LoRa.setTxPower(14,RF_PACONFIG_PASELECT_PABOOST);
LoRa.print("hello ");
LoRa.print(counter);
LoRa.endPacket();
- RF_PACONFIG_PASELECT_RFO – LoRa single output via RFO_HF / RFO_LF, maximum output 14dBm
counter++;
digitalWrite(25, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(25, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
The above is a sketch of the HeltecLoRaSender sketch for context.
I am just starting out with this stuff, so please be kind, forum people can be crappy at times. All i need is guidance.
Thanks much.