Connecting a Cisco Gateway to Chirpstack

Hi,

So I am trying to connect a Cisco Gateway to my chirpstack server running in the cloud. I am reasonably happy with the cloud based chirpstack install now and happily have a Raspberry Pi Zero which runs chirpstack-gateway-os-base and connects to my chirpstack network server and Chirpstack application server in the cloud.

So I have read through the following: Cisco - ChirpStack open-source LoRaWAN<sup>®</sup> Network Server and I have updated the software to Cisco LoRaWAN Gateway Software, Version 2.2.0. In the instructions above I have also configured the common packet forwarder profile

common-packet-forwarder profile
 ipaddr 192.168.1.6 port 1700
 gps enable
 antenna 1 omni gain 4.3 loss 0.1
 gatewayid 00cebefffeabab01
 cpf enable
 exit

My understanding is that this forwarder profile must point to a chirpstack gateway bridge. So at 192.168.1.6 I am running Linux and have installed the chirpstack gateway bridge. If it is helpful, I have posted my config file at the end of this post, it is adapted for the AU915 band. Note I actually had to comment out some frequencies for now to get it to run without complaining about frequencies and bandwidth. I will have to return to that issue later.

At the moment, it appears that the chirpstack gateway bridge connects to my cloud based network server and application server. So I can do a sudo systemctl restart chirpstack-gateway-bridge.service and I see a successful reconnect at my cloud based network server and application server.

I think that what I need to debug next is the connection between the cisco common packet forwarder profile and my Linux chirpstack gateway bridge. To debug the Linux chirpstack gateway bridge running locally I can use:

journalctl -u chirpstack-gateway-bridge -f -n 50

But I cannot see anything that looks like it is coming from the Cisco Gateway. Am I approaching this problem in the correct way. Have I overlooked anything?

Thanks for your time,

# See https://www.chirpstack.io/gateway-bridge/install/config/ for a full
# configuration example and documentation.


[general]
# debug=5, info=4, warning=3, error=2, fatal=1, panic=0
log_level=5

# Log to syslog.
#
# When set to true, log messages are being written to syslog.
log_to_syslog=true

# Gateway backend configuration.
[backend]

# Backend type.
type="basic_station"

  # Basic Station backend.
  [backend.basic_station]

  # ip:port to bind the Websocket listener to.
  bind=":3001"

  # Region.
  region="AU915"

  # Minimal frequency (Hz).
  #frequency_min=916000000

  # Maximum frequency (Hz).
  #frequency_max=919000000

  # Concentrator configuration.
  # Note: this is defined twice as the Cisco gateway has two SX1301 chips.
  [[backend.basic_station.concentrators]]
    # Multi-SF channel configuration.
    [backend.basic_station.concentrators.multi_sf]

    # Frequencies (Hz).
    frequencies=[
      916800000,
      917000000,
      912000000,
      917400000,
      917600000,
      #917800000,
      #918000000,
      #918200000,
    ]

    # LoRa STD channel.
    [backend.basic_station.concentrators.lora_std]

    # Frequency (Hz).
    frequency=917500000

    # Bandwidth (Hz).
    bandwidth=500000

    # Spreading factor.
    spreading_factor=8

    # FSK channel.
    #[backend.basic_station.concentrators.fsk]

    # Frequency (Hz).
    #frequency=918200000

  [[backend.basic_station.concentrators]]
    # Multi-SF channel configuration.
    [backend.basic_station.concentrators.multi_sf]

    # Frequencies (Hz).
    frequencies=[
        916800000,
        917000000,
        917200000,
        917400000,
        917600000,
        #917800000,
        #918000000,
        #918200000,
    ]

    # LoRa STD channel.
    [backend.basic_station.concentrators.lora_std]

    # Frequency (Hz).
    frequency=917500000

    # Bandwidth (Hz).
    bandwidth=500000

    # Spreading factor.
    spreading_factor=8

    # FSK channel.
    #[backend.basic_station.concentrators.fsk]

    # Frequency (Hz).
    #frequency=918200000


# Integration configuration.
[integration]

# Payload marshaler.
marshaler="protobuf"

  # MQTT authentication.
  [integration.mqtt.auth]
  type="generic"

    # Generic MQTT authentication.
    [integration.mqtt.auth.generic]
    # MQTT servers.
    #
    # Configure one or multiple MQTT server to connect to. Each item must be in
    # the following format: scheme://host:port where scheme is tcp, ssl or ws.
    servers=[
      "tcp://chirpstack.runninginthecloud.com:1883",
    ]

Ok, so I have progressed this a little further, on the Cisco Gateway you need to send on the correct port. So the Cisco config should look like:

common-packet-forwarder profile
 ipaddr 192.168.1.6 port 3001
 gps enable
 antenna 1 omni gain 4.3 loss 0.1
 gatewayid 00cebefffeabab01
 cpf enable
 exit 

So we have used port 3001 to match the Chirpstack-gateway-bridge setting.

On the Linux based gateway bridge I now get the following errors. Clearly still some issues, I hope that I am tracking in the right direction with this.

Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.571099502+01:00" level=info msg="backend/basicstation: router-info request received" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53490" router_uri="ws://192.168.1.6:3001/gateway/00cebefffeabab01"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.571099502+01:00" level=info msg="backend/basicstation: router-info request received" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53490" router_uri="ws://192.168.1.6:3001/gateway/00cebefffeabab01"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.581122238+01:00" level=info msg="backend/basicstation: gateway connected" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53492"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.58127312+01:00" level=debug msg="integration/mqtt: set gateway subscription" gateway_id=00cebefffeabab01 subscribe=true
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.581122238+01:00" level=info msg="backend/basicstation: gateway connected" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53492"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.58127312+01:00" level=debug msg="integration/mqtt: set gateway subscription" gateway_id=00cebefffeabab01 subscribe=true
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.586439329+01:00" level=debug msg="backend/basicstation: message received" gateway_id=00cebefffeabab01 message="{\"msgtype\":\"version\",\"station\":\"2.0.5(cisco/std)\",\"firmware\":\"2.0.5\",\"package\":\"2.0.5\",\"model\":\"cisco\",\"protocol\":2,\"features\":\"rmtsh gps\"}"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.587098588+01:00" level=info msg="backend/basicstation: gateway version received" firmware=2.0.5 gateway_id=00cebefffeabab01 model=cisco package=2.0.5 protocol=2 station="2.0.5(cisco/std)"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.586439329+01:00" level=debug msg="backend/basicstation: message received" gateway_id=00cebefffeabab01 message="{\"msgtype\":\"version\",\"station\":\"2.0.5(cisco/std)\",\"firmware\":\"2.0.5\",\"package\":\"2.0.5\",\"model\":\"cisco\",\"protocol\":2,\"features\":\"rmtsh gps\"}"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.587098588+01:00" level=info msg="backend/basicstation: gateway version received" firmware=2.0.5 gateway_id=00cebefffeabab01 model=cisco package=2.0.5 protocol=2 station="2.0.5(cisco/std)"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.587719358+01:00" level=debug msg="sending message to gateway" gateway_id=00cebefffeabab01 message="{\"msgtype\":\"router_config\",\"NetID\":null,\"JoinEui\":null,\"region\":\"AU915\",\"hwspec\":\"sx1301/2\",\"freq_range\":[863000000,870000000],\"DRs\":[[12,125,0],[11,125,0],[10,125,0],[9,125,0],[8,125,0],[7,125,0],[8,500,0],[-1,0,0],[12,500,1],[11,500,1],[10,500,1],[9,500,1],[8,500,0],[7,500,1],[-1,0,0],[-1,0,0]],\"sx1301_conf\":[{\"radio_0\":{\"enable\":true,\"freq\":912400000},\"radio_1\":{\"enable\":true,\"freq\":917200000},\"chan_FSK\":{\"enable\":false},\"chan_Lora_std\":{\"enable\":true,\"radio\":1,\"if\":300000,\"bandwidth\":500000,\"spread_factor\":8},\"chan_multiSF_0\":{\"enable\":true,\"radio\":0,\"if\":-400000},\"chan_multiSF_1\":{\"enable\":true,\"radio\":1,\"if\":-400000},\"chan_multiSF_2\":{\"enable\":true,\"radio\":1,\"if\":-200000},\"chan_multiSF_3\":{\"enable\":true,\"radio\":1,\"if\":200000},\"chan_multiSF_4\":{\"enable\":true,\"radio\":1,\"if\":400000},\"chan_multiSF_5\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_6\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_7\":{\"enable\":false,\"radio\":0,\"if\":0}},{\"radio_0\":{\"enable\":true,\"freq\":917200000},\"radio_1\":{\"enable\":false,\"freq\":0},\"chan_FSK\":{\"enable\":false},\"chan_Lora_std\":{\"enable\":true,\"radio\":0,\"if\":300000,\"bandwidth\":500000,\"spread_factor\":8},\"chan_multiSF_0\":{\"enable\":true,\"radio\":0,\"if\":-400000},\"chan_multiSF_1\":{\"enable\":true,\"radio\":0,\"if\":-200000},\"chan_multiSF_2\":{\"enable\":true,\"radio\":0,\"if\":0},\"chan_multiSF_3\":{\"enable\":true,\"radio\":0,\"if\":200000},\"chan_multiSF_4\":{\"enable\":true,\"radio\":0,\"if\":400000},\"chan_multiSF_5\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_6\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_7\":{\"enable\":false,\"radio\":0,\"if\":0}}]}"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.587719358+01:00" level=debug msg="sending message to gateway" gateway_id=00cebefffeabab01 message="{\"msgtype\":\"router_config\",\"NetID\":null,\"JoinEui\":null,\"region\":\"AU915\",\"hwspec\":\"sx1301/2\",\"freq_range\":[863000000,870000000],\"DRs\":[[12,125,0],[11,125,0],[10,125,0],[9,125,0],[8,125,0],[7,125,0],[8,500,0],[-1,0,0],[12,500,1],[11,500,1],[10,500,1],[9,500,1],[8,500,0],[7,500,1],[-1,0,0],[-1,0,0]],\"sx1301_conf\":[{\"radio_0\":{\"enable\":true,\"freq\":912400000},\"radio_1\":{\"enable\":true,\"freq\":917200000},\"chan_FSK\":{\"enable\":false},\"chan_Lora_std\":{\"enable\":true,\"radio\":1,\"if\":300000,\"bandwidth\":500000,\"spread_factor\":8},\"chan_multiSF_0\":{\"enable\":true,\"radio\":0,\"if\":-400000},\"chan_multiSF_1\":{\"enable\":true,\"radio\":1,\"if\":-400000},\"chan_multiSF_2\":{\"enable\":true,\"radio\":1,\"if\":-200000},\"chan_multiSF_3\":{\"enable\":true,\"radio\":1,\"if\":200000},\"chan_multiSF_4\":{\"enable\":true,\"radio\":1,\"if\":400000},\"chan_multiSF_5\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_6\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_7\":{\"enable\":false,\"radio\":0,\"if\":0}},{\"radio_0\":{\"enable\":true,\"freq\":917200000},\"radio_1\":{\"enable\":false,\"freq\":0},\"chan_FSK\":{\"enable\":false},\"chan_Lora_std\":{\"enable\":true,\"radio\":0,\"if\":300000,\"bandwidth\":500000,\"spread_factor\":8},\"chan_multiSF_0\":{\"enable\":true,\"radio\":0,\"if\":-400000},\"chan_multiSF_1\":{\"enable\":true,\"radio\":0,\"if\":-200000},\"chan_multiSF_2\":{\"enable\":true,\"radio\":0,\"if\":0},\"chan_multiSF_3\":{\"enable\":true,\"radio\":0,\"if\":200000},\"chan_multiSF_4\":{\"enable\":true,\"radio\":0,\"if\":400000},\"chan_multiSF_5\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_6\":{\"enable\":false,\"radio\":0,\"if\":0},\"chan_multiSF_7\":{\"enable\":false,\"radio\":0,\"if\":0}}]}"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.589018814+01:00" level=info msg="backend/basicstation: router-config message sent to gateway" gateway_id=00cebefffeabab01
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.589018814+01:00" level=info msg="backend/basicstation: router-config message sent to gateway" gateway_id=00cebefffeabab01
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.594951936+01:00" level=info msg="backend/basicstation: gateway disconnected" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53492"
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.595087142+01:00" level=debug msg="integration/mqtt: set gateway subscription" gateway_id=00cebefffeabab01 subscribe=false
Jul 13 05:50:01 raspberrypi chirpstack-gateway-bridge[1031]: time="2021-07-13T05:50:01.594951936+01:00" level=info msg="backend/basicstation: gateway disconnected" gateway_id=00cebefffeabab01 remote_addr="192.168.1.25:53492"