easySwitchBox

The long-range LoRa® wall switch powered by coin cells and the Arduino IDE

Jul 01, 2019

Project update 3 of 9

Play with LoRa modem settings

In this update, we’ll explore a recent test we performed while trying to find the optimum modem settings for the ratio: battery life vs. time in the air and distance. We tested different combinations of SF, CR and Bandwidth.

LoRa modem settings

SF spread spectrum chips (chirps).

The main principle of LoRa spread spectrum modulation is that each bit of information is encoded as multiple chips (chirps). SF number is degree of 2.

The more chips, the better noise resistance when the signal is demodulated.

CR we tested is 4/5

Forward Error Correction implemented by encoding 4-bit data with redundancies into 5, 6, 7, or 8-bit can help to overcome short burst of interference.

Bandwidth we tested

We tested 125-500 KHz. The wider the bandwidth used, the faster transmission we have. A draw back here is that some sensitivity [dBm] will be lost.

Test conditions

Software used: MySensors API
Terrain: Urban environment
Visibility: There was no line of sight between the two points
Obstacles: Trees in the park, and low rise and high-rise buildings in between the points as well

The distance between the receiver and the switch was about 200 - 300 meters long, and filled wit trees. According to https://studylib.net/doc/7665614/recommendation-itu-r-p.833-4

It is 0.1 DBm per meter in receiving signal loss, so we may assume this is equivalent of several low-rise buildings.

Maximum output power: 20 dBm
Frequency: 868 MHz band

The receiving gateway was mounted at about 14 meters height.

Testing SF, CR and Bandwidth settings

Please see the images below as well, for each setting.

Settings 1:

** Notes:** Time on air with receiving of the message acknowledgement from receiver is about 252 ms. Visually looks like no delay while messages is en route to receiver, and receivers sends acknowledgement back to the switch

Settings 2:

Notes: Time on air with receiving of the message acknowledgement from receiver is about 634 ms Feels some delay while messages going to receiver and receivers sends acknowledgement back to the switch

Settings 3:

Notes: Time on air with receiving of the message acknowledgement from receiver is about 2.3 seconds. Feels very slow while messages going to receiver and receivers sends acknowledgement back to the switch

General Notes:

More redundant data (CR) showed better results if short bursts of noise were detected. Unfortunately, we did not catch that type of noise while testing this time. Plying with CR did not increase distance during this test session.

More chirps per bit (SF) definitely increase distance in urban areas. Combined with less bandwidth used (125 instead of 500) gives very good results. Much more stable and almost no dead zones.

Dead zones – since we had no line of sight between the points, there were many dead zones where signal was received but took many retries by the switch to receive or send signal.

Maximizing sensitivity (less bandwidth taken) but increasing time on air (much less battery life) or increasing the bandwidth for faster transmission but reducing sensitivity showed overall advantage

Resending vs large spreading factor. This test with particular conditions we had, showed advantage of large spreading factor.

Settings 1:

Settings 2:

Settings 3:


Sign up to receive future updates for easySwitchBox.

Subscribe to the Crowd Supply newsletter, highlighting the latest creators and projects