Last week at TheThingsNetwork meetup I was introduced to a setup of a ‘self build’ gateway. Can you tell me if that setup is a IMST IC880A and RPI?
If I order a IMST IC880A, what else do I need to setup to build my one gateway besides a power plug and antenna? (I already have a RaspberryPI).
Yep, that was an IMST IC880A and RPI. You only need the USB connection cable besides the things you mention, and of course the software. That is on our github: https://github.com/TheThingsNetwork/lora_gateway , https://github.com/TheThingsNetwork/packet_forwarder and git clone https://github.com/devttys0/libmpsse.git
Today recieved an IMST IC880A. Did the install procedure as below.
- Is this correct?
- What’s the next step?
====== Installation procedure on RaspBerryPi ==============
sudo apt-get update
sudo apt-get install swig libftdi-dev python-dev
cd /opt/lorawan
sudo git clone https://github.com/TheThingsNetwork/lora_gateway.git
sudo git clone https://github.com/TheThingsNetwork/packet_forwarder.git
sudo git clone https://github.com/devttys0/libmpsse.git
cd /opt/lorawan/libmpsse/src
sudo ./configure
sudo make
sudo make install
cd examples
sudo make
cd /opt/lorawan/lora_gateway
sudo make
cd /opt/lorawan/packet_forwarder
sudo make
In principle it is correct, assuming you have the one with USB connection.
You must also add an udev rule. look in lora_gateway/libloragw/99-libftdi.rules and replace ATTRS{idProduct}==“6010”, with ATTRS{idProduct}==“6014”, and then copy that file to /etc/udev/rules.d/ and reboot.
Furthermore, i ran with libmpsse with ./configure --disable-python but maybe this is not required.
Then first connect the power to your concentrator and aftwards(!) the USB. At least the ./util_tx_test should work, call it with the following options:
./util_tx_test -f 868 -r 1257
If that works, you are ready to test the (any) packet forwarder.
Btw, this is all assuming you use linux, if you are on a mac, you need to change the CFG_SPI in lora_gateway/libloragw/library.cfg from ‘ftdi’ to ‘mac’ and recompile everthing. (make clean all) And, on the mac only the poly_forwarder will run, others packet forwarders will not. (but the util_tx_test should also work).
Linux RaspBerryPi:
- restart RPI
- Connect power to concentrator
- connect usb RPI / Concentrator
sudo /opt/lorawan/lora_gateway/util_tx_test/util_tx_test -f 868 -r 1257
Sending -1 packets on 868000000 Hz (BW 125 kHz, SF 10, CR 1, 16 bytes payload, 8 symbols preamble) at 14 dBm, with 1000 ms between each
ERROR: failed to start the concentrator
Should I (re) make libmpsse with --disable-python ?
Yep, and check if you build with CFG_SPI= ftdi.
Did you change the Product ID to 6014 and added the udev rules?
Do you have the latest https://github.com/TheThingsNetwork/lora_gateway.git (this changed recently)
did you clean before make?
did you change the PLATFORM= lorank
A million things can go wrong here. In doubt, start from scratch. In any case, this should work, we have it running, hold on, we get you there …
- where to put this CFG_SPI= ftdi ?
- yes I changed product ID and added udev rules
- Downloaded lora_gateway.git today
- first run so did not clean
- where to put PLATFORM= lorank ?
where to put this CFG_SPI= ftdi ?
where to put PLATFORM= lorank ?
=> edit the file lora_gateway/libloragw/library.cfg
There you will see these parameters, edit them accordingly.
first run so did not clean
=> Okay, but now, after these changes, do:
in directory: lora_gateway execute: “make clean all”
then, in directory: packet_forwarder execute: “make clean all”
Just realize this, did you install :
sudo apt-get install libftdi-dev
I assume you did so otherwise installing of libmpsse should not work, but just checking.
To be explicit: you need the developer version libftdi-dev and not the standard libftdi
(i don’t think they can be installed both btw)
I did install libftdi-dev
Did the updates run the make clean all for both.
What next?
try it out with (in the appropriate directory)
sudo ./util_tx_test -f 868 -r 1257
I assume there where no compiler errors?
You checked every step carefully for typo’s etc …
if this still does not work … we have to start debugging, or you come to the hackers vault in Amsterdam. Where are you based?
./util_tx_test: error while loading shared libraries: libmpsse.so: cannot open shared object file: No such file or directory
I did not see any compile errors. Maybe try from scratch.
Based in Purmerend so near Amsterdam. I’ve been twice with you on friday, I am the guy from the marathon of Eindhoven if that rings a bell. I am hoping to get something running on 11 october (day of marathon). Also been to the first kick-of meetup in Eindhoven and did meet Lorna. So I know there is something going on overthere. If not ready on 11 october than next target is develop software for connecting sensor data and integrate into my (open) data software. see http://scapeler.com or twitter:@Scapeler for result of my work until now. Planning to create somekind of presentation for the Dutch Desing Week (also Eindhoven) and make promotional video (airquality/health/sport/and maybe thethingsnetwork) during the marathon day.
I did instal from scratch and:
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib/
export LD_LIBRARY_PATH
Now running sudo ./util_tx_test -f 868 -r 1257
give “Sending packet number 1 …OK” etc.
succes!
Very nice you got this working! Next step, start a packet forwarder! I go offline for a couple of hours now, see you soon.
Thanks so far
Start packet forwarder:
/opt/lorawan/packet_forwarder/gps_pkt_fwd/gps_pkt_fwd
and
/opt/lorawan/packet_forwarder/util_tx_test/util_tx_test -n 1680
It all seams to work. All package forwarders do.
What’s next?
Now start up a node and head here
http://thethingsnetwork.org/wiki/Software/Overview#getting-the-data
I got the same gateway, i.e. iC880A + Raspberry Pi, and I have a LoRaMote which sends sensors data, e.g. GPS, temperature, accelerometer, to the gateway. I am trying to get the gateway forwards the sensors data to TTN’s database (InfluxDB) so I can GET the latest sensors data from the database thru REST API.
My question is - do I have edit anything on the codes, e.g. DevEui, AppEui, to get it works? Or it will work with the default settings?
Thanks.
Hi @boon, we have the same setup in Zurich. iC880A + raspberry pi running the poly_packet_forwarder. We’ve tested it with the iM880a module, and got it to work with the sample code from the LoRaMac-node repositories (this one concretely: https://github.com/Lora-net/LoRaMac-node/tree/master/src/apps/LoRaMac/classC/SK-iM880A).
The setup works more or less by default, but right now, the TTN InfluxDB thing is not up, so yesterday we struggled a lot until we got the info that the backend was ‘misbehaving’ a bit. As a workaround, we used iot.semtech.com:1700 in the packet forwarder, just to be able to see the data coming out on the other end.
If you need more info, let me know!
Cheers
Thanks @gonzalocasas.
I will give it a try and see if I can get it works. Any idea when is InfluxDB back to normal condition?
Where to buy the iC880A ?