Beginner: Raspberry PI SX162 SX1302 Gateway

Hello,

I’m an absolute beginner with this technology and I would like to build up from scratch a prototype based on some raspberry hardware.

Specifically, I would like to run a RPI Pico and a RPI Zero as two “End Point Devices” and a RPI3B+ (or 4B if necessary) as gateway.

I plan to use:

I do not understand if (and how) the transition between V2 and V3 will have an impact on the hardware and/or software I will use or on the software I will download from the producers web page.

Specifically: is there any impact between the transition from V2 to V3 and all the hardware and software one can find around? Can you see any incompatibility betwenn my setup (as described above) and the transition to V3?

Thank you very much for any help.

Paolo

1 Like

This is a conceptually sound choice, but it’s not clear if anyone has yet really work out the software details of doing so.

Typically it’s better to have your first experience of an end device be a more traditional flash-based ARM Cortex MCU (or else an ESP32) already known to be well supported with good instructions and a large community of people familiar with the details by something like LoRaMAC-Node or MCCI LMiC, and move to less common hardware only after there is experience.

and a RPI Zero as two End Point Devices

A conventional Raspberry Pi is a bit of an odd fit as a LoRaWAN end device, both in that the timing to do it correctly is possible but a bit tricky under a multitasking operating system, and that the firm requirement for mains power and the common desire to send far more data from a pi than LoRaWAN can plausibly support tend to point to it being a mismatch for a low power long range sensor-oriented network.

This is a good choice for a gateway to be installed in a location with very reliable mains power and easy access for maintenance should you end up needing to do something like re-image the SD card. It’s not really as suited to field deployment as gateway platforms with more dedicated embedded engineering and storage technologies more robust against unexpected loss of power. If using a pi, there’s no need for a recent one, a pi zero or even an old model B will work.

Specifically: is there any impact between the transition from V2 to V3 and all the hardware and software one can find around?

The main thing you need to watch out for is to avoid using “stale” software on either end, but especially the end device end. A lot of things that were never right but were sort of tolerable with V2 now cause real problems in V3 unless actually done correctly. So for example old forks of LMiC other than MCCI’s maintained one. And be particularly wary of anything that claims to make a pi into an end device being old and/or incomplete (transmit only, etc) in ways that will cause serious problems with V3.

For the gateway side you really want to use a packet forwarder recent enough to have the JIT queue, but since the sx1302 post-dates that software improvement, anything that supports it should be fine. “Basic Station” is considered more robust if you can get it to work, the sx1302 version of the “classic” packet forwarder could be your backup solution to get a gateway going.

Make sure that everything you buy is the product version for the frequency band that TTN uses in your location! Regrettably, online sellers sometimes stock frequency versions that are not just atypical, but actually illegal to use in the countries where they promote them for sale.

2 Likes

Using AT style modules that was done in early Feb.

I had a stab at porting LMIC - aka de’Arduino’ing it but the concept of HAL doesn’t extend to the radio and more important things came up.

So overall I’d go with plan A, the Adafruit Feather M0 with RFM as a starter device.

Hello and thank you very much.

I’m not sure to understand you properly when you say:

the Adafruit Feather M0 with RFM as a starter device.

I see that
Black Adafruit Feather RP2040 : ID 4884 : $11.95 : Adafruit Industries, Unique & fun DIY electronics and kits ( Black Adafruit Feather RP2040) is based on RP2040, I assume therefore that I can program it like a RPI Pico

I think I have to put on top of the Feather RP2040 radio module like Adafruit Radio FeatherWing - RFM69HCW 433MHz [RadioFruit] : ID 3230 : $9.95 : Adafruit Industries, Unique & fun DIY electronics and kits (Adafruit Radio FeatherWing - RFM69HCW 433MHz - RadioFruit plus antenna and battery)

This should be everything to make the first steps with an end device, correct?

Cheers

No.

Feather as a form factor is distinct from the Feather M0 as a particular processor in that form factor, which is what you want.

You can get a Feather M0 and wire it to your own radio, or you can get a Feather M0 LoRa for the 868 or 915 band applicable in your region and then add one jumper wire so that the MCU can fully detect the on-board LoRa chip state in the way needed for LoRaWAN.

A pi pico in a feather form factor is still a pi pico with all the disadvantages of a being a not-yet established platform for a LoRaWAN end device.

Also the RFM69 is an FSK radio, not a LoRa radio. The RFM95/RFM96 are its LoRa successors.

Just to reinforce the comment above, no, very incorrect.

But now I’ve discovered that there is an RFM69 variant, I’ll be more explicit.

This is what I recommend people who want to learn to code a LoRaWAN device buy:

It is fully supported by LMIC 4.1 and by the very detailed, comphrehensive LMIC-node:

If you use LMIC-node & VS Code with PlatformIO there is a lot of help to be had on here. You can also use any of the other boards supported by LMIC-node.

Anything else your results will vary.

For clairity, the Pico is not suitable as a starter device.

OK. Thank you very much. Now it is perfectly clear. Cheers

Hi,

thanks again. Your piece of advice helped me a lot.

Just another question :slightly_smiling_face:
Following Overview | Feather + Raspberry Pi Weather Monitoring Network with LoRa or LoRaWAN | Adafruit Learning System
I found that Adafruit LoRa Radio Bonnet with OLED - RFM95W @ 915MHz [RadioFruit] : ID 4074 : $32.50 : Adafruit Industries, Unique & fun DIY electronics and kits can be used to create a Gateway based on a RPI Zero.
All together this woud be exactly what I’m looking for.
What would you say? Can I assume that this gateway will rung without any problem with V3 of the TTN Stack?
Thank you very much

I’d say that’s another website that we as Corporal Hicks would say, need to nuke from high orbit.

It’s old stuff. Very very old stuff. It would create something called a SCPF - I can’t use the whole name as it’s worse than saying Voldermort or other swear words. I mean really bad. Makes Samuel L. Jackson in Pulp Fiction with his Oedipal Noun phrase look like saintly language.

You won’t even get started, far too many complications - and you won’t get ANY support from any of us on here. See this for more info: Single Channel Packet Forwarders (SCPF) are obsolete and not supported

You need to remove the word ‘assume’ from your LoRaWAN vocabulary - it’s got too many moving parts to assume anything. Which is why we are so happy to help with sensible questions, even if we do get a bit theatric (like above) with some of the answers.

If you need a solid starter gateway, get a TTIG, a Dragino LPS8 or LIG16 or a RAK card to sit on top of your Pi - they are all reasonably priced (for the technology) and are all fully compliant.

Going penny-pinching cheap is a real bad move with LoRaWAN - as you end up buying stuff you can’t use and no one can help you make work because it’s just not possible.

Once you have got going with creating a device, you can bring the cost down in that dept, you can build one for around £/$/€10 with a sensor or two. But to get started you need something you can rely on and is on the support list, like the Feather above.

15 posts were split to a new topic: LMIC scheduling & JSON payload issues