Crossbow LRS, I’m still doing this wrong…

Only two weeks ago I thought I solved all my major problems with DIY LoRa RC link. I was wrong. I was able to solve one problem (link unstable due to rouge packets messing up with protocol decoding), but an old problem came up again: PPM input from Taranis is no longer stable. At least I know why since this is a second time this is happening.

Current code read bytes from SX1276 buffer inside interrupt callback procedure (ISR). PPM decoding is also done in ISR. How many threads ATmega has? What happens when one ISR is triggered while second is still executed? Problems. The solution is to keep ISRs as simple and fast as possible. My code was not simple and fast enough.

On top of that, it turned out that Arduino LoRa library I’m using is not efficient. It performs 2 SPI transactions to read one byte from SX1276 FIFO buffer. So, 12 bytes of typical data packet equals 24 SPI transaction… Looks like I will have to do some low-level coding I wanted to avoid in the beginning… Oh well…

Read More

iRangeX IR8M: when you clone too much, but that is not a bad thing after all

I love chinesium and admire chinese manufacturers very much for a simple fact: some time ago they stopped just cloning. They started to create new things based on “legit” ones. Just look at iRangeX iRX-IR8M 2.4G 8CH Multi-Protocol Transmitter.

iRangeX iRX-IR8M multiprotocol radio transmitter

Doesn’t this thing looks almost like Team Black Sheep Tango radio transmitter? Well, it is at least similar. But this is a bad thing? The way I see it, definitely not. It is similar on the outside, but it’s not the same. Just the way TBS Tango has similar shape to Sony PlayStation 3 DualShock controller. Continue reading “iRangeX IR8M: when you clone too much, but that is not a bad thing after all” »

Read More

Crossbow LRS, I was doing this wrong…

Last update on Crossbow LRS DIY RC link I'm currently building was 2 weeks ago. Back then, it did not went well: crashed an airplane beyond field repair. Last weekend I was able to do what I planned, but that did not went well as well. This time from completely different reason…

Link was catching failsafe every few minutes, even when RX was only few meters away from TX. To make things worse, link needed few seconds to recover. And twice it got stuck and required RX restart. It took me quite some time to discover what was the reason of that and a way to fix it.

To give you a full picture:

  • Link is build using LoRa32u4 II Arduino compatible boards that utilizes HPD13 868MHz LoRa radio module. HPD13 uses Semtech SX1276 radio chipset
  • SX1276 has 256 bytes of memory is divided equally for RX and TX FIFO queue
  • I was testing in LoRa rich environment
  • To reduce the probability of race conditions on SPI access and ISR locking, radio RX fifo was read in main loop. Radio interrupt was only setting a flag that data is present

The reason for hanging link was a combination of all points above: From time to time, when radio received a rouge long LoRa packet (by long I mean longer than 128 bytes), both RX and TX were stuck processing it and as a result buffer was never fully emptied and protocol state set to IDLE. In theory, there was a air protocol reset routine, but since SX1276 FIFO was overloaded, it was not working like I expected.

The solution (or at least I hope it will solve the problem) is as follows:

  • Radio interrupt checks if received packet size is a probable air protocol packet. Since its between 7 and 12 bytes, everything else is rejected
  • When probable packet is detected (size between 7 and 12 bytes), it is copied to temporary buffer, read and decoded in main loop
  • Radio buffers are flushed after each packet (put SX1276 in sleep and wake again)

Right now, link is up and running on a bench with other LoRa stations talking around for 2 hours. Not a single failsafe or any other problem so far. Look good. Unfortunately it is raining, so not further live testing this weekend I'm afraid.

By the way, there were good things during my last test too. At 500m distance link still had around 80dB of link budget left. That means I should be able to reach my goal: 5km range is within reach!

Read More

Crossbow LRS, range test that did not went well….

Yestarday I wanted to make a first "real" range test of my DIY LRS system. "Real", because RX was supposed to be on a flying wing, but only as an passenger. Actual control was supposed to be happening via FrSky X8R. Crossbow RX was only to measure RSSI and check for failsafes.

It, well, did not ended up very well. Just watch the video.

Read More

DIY RC radio link: the problem of protocols

So, you want to build your own RC radio system? Long range maybe? Cool, I want to do it too. Since I'm pretty deep in that topic now, I can give you a hint or two. For example, have you thought about a protocol your radio system will implement?

RC link simplified

Or rather should I say: protocols? Why plural? If you want to do a RC link that talks with popular radios like FrSky Taranis on TX side and servos or flight controllers on the RX side, it will have to implement at least 2 different protocols. More likely 3. And if you will want to add telemetry downlink, 4 or even 5…

Continue reading “DIY RC radio link: the problem of protocols” »

Read More

Hands on: LoRa32u4 II 868MHz LoRa development board

Idea for Crossbow, DIY LRS system did not appearned in my mind out of nowhere. All my previous LoRa attempts were aimed at telemetry purposes only. E45-TTL-100 are cool, but bulky. If I would want to use them, I would either have to attach Arduino to it or hack it open and reprogram onboard CPU (like Qczek LRS does). Somehow it was not something what suited me very much.

But then I came across Adafruit Feather LoRa32u4 RFM95. Awesome idea. ATmega32u4 and HopeRF RFM95 LoRa module on one PCB, Arduino compatible, reasonably small and light. As a bonus, can be LiPo battery operated and has own 1S LiPo chanrger. The only thing I did not liked (OK, not the only one, but that was the biggest one) was price tag: $34.95 is somehow slightly more than I'm willing to pay for ATmega32u4. Even with radio module. So, after some digging on eBay I've found something that looked like a clone of Adafruit Feather LoRa32u4 RFM95: BSFrance LoRa32u4 II.

LoRa32u4 II 868MHz LoRa development board

BSFrance LoRa32u4 II 868MHz LoRa development board

Continue reading “Hands on: LoRa32u4 II 868MHz LoRa development board” »

Read More

QuadMeUp Crossbow LRS: introduction

Few days ago I mentioned that I'm working on my own DIY long range radio system (LRS) that I named QuadMeUp Crossbow LRS. Today I will share some more details about it.

First of all, I'm not creating anything new or "amazing". There are plenty of "DIY" or OpenSource LRS systems. OpenLRS for example. Or QCZEK LRS that is made from almost nothing at all. And amazing commercial systems like TBS Crossfire.

Is there a place for something else? I think there is. For example, I was so pissed of by complexity of OpenLRS. So many options, so hard to understand. Or do you know how much micro RX for Crossfire costs? And that you do not need 2W of power to fly up to 5km? And most of pilots owning Crossfire never flied > 2km?

This is why, my idea for DIY LRS is:

Continue reading “QuadMeUp Crossbow LRS: introduction” »

Read More

E45-TTL-100 not transmitting when connected to Arduino

While working on one of my project involving Arduino and E45-TTL-100 LoRa 868MHz radio modules, I've discovered that it is not working exactly like expected. Documentation states:

(…) When the data inputted by user is up to 58 byte, the module will start wireless transmission (…)
(…) When the required transmission bytes is less than 58 byte, the module will wait 3-byte time and treat it as data termination (…)

If I understand this correctly, E45-TTL-100 should begin radio transmission when:

  • 58 bytes were sent via serial port
  • serial transmission stopped for 3 bytes. So, at 9600bps, 3ms pause whould trigger transmission
void loop() {

In theory, code from the able should send string "Test" every 100ms. Unfortunately, it was not happening. Second E45-TTL-100 was not receiving anything. Also SDR dongle was not catching any transmissions. Something was wrong. I even contacted CD Ebyte, but they were unable to help me and The Internet was equally useless. What was wrong? No idea… looks like some kind of E45-TTL-100 MCU bug…

The solution

The solution is, hmmm, surprisingly simple. You not only have to stop transmitting, but also end serial port (Serial.end()) and open it again (Serial.begin()) after short period of time. In my experiments I've determined that 20-30ms of closed port selves the problem. So, code from above should be replaced with following:

void loop() {
    delay(70); //The rest of requested delay. So 100 - 30 = 70

It might not be the prettiest solution ever, but it works.

Read More

Testing 868MHz LoRa range, part 3: round trip

After determining that range of 868MHz LoRa wireless modules E45-TTL-100 have, at least, quite impressive range (5,7km and I was out of line-of-sight to test further) I’ve decided to test something else.

In the beginning I was planning to use those radio modules for telemetry only, but then another thought crossed my mind: why not to build DIY TBS Crossfire for the poor? After all, TBS Crossfire also uses 868MHz LoRa (SX1272 vs SX1276), so it should be possible to build DIY radio link for medium range (up to 5km) for RC planes, right?

First of all, I will need to know how fast data can be transferred and how much delay can I expect in real life. So I’ve modified Arduino code and E45-TTL-100 configuration:

  • UART speed bumped from 9600bps to 57600bps
  • air speed bumped from 2400bps to 19200bps
  • output power lowered from 100mW to 50mW (17dBm)
  • transmitter sends 5 bytes of data (current microseconds and prefix)
  • relay receives packet and resends it to transmitter
  • current received number is deducted from current microseconds and round trip time is showed on OLED display

LoRa E45-TTL-100 round trip test


  • Round trip time is 82ms on average and it does not changes with distance
  • at lower output power (50mW vs 100mW) reception at 2.8km is worse. 100% of packets are received only then antenna alignment is not worse than 45 degrees
  • with slightly bigger payload size (up to 7 bytes) it should be possible to archive at least 20Hz update rate

Read More