Cisco LoRaWAN Gateway

Hello,

I have not daily acces to a that kind off Cisco device, and in the situation where they used it’s in a private server.
But in a new install off a new gateway, i have done at first a test setup follow the instruktion off this link https://www.thethingsnetwork.org/docs/gateways/cisco/setup.html and that works very well. i don’t had time to make more test, and reinstall it with his private setting’s.
But i following the info in de link above and it works very with TTN.

Regards

Hi guys,
I have that cisco gateway lying on a shelve.
I can do tests but unfortunately I don’t have the latest firmware. I think is running 1.0.xx.

Regards

Curious if anyone managed to figure this out. I seem to be running into the same init.d boot issue as described by Ioteelab.

Hey,

This has been solved, the issue was the the gateway could not resolve the dns of router.eu.thethings.network when it started up, since the internet connection was not yet set up.
The following script in the beginning of the start-up script (that you have in init.d) should fix the issue:

#get TTN server_address from config.json:
ttn_server=$(cat $SCRIPT_DIR/config.json|grep server_address|cut -d '"' -f 4)

#check if LXC container is able to resolve TTN FQDN:
for i in {1..10}; do
    res=$(python -c "import socket; print(socket.getaddrinfo(\"$ttn_server\", "80")[0][4][0])" 2>/dev/null)
    retVal=$?
    if [ $retVal -ne 0 ]; then
        echo not able to resolve yet, waiting 5s and try again, attempt $i of 10
        sleep 5
    else
        echo resolve ok, continue with start
        break
    fi
done
1 Like

Hi all,

The gateway is working now, however i found another bug, this time it could be with the Semtech packet forwarder.
When i try to register a new device through OTAA, the packet forwarder crashes causing the gateway to reboot, once the device has joined the network.

A short excerpt from the log:

[1470445253992526] JSON down: {“txpk”: {“imme”:false,“tmst”:250665372,“freq”:869.525,“rfch”:0,“powe”:27,“modu”:“LORA”,“datr”:“SF12BW125”,“codr”:“4/5”,“ipol”:true,“size”:33,“ncrc”:true,“data”:“IPVOTBrDSx4Dr2u5Cxg6NoRBkgyHoKm8uy5XuNGT35ki”}}
INFO: [down] a packet will be sent on timestamp value 250665372
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
INFO: [down] ACK received :slight_smile:
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: parsing GGA sentence returned - Incomplete
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: parsing GGA sentence returned - Incomplete
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)
[ 1492.047650]
[ 1492.047650] All date write into flash!
[ 1492.052895] Emergency Sync complete
WARNING: sx1301_0 packet FIFO is FULL, packets may have been lost
ERROR: [BRD0] Failed to fetch packets from SX1301s (error=-1)
ERROR: sx1301ar_fetch failed ; Unspecified error code
bash-3.2#
BootROM - 1.73
Booting from SPI flash, Secure mode
BootROM: RSA Public key verification PASSED
BootROM: CSK block signature verification PASSED
BootROM: Boot header signature verification PASSED
BootROM: Box ID verification PASSED
BootROM: JTAG is disabled

Hi everyone,

Our Uni just acquired a LoRaWAN Gateway and I’m trying to configure it to communicate with The Things Network. I followed this tutorial: https://www.thethingsnetwork.org/docs/gateways/cisco/setup.html and created a config file based on the templates that are available in /tools/templates.

Unfortunately, I get an error message in regards to the FPGA when I try to start the packet forwarder.

Configuring DSP…
INFO: [BRD0] enabling chip 0
INFO: [BRD0] enabling chip 1
INFO: [BRD0] channel diversity table: { 0 0 0 0 0 0 0 0 0 0 }
[BRD1] FPGA version = 255
ERROR: sx1301ar_start failed ; Invalid version number for the top FPGA

My FPGA version on the gateway is Version 61.

Does anyone have an idea on how to fix this?

Cheers
Louis

Fixed it!
Happened that I was using the wrong radio template!

Hello,
I would like to start the configure our gateway. But the antenna cables are missing and I’m not sure if I can power on the gateway without attached antennas. I’m still searching but maybe someone can point me to a document so I’m sure if I’m allowed to continue or not.
Thank you, Tore

In general you shouldn’t power on a gateway without antennas attached to prevent damage to the transmitter.
However if the gateway is not configured chances of it attempting to transmit are near zero, so no damage should occur.

Hello,
good point about the (not existing) configuration so I gave it a try. Now I have a unix prompt and I have to find a way to check the version and to set the root password. But I think I will do some reading first …
Thank you, Tore

Hello,
by the way, one of the boot messages:

LRR has not been installed: Turn off radio

Fine with me, at least for the moment.
Thank you, Tore

Hello,
I had to use the command “switchover” to get away from the unix prompt to a prompt where I could start with the (network) configuration. The network part, NTP and GPS are already working.

Now I’m waiting for the antenna cables and in the meantime I’m working on my two ESP32 Lora Boards. The first test with one board as (single channel) Gateway and the other as Node was successful.
Thank you, Tore

Hello,
the antenna cables arrived last Friday and today I spend some time to install one antenna. I had to use switchover to get from the Cisco prompt to the Unix prompt. I found the /etc/pktfwd directory and was able to create a config.json file. There is no tools directory, but I found a file called pkt_forwarder in /usr/sbin.

pkt_forwarder -c /etc/pktfwd/config.json -g/dev/ttyS1

seems to be fine until it complains about the FPGA:

[BRD0] FPGA version = 255
ERROR: sx1301ar_start failed ; Invalid version number for the top FPGA

The output of show version was ok for FPGA when I checked it (with the Cisco prompt).

By the way, I started with the image and files I found on the gateway. The version is 2.0.32. If you think I should start with a fresh (IOS) image I will try to get one.

Update:
I used the wrong packet forwarder. After I started the container-console (see the Cisco link already mentioned in this thread for the password) I found a /tools/ directory.

Nevertheless I still have the FPGA problem as a used the same template (config_loc_single_antenna_16ch_EU868.json) for my own config.json as I did yesterday. Next step is to decide if I try to understand the config file and to do some edits or if I just add a second antenna and try a different config file for two antennas.

Second update:
Please make sure that you did a “no radio off” and saved the config. Now the packet forwarder starts and I see the (already mentioned) “WARNING: GPS time reference is invalid. Check GPS configuration (UBX: NAV-TIMEGPS)”. Back to the documentation …

Third update:
After some waiting the GPS message went away but messages about “INFO: gateway lost sync for beaconing” started. I’m not sure if this (beacon) message is about the GPS reception. At the moment both antennas (LoRa and GPS) are mounted indoors near a window and sometimes it seems that the GPS can’t get any data at all. But even this not so optimal setup was able to transport one data packet. I’m happy about reaching this milestone.
Thank you, Tore

Hello,
the gateway is still only running when I want to check something. And I’m stuck because my OTAA nodes don’t want to join. It seems that the Join Accept messages doesn’t get back to my nodes at all.

I use a copy of config_loc_dual_antenna_8ch_full_diversity_EU868.json for my setup. Is there anything beside the following lines that I need to edit?

+       "gateway_ID": "xxx",
+        "server_address": "router.eu.thethings.network",
+        "serv_port_up": 1700,
+        "serv_port_down": 1700,

(I use a correct gateway ID and I can see packets on TTN.)

Today I will join a meeting with other LoRaWAn people and I hope there is a gateway near by so I can check two of my nodes. (One is a PAX counter on a ESP32 LoRa Heltec board so I can check if the node is able to join.)
Thank yoi, Tore

Hello,
the gateway is up and running now. At the end it was an access-list on a router somewhere between our internet connection and the gateway. Outgoing traffic wasn’t blocked and the so traffic to the TTN router on UDP port 1700 was ok. But incoming traffic was blocked. The following line did the trick:

666 permit udp host 52.169.76.203 eq 1700 host 192.168.168.192

With this line my OTAA device was finally able to join as the JOIN ACCEPT from TTN reached the gateway and was send to the node. Fun fact is that the status of the gateway is green without incoming traffic from TTN to the gateway.
Hope that helps, Tore

1 Like

I’m running into the GPS bug as well. Also for the life of me I can’t seem to get any packets to reach the TTN network at all. Nothing shows up at all.

I’ve been trying to get the Cisco gateway to work on The Things Stack, but I didn’t manage to get the Packet Forwarder to start yet. Any thoughts on this would be very helpful.

I’ve installed the packet forwarder, when trying to start the packet forwarder by running:

/etc/init.d/S60pkt_forwarder start

it returns:

Starting pkt_forwarder
0

The log file state:

spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter

Complete log file:

INFO: parsing gateway parameters
INFO: gateway MAC address is configured to 70D379FFFE8E2F00
INFO: server hostname or IP address is configured to "tti.eu1.cloud.thethings.industries"
INFO: upstream port is configured to "1700"
INFO: downstream port is configured to "1700"
INFO: packets received with a valid CRC will be forwarded
INFO: packets received with a CRC error will NOT be forwarded
INFO: packets received with no CRC will NOT be forwarded
INFO: no configuration for beaconing
INFO: Link testing mote address is configured not configured
INFO: socket 4 opened for upstream traffic, host: 52.215.156.168, port: 1700
INFO: socket 4 opened for downstream traffic, host: 52.215.156.168, port: 1700
spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter
+++ Start of packet forwarder for 'SX1301 array' concentrator +++
Version string: 5.1.0
SX1301 array library version string: 5.1.0
INFO: SPI speed set to 2000000 Hz
INFO: Little endian host
INFO: found configuration file config.json
INFO: parsing gateway parameters
INFO: gateway MAC address is configured to 70D379FFFE8E2F00
INFO: server hostname or IP address is configured to "tti.eu1.cloud.thethings.industries"
INFO: upstream port is configured to "1700"
INFO: downstream port is configured to "1700"
INFO: packets received with a valid CRC will be forwarded
INFO: packets received with a CRC error will NOT be forwarded
INFO: packets received with no CRC will NOT be forwarded
INFO: no configuration for beaconing
INFO: Link testing mote address is configured not configured
INFO: socket 4 opened for upstream traffic, host: 52.215.156.168, port: 1700
INFO: socket 4 opened for downstream traffic, host: 52.215.156.168, port: 1700
spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter
/bin/bash: /pkt_forwarder: No such file or directory
/bin/bash: line 0: exec: /pkt_forwarder: cannot execute: No such file or directory
/bin/bash: /pkt_forwarder: No such file or directory
/bin/bash: line 0: exec: /pkt_forwarder: cannot execute: No such file or directory
/bin/bash: /pkt_forwarder: No such file or directory
/bin/bash: line 0: exec: /pkt_forwarder: cannot execute: No such file or directory
+++ Start of packet forwarder for 'SX1301 array' concentrator +++
Version string: 5.1.0
SX1301 array library version string: 5.1.0
INFO: SPI speed set to 2000000 Hz
INFO: Little endian host
INFO: found configuration file config.json
INFO: parsing gateway parameters
INFO: gateway MAC address is configured to 70D379FFFE8E2F00
INFO: server hostname or IP address is configured to "tti.eu1.cloud.thethings.industries"
INFO: upstream port is configured to "1700"
INFO: downstream port is configured to "1700"
INFO: packets received with a valid CRC will be forwarded
INFO: packets received with a CRC error will NOT be forwarded
INFO: packets received with no CRC will NOT be forwarded
INFO: no configuration for beaconing
INFO: Link testing mote address is configured not configured
INFO: socket 4 opened for upstream traffic, host: 52.215.156.168, port: 1700
INFO: socket 4 opened for downstream traffic, host: 52.215.156.168, port: 1700
spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter
+++ Start of packet forwarder for 'SX1301 array' concentrator +++
Version string: 5.1.0
SX1301 array library version string: 5.1.0
INFO: SPI speed set to 2000000 Hz
INFO: Little endian host
INFO: found configuration file config.json
INFO: parsing gateway parameters
INFO: gateway MAC address is configured to 70D379FFFE8E2F00
INFO: server hostname or IP address is configured to "tti.eu1.cloud.thethings.industries"
INFO: upstream port is configured to "1700"
INFO: downstream port is configured to "1700"
INFO: packets received with a valid CRC will be forwarded
INFO: packets received with a CRC error will NOT be forwarded
INFO: packets received with no CRC will NOT be forwarded
INFO: no configuration for beaconing
INFO: Link testing mote address is configured not configured
INFO: socket 4 opened for upstream traffic, host: 52.215.156.168, port: 1700
INFO: socket 4 opened for downstream traffic, host: 52.215.156.168, port: 1700
spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter
+++ Start of packet forwarder for 'SX1301 array' concentrator +++
Version string: 5.1.0
SX1301 array library version string: 5.1.0
INFO: SPI speed set to 2000000 Hz
INFO: Little endian host
INFO: found configuration file config.json
INFO: parsing gateway parameters
INFO: gateway MAC address is configured to 70D379FFFE8E2F00
INFO: server hostname or IP address is configured to "tti.eu1.cloud.thethings.industries"
INFO: upstream port is configured to "1700"
INFO: downstream port is configured to "1700"
INFO: packets received with a valid CRC will be forwarded
INFO: packets received with a CRC error will NOT be forwarded
INFO: packets received with no CRC will NOT be forwarded
INFO: no configuration for beaconing
INFO: Link testing mote address is configured not configured
INFO: socket 4 opened for upstream traffic, host: 52.215.156.168, port: 1700
INFO: socket 4 opened for downstream traffic, host: 52.215.156.168, port: 1700
spi_r/w=NULL
ERROR: sx1301ar_start failed ; Invalid null pointer in function parameter

Hello HB

Which template did you use?

Thanks

What’s really wild is that it seems to be complaining it cannot find the packet forwarder executable, while also showing log output that is clearly coming from it.

Are there perhaps two separate things that think it is their job to run it, one which knows where it is, and one which doesn’t?

/bin/bash: /pkt_forwarder: No such file or directory

I would really hope that is not the path where a binary would live.

That said, I don’t have one of these boxes, so I’m not sure how they are supposed to be set up.

The documentation about configuring the Cisco Gateway to The Things Stack has been created and published.

For detailed info, see:
https://www.thethingsindustries.com/docs/gateways/ciscowirelessgateway/

2 Likes