IP over LoRa? Absolutely!

A very handy feature of RNode is that you can attach it to your computer, Rasbperry Pi, or similar, as a generic network interface. It’s probably the easiest way to run IP, TCP, UDP and whatever you might fancy over LoRa. As such, you can run more or less any networked application over LoRa.

To do so, you will need a couple of packages, which don’t come standard on most systems, so use your package manager to install them:

sudo apt install ax25-apps ax25-tools

You should also use the RNode Config Utility to put your RNode into TNC mode. Here’s an example command:

./rnodeconf /dev/ttyUSB0 -T --freq 867000000 --bw 250000 --txp 14 --sf 7 --cr 5

The above setup yields an on-air bitrate of 10.9 kbps.

After that, you’ll need to configure your RNode interface in /etc/ax25/axports. Add a line like the following. Replace MYCALL with the callsign of your station. If you’re using this over amateur radio frequencies, use your operator callsign. If you’re using private or unlicensed spectrum, use whatever makes sense to you. The 1152000 is the serial baud rate, 484 is the MTU, and 5 is the packet window. You can experiment with different window sizes, but don’t change the MTU, it is intentionally set at that value (even though it might seem strange if you’re used to “normal” ethernet).

rnode	MYCALL	115200	484	5	RNode interface

After you’ve added the line to the configuration file, you’re ready to bring up the interface. Use a command like the following. Remember to change /dev/ttyUSB0 to whatever serial port the RNode is connected to. Also change the IP address to whatever you want it to be.

sudo kissattach /dev/ttyUSB0 rnode 10.189.77.12

If the kissattach command completes successfully, you should be able to see the configured interface with ifconfig.

$ ifconfig ax0
ax0: flags=67  mtu 484
        inet 10.189.77.12  netmask 255.255.255.0  broadcast 10.255.255.255
        ax25 OZ7TMD-4  txqueuelen 10  (AMPR AX.25)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

That’s it! You now have a wireless IP interface using LoRa modulation up and running!

One thought on “IP over LoRa: Using RNode as a wireless NIC

Leave a Reply

Your email address will not be published. Required fields are marked *