From ed99052f47abdc16e2d9c15af755fe50e8582366 Mon Sep 17 00:00:00 2001 From: Orne Brocaar Date: Thu, 1 Sep 2022 14:32:54 +0100 Subject: [PATCH] Update ChirpStack configuration. --- configuration/chirpstack/chirpstack.toml | 17 +- .../{as923.toml => region_as923.toml} | 6 +- .../{as923_2.toml => region_as923_2.toml} | 6 +- .../{as923_3.toml => region_as923_3.toml} | 6 +- .../{as923_4.toml => region_as923_4.toml} | 6 +- .../{au915_0.toml => region_au915_0.toml} | 6 +- .../{au915_1.toml => region_au915_1.toml} | 6 +- .../{au915_2.toml => region_au915_2.toml} | 6 +- .../{au915_3.toml => region_au915_3.toml} | 6 +- .../{au915_4.toml => region_au915_4.toml} | 6 +- .../{au915_5.toml => region_au915_5.toml} | 6 +- .../{au915_6.toml => region_au915_6.toml} | 6 +- .../{au915_7.toml => region_au915_7.toml} | 6 +- configuration/chirpstack/region_cn470_0.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_1.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_10.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_11.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_2.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_3.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_4.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_5.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_6.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_7.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_8.toml | 237 ++++++++++++++++++ configuration/chirpstack/region_cn470_9.toml | 237 ++++++++++++++++++ .../{cn779.toml => region_cn779.toml} | 6 +- .../{eu433.toml => region_eu433.toml} | 6 +- .../{eu868.toml => region_eu868.toml} | 6 +- .../{in865.toml => region_in865.toml} | 6 +- .../{ism2400.toml => region_ism2400.toml} | 6 +- .../{kr920.toml => region_kr920.toml} | 6 +- .../{ru864.toml => region_ru864.toml} | 6 +- .../{us915_0.toml => region_us915_0.toml} | 6 +- .../{us915_1.toml => region_us915_1.toml} | 6 +- .../{us915_2.toml => region_us915_2.toml} | 6 +- .../{us915_3.toml => region_us915_3.toml} | 6 +- .../{us915_4.toml => region_us915_4.toml} | 6 +- .../{us915_5.toml => region_us915_5.toml} | 6 +- .../{us915_6.toml => region_us915_6.toml} | 6 +- .../{us915_7.toml => region_us915_7.toml} | 6 +- docker-compose.yml | 4 + 41 files changed, 2933 insertions(+), 94 deletions(-) rename configuration/chirpstack/{as923.toml => region_as923.toml} (97%) rename configuration/chirpstack/{as923_2.toml => region_as923_2.toml} (97%) rename configuration/chirpstack/{as923_3.toml => region_as923_3.toml} (97%) rename configuration/chirpstack/{as923_4.toml => region_as923_4.toml} (97%) rename configuration/chirpstack/{au915_0.toml => region_au915_0.toml} (98%) rename configuration/chirpstack/{au915_1.toml => region_au915_1.toml} (98%) rename configuration/chirpstack/{au915_2.toml => region_au915_2.toml} (98%) rename configuration/chirpstack/{au915_3.toml => region_au915_3.toml} (98%) rename configuration/chirpstack/{au915_4.toml => region_au915_4.toml} (98%) rename configuration/chirpstack/{au915_5.toml => region_au915_5.toml} (98%) rename configuration/chirpstack/{au915_6.toml => region_au915_6.toml} (98%) rename configuration/chirpstack/{au915_7.toml => region_au915_7.toml} (98%) create mode 100644 configuration/chirpstack/region_cn470_0.toml create mode 100644 configuration/chirpstack/region_cn470_1.toml create mode 100644 configuration/chirpstack/region_cn470_10.toml create mode 100644 configuration/chirpstack/region_cn470_11.toml create mode 100644 configuration/chirpstack/region_cn470_2.toml create mode 100644 configuration/chirpstack/region_cn470_3.toml create mode 100644 configuration/chirpstack/region_cn470_4.toml create mode 100644 configuration/chirpstack/region_cn470_5.toml create mode 100644 configuration/chirpstack/region_cn470_6.toml create mode 100644 configuration/chirpstack/region_cn470_7.toml create mode 100644 configuration/chirpstack/region_cn470_8.toml create mode 100644 configuration/chirpstack/region_cn470_9.toml rename configuration/chirpstack/{cn779.toml => region_cn779.toml} (97%) rename configuration/chirpstack/{eu433.toml => region_eu433.toml} (97%) rename configuration/chirpstack/{eu868.toml => region_eu868.toml} (98%) rename configuration/chirpstack/{in865.toml => region_in865.toml} (97%) rename configuration/chirpstack/{ism2400.toml => region_ism2400.toml} (97%) rename configuration/chirpstack/{kr920.toml => region_kr920.toml} (97%) rename configuration/chirpstack/{ru864.toml => region_ru864.toml} (97%) rename configuration/chirpstack/{us915_0.toml => region_us915_0.toml} (98%) rename configuration/chirpstack/{us915_1.toml => region_us915_1.toml} (98%) rename configuration/chirpstack/{us915_2.toml => region_us915_2.toml} (98%) rename configuration/chirpstack/{us915_3.toml => region_us915_3.toml} (98%) rename configuration/chirpstack/{us915_4.toml => region_us915_4.toml} (98%) rename configuration/chirpstack/{us915_5.toml => region_us915_5.toml} (98%) rename configuration/chirpstack/{us915_6.toml => region_us915_6.toml} (98%) rename configuration/chirpstack/{us915_7.toml => region_us915_7.toml} (98%) diff --git a/configuration/chirpstack/chirpstack.toml b/configuration/chirpstack/chirpstack.toml index eaa0c9d..54c3e5d 100644 --- a/configuration/chirpstack/chirpstack.toml +++ b/configuration/chirpstack/chirpstack.toml @@ -19,7 +19,7 @@ # * require - Always SSL (skip verification) # * verify-ca - Always SSL (verify that the certificate presented by the server was signed by a trusted CA) # * verify-full - Always SSL (verify that the certification presented by the server was signed by a trusted CA and the server host name matches the one in the certificate) - dsn="postgres://chirpstack:chirpstack@postgres/chirpstack?sslmode=disable" + dsn="postgres://chirpstack:chirpstack@$POSTGRESQL_HOST/chirpstack?sslmode=disable" # Max open connections. # @@ -41,7 +41,7 @@ # # Set multiple addresses when connecting to a cluster. servers=[ - "redis://redis/", + "redis://$REDIS_HOST/", ] # TLS enabled. @@ -70,6 +70,7 @@ "as923_3", "as923_4", "au915_0", + "cn470_10", "cn779", "eu433", "eu868", @@ -97,19 +98,9 @@ secret="you-must-replace-this" -[gateway] - client_cert_lifetime="365days" - ca_cert="configuration/certs/ca.crt" - ca_key="configuration/certs/ca.key" - [integration] enabled=["mqtt"] [integration.mqtt] - server="tcp://mosquitto:1883/" + server="tcp://$MQTT_BROKER_HOST:1883/" json=true - - [integration.mqtt.client] - client_cert_lifetime="365days" - ca_cert="configuration/certs/ca.crt" - ca_key="configuration/certs/ca.key" diff --git a/configuration/chirpstack/as923.toml b/configuration/chirpstack/region_as923.toml similarity index 97% rename from configuration/chirpstack/as923.toml rename to configuration/chirpstack/region_as923.toml index 5b310de..a826764 100644 --- a/configuration/chirpstack/as923.toml +++ b/configuration/chirpstack/region_as923.toml @@ -34,7 +34,7 @@ command_topic="as923/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/as923_2.toml b/configuration/chirpstack/region_as923_2.toml similarity index 97% rename from configuration/chirpstack/as923_2.toml rename to configuration/chirpstack/region_as923_2.toml index 602572b..75f0825 100644 --- a/configuration/chirpstack/as923_2.toml +++ b/configuration/chirpstack/region_as923_2.toml @@ -34,7 +34,7 @@ command_topic="as923_2/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/as923_3.toml b/configuration/chirpstack/region_as923_3.toml similarity index 97% rename from configuration/chirpstack/as923_3.toml rename to configuration/chirpstack/region_as923_3.toml index 2d5be43..8665e9c 100644 --- a/configuration/chirpstack/as923_3.toml +++ b/configuration/chirpstack/region_as923_3.toml @@ -34,7 +34,7 @@ command_topic="as923_3/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/as923_4.toml b/configuration/chirpstack/region_as923_4.toml similarity index 97% rename from configuration/chirpstack/as923_4.toml rename to configuration/chirpstack/region_as923_4.toml index e149bae..703d167 100644 --- a/configuration/chirpstack/as923_4.toml +++ b/configuration/chirpstack/region_as923_4.toml @@ -34,7 +34,7 @@ command_topic="as923_4/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_0.toml b/configuration/chirpstack/region_au915_0.toml similarity index 98% rename from configuration/chirpstack/au915_0.toml rename to configuration/chirpstack/region_au915_0.toml index a0998b1..4323e7c 100644 --- a/configuration/chirpstack/au915_0.toml +++ b/configuration/chirpstack/region_au915_0.toml @@ -34,7 +34,7 @@ command_topic="au915_0/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_1.toml b/configuration/chirpstack/region_au915_1.toml similarity index 98% rename from configuration/chirpstack/au915_1.toml rename to configuration/chirpstack/region_au915_1.toml index 7ffb978..7323a2a 100644 --- a/configuration/chirpstack/au915_1.toml +++ b/configuration/chirpstack/region_au915_1.toml @@ -34,7 +34,7 @@ command_topic="au915_1/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_2.toml b/configuration/chirpstack/region_au915_2.toml similarity index 98% rename from configuration/chirpstack/au915_2.toml rename to configuration/chirpstack/region_au915_2.toml index 7edda64..161a753 100644 --- a/configuration/chirpstack/au915_2.toml +++ b/configuration/chirpstack/region_au915_2.toml @@ -34,7 +34,7 @@ command_topic="au915_2/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_3.toml b/configuration/chirpstack/region_au915_3.toml similarity index 98% rename from configuration/chirpstack/au915_3.toml rename to configuration/chirpstack/region_au915_3.toml index 4ef4a17..74a13a5 100644 --- a/configuration/chirpstack/au915_3.toml +++ b/configuration/chirpstack/region_au915_3.toml @@ -34,7 +34,7 @@ command_topic="au915_3/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_4.toml b/configuration/chirpstack/region_au915_4.toml similarity index 98% rename from configuration/chirpstack/au915_4.toml rename to configuration/chirpstack/region_au915_4.toml index a0aaad8..57c15ec 100644 --- a/configuration/chirpstack/au915_4.toml +++ b/configuration/chirpstack/region_au915_4.toml @@ -34,7 +34,7 @@ command_topic="au915_4/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_5.toml b/configuration/chirpstack/region_au915_5.toml similarity index 98% rename from configuration/chirpstack/au915_5.toml rename to configuration/chirpstack/region_au915_5.toml index 2e1b3aa..2d2ce02 100644 --- a/configuration/chirpstack/au915_5.toml +++ b/configuration/chirpstack/region_au915_5.toml @@ -34,7 +34,7 @@ command_topic="au915_5/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_6.toml b/configuration/chirpstack/region_au915_6.toml similarity index 98% rename from configuration/chirpstack/au915_6.toml rename to configuration/chirpstack/region_au915_6.toml index 348d8f2..476befa 100644 --- a/configuration/chirpstack/au915_6.toml +++ b/configuration/chirpstack/region_au915_6.toml @@ -34,7 +34,7 @@ command_topic="au915_6/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/au915_7.toml b/configuration/chirpstack/region_au915_7.toml similarity index 98% rename from configuration/chirpstack/au915_7.toml rename to configuration/chirpstack/region_au915_7.toml index 2adbe1d..e51ffcc 100644 --- a/configuration/chirpstack/au915_7.toml +++ b/configuration/chirpstack/region_au915_7.toml @@ -34,7 +34,7 @@ command_topic="au915_7/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/region_cn470_0.toml b/configuration/chirpstack/region_cn470_0.toml new file mode 100644 index 0000000..8de8c7c --- /dev/null +++ b/configuration/chirpstack/region_cn470_0.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 0-7). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_0" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_0/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_0/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=470300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=470500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=470700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=470900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=471100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=471300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=471500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=471700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[0, 1, 2, 3, 4, 5, 6, 7] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_1.toml b/configuration/chirpstack/region_cn470_1.toml new file mode 100644 index 0000000..5949697 --- /dev/null +++ b/configuration/chirpstack/region_cn470_1.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 8-15). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_1" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_1/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_1/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=471900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=472100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=472300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=472500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=472700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=472900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=473100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=473300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[8, 9, 10, 11, 12, 13, 14, 15] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_10.toml b/configuration/chirpstack/region_cn470_10.toml new file mode 100644 index 0000000..abcd3ce --- /dev/null +++ b/configuration/chirpstack/region_cn470_10.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 80-87). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_10" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_10/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_10/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=486300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=486500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=486700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=486900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=487100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=487300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=487500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=487700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[80, 81, 82, 83, 84, 85, 86, 87] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_11.toml b/configuration/chirpstack/region_cn470_11.toml new file mode 100644 index 0000000..0fd37c8 --- /dev/null +++ b/configuration/chirpstack/region_cn470_11.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 88-95). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_11" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_11/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_11/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=487900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=488100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=488300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=488500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=488700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=488900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=489100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=489300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[88, 89, 90, 91, 92, 93, 94, 95] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_2.toml b/configuration/chirpstack/region_cn470_2.toml new file mode 100644 index 0000000..0bc4293 --- /dev/null +++ b/configuration/chirpstack/region_cn470_2.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 16-23). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_2" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_2/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_2/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=473500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=473700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=473900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=474100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=474300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=474500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=474700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=474900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[16, 17, 18, 19, 20, 21, 22, 23] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_3.toml b/configuration/chirpstack/region_cn470_3.toml new file mode 100644 index 0000000..f75cf96 --- /dev/null +++ b/configuration/chirpstack/region_cn470_3.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 24-31). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_3" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_3/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_3/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=475100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=475300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=475500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=475700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=475900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=476100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=476300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=476500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[24, 25, 26, 27, 28, 29, 30, 31] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_4.toml b/configuration/chirpstack/region_cn470_4.toml new file mode 100644 index 0000000..95b52cc --- /dev/null +++ b/configuration/chirpstack/region_cn470_4.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 32-39). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_4" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_4/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_4/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=476700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=476900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=477100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=477300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=477500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=477700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=477900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=478100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[32, 33, 34, 35, 36, 37, 38, 39] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_5.toml b/configuration/chirpstack/region_cn470_5.toml new file mode 100644 index 0000000..578eb05 --- /dev/null +++ b/configuration/chirpstack/region_cn470_5.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 40-47). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_5" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_5/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_5/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=478300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=478500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=478700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=478900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=479100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=479300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=479500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=479700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[40, 41, 42, 43, 44, 45, 46, 47] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_6.toml b/configuration/chirpstack/region_cn470_6.toml new file mode 100644 index 0000000..d118dcb --- /dev/null +++ b/configuration/chirpstack/region_cn470_6.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 48-55). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_6" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_6/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_6/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=479900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=480100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=480300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=480500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=480700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=480900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=481100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=481300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[48, 49, 50, 51, 52, 53, 54, 55] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_7.toml b/configuration/chirpstack/region_cn470_7.toml new file mode 100644 index 0000000..719b93a --- /dev/null +++ b/configuration/chirpstack/region_cn470_7.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 56-63). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_7" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_7/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_7/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=481500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=481700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=481900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=482100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=482300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=482500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=482700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=482900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[56, 57, 58, 59, 60, 61, 62, 63] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_8.toml b/configuration/chirpstack/region_cn470_8.toml new file mode 100644 index 0000000..8d4e5fa --- /dev/null +++ b/configuration/chirpstack/region_cn470_8.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 64-71). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_8" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_8/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_8/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=483100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=483300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=483500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=483700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=483900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=484100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=484300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=484500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[64, 65, 66, 67, 68, 69, 70, 71] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/region_cn470_9.toml b/configuration/chirpstack/region_cn470_9.toml new file mode 100644 index 0000000..4cb46fd --- /dev/null +++ b/configuration/chirpstack/region_cn470_9.toml @@ -0,0 +1,237 @@ +# This file contains an example CN470 example (channels 72-79). +[[regions]] + + # Name is an use-defined identifier for this region. + name="cn470_9" + + # Common-name refers to the common-name of this region as defined by + # the LoRa Alliance. + common_name="CN470" + + + # Gateway configuration. + [regions.gateway] + + # Force gateways as private. + # + # If enabled, gateways can only be used by devices under the same tenant. + force_gws_private=false + + + # Gateway backend configuration. + [regions.gateway.backend] + + # The enabled backend type. + enabled="mqtt" + + # MQTT configuration. + [regions.gateway.backend.mqtt] + + # Event topic template. + event_topic="cn470_9/gateway/+/event/+" + + # Command topic template. + command_topic="cn470_9/gateway/{{ gateway_id }}/command/{{ command }}" + + # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) + server="tcp://$MQTT_BROKER_HOST:1883" + + # Connect with the given username (optional) + username="" + + # Connect with the given password (optional) + password="" + + # Quality of service level + # + # 0: at most once + # 1: at least once + # 2: exactly once + # + # Note: an increase of this value will decrease the performance. + # For more information: https://www.hivemq.com/blog/mqtt-essentials-part-6-mqtt-quality-of-service-levels + qos=0 + + # Clean session + # + # Set the "clean session" flag in the connect message when this client + # connects to an MQTT broker. By setting this flag you are indicating + # that no messages saved by the broker for this client should be delivered. + clean_session=false + + # Client ID + # + # Set the client id to be used by this client when connecting to the MQTT + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. + client_id="" + + # CA certificate file (optional) + # + # Use this when setting up a secure connection (when server uses ssl://...) + # but the certificate used by the server is not trusted by any CA certificate + # on the server (e.g. when self generated). + ca_cert="" + + # TLS certificate file (optional) + tls_cert="" + + # TLS key file (optional) + tls_key="" + + + # Gateway channel configuration. + # + # Note: this configuration is only used in case the gateway is using the + # ChirpStack Concentratord daemon. In any other case, this configuration + # is ignored. + [[regions.gateway.channels]] + frequency=484700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=484900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=485100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=485300000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=485500000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=485700000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=485900000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + [[regions.gateway.channels]] + frequency=486100000 + bandwidth=125000 + modulation="LORA" + spreading_factors=[7, 8, 9, 10, 11, 12] + + + # Region specific network configuration. + [regions.network] + + # Installation margin (dB) used by the ADR engine. + # + # A higher number means that the network-server will keep more margin, + # resulting in a lower data-rate but decreasing the chance that the + # device gets disconnected because it is unable to reach one of the + # surrounded gateways. + installation_margin=10 + + # RX window (Class-A). + # + # Set this to: + # 0: RX1 / RX2 + # 1: RX1 only + # 2: RX2 only + rx_window=0 + + # RX1 delay (1 - 15 seconds). + rx1_delay=1 + + # RX1 data-rate offset + rx1_dr_offset=0 + + # RX2 data-rate + rx2_dr=0 + + # RX2 frequency (Hz) + rx2_frequency=505300000 + + # Prefer RX2 on RX1 data-rate less than. + # + # Prefer RX2 over RX1 based on the RX1 data-rate. When the RX1 data-rate + # is smaller than the configured value, then the Network Server will + # first try to schedule the downlink for RX2, failing that (e.g. the gateway + # has already a payload scheduled at the RX2 timing) it will try RX1. + rx2_prefer_on_rx1_dr_lt=0 + + # Prefer RX2 on link budget. + # + # When the link-budget is better for RX2 than for RX1, the Network Server will first + # try to schedule the downlink in RX2, failing that it will try RX1. + rx2_prefer_on_link_budget=false + + # Downlink TX Power (dBm) + # + # When set to -1, the downlink TX Power from the configured band will + # be used. + # + # Please consult the LoRaWAN Regional Parameters and local regulations + # for valid and legal options. Note that the configured TX Power must be + # supported by your gateway(s). + downlink_tx_power=-1 + + # ADR is disabled. + adr_disabled=false + + # Minimum data-rate. + min_dr=0 + + # Maximum data-rate. + max_dr=5 + + # Enabled uplink channels. + # + # Use this when ony a sub-set of the by default enabled channels are being + # used. For example when only using the first 8 channels of the US band. + # Note: when left blank / empty array, all channels will be enabled. + enabled_uplink_channels=[72, 73, 74, 75, 76, 77, 78, 79] + + + # Rejoin-request configuration (LoRaWAN 1.1) + [regions.network.rejoin_request] + + # Request devices to periodically send rejoin-requests. + enabled=false + + # The device must send a rejoin-request type 0 at least every 2^(max_count_n + 4) + # uplink messages. Valid values are 0 to 15. + max_count_n=0 + + # The device must send a rejoin-request type 0 at least every 2^(max_time_n + 10) + # seconds. Valid values are 0 to 15. + # + # 0 = roughly 17 minutes + # 15 = about 1 year + max_time_n=0 + + + # Class-B configuration. + [regions.network.class_b] + + # Ping-slot data-rate. + ping_slot_dr=0 + + # Ping-slot frequency (Hz) + # + # set this to 0 to use the default frequency plan for the configured region + # (which could be frequency hopping). + ping_slot_frequency=0 diff --git a/configuration/chirpstack/cn779.toml b/configuration/chirpstack/region_cn779.toml similarity index 97% rename from configuration/chirpstack/cn779.toml rename to configuration/chirpstack/region_cn779.toml index 8982fa1..ced9934 100644 --- a/configuration/chirpstack/cn779.toml +++ b/configuration/chirpstack/region_cn779.toml @@ -34,7 +34,7 @@ command_topic="cn779/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/eu433.toml b/configuration/chirpstack/region_eu433.toml similarity index 97% rename from configuration/chirpstack/eu433.toml rename to configuration/chirpstack/region_eu433.toml index 8b7d47a..c15367c 100644 --- a/configuration/chirpstack/eu433.toml +++ b/configuration/chirpstack/region_eu433.toml @@ -34,7 +34,7 @@ command_topic="eu433/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/eu868.toml b/configuration/chirpstack/region_eu868.toml similarity index 98% rename from configuration/chirpstack/eu868.toml rename to configuration/chirpstack/region_eu868.toml index 6b4e15b..8812ebb 100644 --- a/configuration/chirpstack/eu868.toml +++ b/configuration/chirpstack/region_eu868.toml @@ -34,7 +34,7 @@ command_topic="eu868/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/in865.toml b/configuration/chirpstack/region_in865.toml similarity index 97% rename from configuration/chirpstack/in865.toml rename to configuration/chirpstack/region_in865.toml index 6cf5a96..609b55d 100644 --- a/configuration/chirpstack/in865.toml +++ b/configuration/chirpstack/region_in865.toml @@ -34,7 +34,7 @@ command_topic="in865/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/ism2400.toml b/configuration/chirpstack/region_ism2400.toml similarity index 97% rename from configuration/chirpstack/ism2400.toml rename to configuration/chirpstack/region_ism2400.toml index 9ded437..50d2ce2 100644 --- a/configuration/chirpstack/ism2400.toml +++ b/configuration/chirpstack/region_ism2400.toml @@ -34,7 +34,7 @@ command_topic="ism2400/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/kr920.toml b/configuration/chirpstack/region_kr920.toml similarity index 97% rename from configuration/chirpstack/kr920.toml rename to configuration/chirpstack/region_kr920.toml index 62c629d..ebdfff0 100644 --- a/configuration/chirpstack/kr920.toml +++ b/configuration/chirpstack/region_kr920.toml @@ -34,7 +34,7 @@ command_topic="kr920/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/ru864.toml b/configuration/chirpstack/region_ru864.toml similarity index 97% rename from configuration/chirpstack/ru864.toml rename to configuration/chirpstack/region_ru864.toml index 0b3bf17..d7578bd 100644 --- a/configuration/chirpstack/ru864.toml +++ b/configuration/chirpstack/region_ru864.toml @@ -34,7 +34,7 @@ command_topic="ru864/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_0.toml b/configuration/chirpstack/region_us915_0.toml similarity index 98% rename from configuration/chirpstack/us915_0.toml rename to configuration/chirpstack/region_us915_0.toml index d1a8f1a..9953c49 100644 --- a/configuration/chirpstack/us915_0.toml +++ b/configuration/chirpstack/region_us915_0.toml @@ -34,7 +34,7 @@ command_topic="us915_0/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_1.toml b/configuration/chirpstack/region_us915_1.toml similarity index 98% rename from configuration/chirpstack/us915_1.toml rename to configuration/chirpstack/region_us915_1.toml index 90c754c..3061176 100644 --- a/configuration/chirpstack/us915_1.toml +++ b/configuration/chirpstack/region_us915_1.toml @@ -34,7 +34,7 @@ command_topic="us915_1/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_2.toml b/configuration/chirpstack/region_us915_2.toml similarity index 98% rename from configuration/chirpstack/us915_2.toml rename to configuration/chirpstack/region_us915_2.toml index 80e2e98..9462013 100644 --- a/configuration/chirpstack/us915_2.toml +++ b/configuration/chirpstack/region_us915_2.toml @@ -34,7 +34,7 @@ command_topic="us915_2/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_3.toml b/configuration/chirpstack/region_us915_3.toml similarity index 98% rename from configuration/chirpstack/us915_3.toml rename to configuration/chirpstack/region_us915_3.toml index 887bb12..e507cf0 100644 --- a/configuration/chirpstack/us915_3.toml +++ b/configuration/chirpstack/region_us915_3.toml @@ -34,7 +34,7 @@ command_topic="us915_3/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_4.toml b/configuration/chirpstack/region_us915_4.toml similarity index 98% rename from configuration/chirpstack/us915_4.toml rename to configuration/chirpstack/region_us915_4.toml index 0a9b729..f9e23be 100644 --- a/configuration/chirpstack/us915_4.toml +++ b/configuration/chirpstack/region_us915_4.toml @@ -34,7 +34,7 @@ command_topic="us915_4/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_5.toml b/configuration/chirpstack/region_us915_5.toml similarity index 98% rename from configuration/chirpstack/us915_5.toml rename to configuration/chirpstack/region_us915_5.toml index 82abd19..11948c7 100644 --- a/configuration/chirpstack/us915_5.toml +++ b/configuration/chirpstack/region_us915_5.toml @@ -34,7 +34,7 @@ command_topic="us915_5/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_6.toml b/configuration/chirpstack/region_us915_6.toml similarity index 98% rename from configuration/chirpstack/us915_6.toml rename to configuration/chirpstack/region_us915_6.toml index 9eb8d21..aee3b34 100644 --- a/configuration/chirpstack/us915_6.toml +++ b/configuration/chirpstack/region_us915_6.toml @@ -34,7 +34,7 @@ command_topic="us915_6/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/configuration/chirpstack/us915_7.toml b/configuration/chirpstack/region_us915_7.toml similarity index 98% rename from configuration/chirpstack/us915_7.toml rename to configuration/chirpstack/region_us915_7.toml index 68e1910..86818aa 100644 --- a/configuration/chirpstack/us915_7.toml +++ b/configuration/chirpstack/region_us915_7.toml @@ -34,7 +34,7 @@ command_topic="us915_7/gateway/{{ gateway_id }}/command/{{ command }}" # MQTT server (e.g. scheme://host:port where scheme is tcp, ssl or ws) - server="tcp://mosquitto:1883" + server="tcp://$MQTT_BROKER_HOST:1883" # Connect with the given username (optional) username="" @@ -62,8 +62,8 @@ # Client ID # # Set the client id to be used by this client when connecting to the MQTT - # broker. A client id must be no longer than 23 characters. When left blank, - # a random id will be generated. + # broker. A client id must be no longer than 23 characters. If left blank, + # a random id will be generated by ChirpStack. client_id="" # CA certificate file (optional) diff --git a/docker-compose.yml b/docker-compose.yml index d546ab9..abb46f2 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -12,6 +12,10 @@ services: - postgres - mosquitto - redis + environment: + - MQTT_BROKER_HOST=mosquitto + - REDIS_HOST=redis + - POSTGRESQL_HOST=postgres ports: - 8080:8080