Capstan wrote: ↑Fri Jan 12, 2018 6:03 pm
You seem to be getting much better results than I am. Here are the default settings in the SX127x driver code I have. I guess the 'signal_bandwidth' value corresponds to your 'BW' value? If so, 125E3 hex is 75235 decimal, far less than your 125000. Also the 'coding_rate' of 5 (may be your 'CR'?) is much less than 45.
Code: Select all
{'frequency': 433E6, 'tx_power_level': 2, 'signal_bandwidth': 125E3,
'spreading_factor': 8, 'coding_rate': 5, 'preamble_length': 8,
'implicitHeader': False, 'sync_word': 0x12, 'enable_CRC': False}
I'll see what happens when I use your values. Also on your blog I noticed that you mention "I have one of the ESP32 modules with built in LoRa and OLED display on order and will be checking its performance versus a standard ATMega set-up". Presumably you will be getting a device very similar to what I have, so it will be interesting to compare results. The code I am using is derived from this github repository;
https://github.com/Wei1234c/SX127x_driv ... on_ESP8266
The bandwidths are not set as numbers, I just use symbols so its easier to understand the code, BW125000 is actually number 112, which is the value you write to the lora modem registers to set the bandwidth to 125khz.
CR45, is my shorthand for a coding rate of 4:5.
SF12 is shorthand for spreading factor 12.
You can only use specific bandwidths, coding rates and spreading factors.
The numbers I use apply to my own code only they may not make sense to whatever code library you are using. I wrote my own LoRa libraries (for PICAXE, Micromite and Arduino) back in early 2015, there were no suitable code libraries available then.
I have the Heltec Wifi LoRa OLED working under Arduino, and an initial look suggests it does not perform so well as an ATMega, but I need to test the Heltec as a handheld receiver in a large field to be sure the results I am getting are accurate. I spend a lot of time 'testing' in large open fields.