manuelbl / ttn-esp32

The Things Network device library for ESP32 (ESP-IDF) and SX127x based devices
MIT License
303 stars 64 forks source link

change datarate #20

Closed haorfani closed 4 years ago

haorfani commented 4 years ago

Hi all,

I am trying to change the datarate, when I was using the lmic library from arduino IDE I was using the LMIC_setDrTxpow(DR_SF10,14); command to change txpower and data rate. However when I am doing the same with ttn-esp32 do not seem to change according to the metadata in ttn console.

Best, Haris

manuelbl commented 4 years ago

Using LMIC functions directly will not reliably work. I will probably add a dedicated function for this.

What's your use case for setting the data rate explicitly (and not relying on the automated setting)?

haorfani commented 4 years ago

I want to evaluate different datarates for a synchronization scheme I developed.

haorfani commented 4 years ago

Hi again, in the same manner is there any way to change the rxDelay? Because using LMIC function (i.e. LMIC.rxDelay = 2;) does not make any difference as far as I can see.

manuelbl commented 4 years ago

If you are looking for a library to work outside the LoRaWAN / TTN standards, then ttn-esp32 is probably not the library for your project.

If you modify rxDelay, the device won't be able to receive downlink messages in TTN environment anymore. So it will never be exposed via an API.

haorfani commented 4 years ago

OK, thanks for your response.

Is there any chance that you know any library that would fit more to my project then?

Best, Haris

manuelbl commented 4 years ago

I don't have a good overview of LoRa libraries. A Google search reveals esp32-lora-library. It's described as "Low-level Lora (SX127_) library for the ESP-32 IDF". So that might be a fit.

Or lmic-esp-idf...

I haven't used any of these libraries. So I can't make a recommendation.

haorfani commented 4 years ago

thanks a lot!