lorawan-stack icon indicating copy to clipboard operation
lorawan-stack copied to clipboard

Join-Accept not transmitted to AS923-1 end-device when dwell time restrictions enabled

Open cprovidenti opened this issue 1 year ago • 0 comments

Summary

When dwell time restrictions are enabled for a LoRaWAN 1.0.4 AS923-1 end-device, the network server will not transmit a Join-Accept to that end-device. (To be precise: the network server does not forward the Join-Accept downlink to the corresponding gateway.) By contrast, it will do so for the same end-device when dwell time restrictions are disabled, or for a LoRaWAN 1.0.4 AU915 end-device regardless of whether dwell time restrictions are enabled or disabled. Note: Insofar as this issue is concerned, "network server" may, in fact, refer to the join server (JS) rather than the LNS per se. (I am not using an external JS.)

Steps to Reproduce

  1. Configure a LoRaWAN 1.0.4 AS923-1 end-device for OTAA, and with dwell time restrictions enabled (e.g., as shown in the screenshot attached under the heading Other Information).
  2. Configure an AS923 gateway accordingly (e.g., as shown in the screenshot attached under the heading Other Information), and connect it to The Things Network.
  3. Enable "Verbose stream" in the "Live Data" tab of the console for the aforementioned end-device (see step 1).
  4. (Optional) If possible, monitor the packet forwarding log (or equivalent) on the gateway.
  5. Force the end-device to undergo OTAA (i.e., join The Things Network), e.g., by resetting or power-cycling the end-device.
  6. Observe what results when a valid Join-Request is received from that end-device on the corresponding "Live Data" tab of the console.
  7. (Optional) If possible, observe in the packet forwarding log (on the gateway), the presence of the uplink packet (containing the Join-Request) from the end-device, but absence of a downlink packet (containing the Join-Accept) from the network server.

Current Result

As shown in the relevant log (downloaded as a JSON string from the "Live Data" tab of the end-device console), it turns out that the network server is "blocking itself" from forwarding the Join-Accept to the gateway, because at DR2 with dwell time restrictions enabled, the maximum frame size in this region (AS923-1) is 24 octets (24 bytes), whereas a Join-Accept with an (optional) CFList requires a packet size of 33 octets. In this case, however, a better course of action would have been to omit the (optional) CFList so as to reduce the packet size to 17 octets. Not only is the CFList optional (meaning that omitting it from the Join-Accept does not violate the LoRaWAN specification), but in the case shown in the log, there was no point in including a CFList (because only the default AS923-1 channels were being used, meaning the CFList would have been "empty"). By contrast, under AU915 with dwell time restrictions enabled (and using the 8-channel plan recommended by The Things Network), precisely the same situation arises at DR2, but the network server transmits the Join-Accept nevertheless.

Expected Result

The Join-Request should be transmitted to the end-device, but without the (optional) CFList so as to comply with the dwell time restrictions.

Relevant Logs

[
  {
    "name": "ns.down.join.schedule.fail",
    "time": "2022-08-09T20:05:23.844962273Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.ErrorDetails",
      "namespace": "pkg/gatewayserver",
      "name": "schedule",
      "message_format": "failed to schedule",
      "correlation_id": "23e461e5d56a4902b0d7e90b63ff84dd",
      "code": 10,
      "details": [
        {
          "@type": "type.googleapis.com/ttn.lorawan.v3.ScheduleDownlinkErrorDetails",
          "path_errors": [
            {
              "namespace": "pkg/gatewayserver",
              "name": "schedule_path",
              "message_format": "failed to schedule on path `{gateway_uid}`",
              "attributes": {
                "gateway_uid": "pico-gw-647fdafffe004071@ttn"
              },
              "correlation_id": "0d204fdbd95e4784b32e2cd160788338",
              "cause": {
                "namespace": "pkg/gatewayserver/io",
                "name": "too_long",
                "message_format": "the payload length `{payload_length}` exceeds maximum `{maximum_length}` at data rate `{data_rate}`",
                "attributes": {
                  "data_rate": "lora:<bandwidth:125000 spreading_factor:10 > ",
                  "maximum_length": "24",
                  "payload_length": 33
                },
                "correlation_id": "44fc0b47ba1d48baaaa5797becc68a53",
                "code": 3
              },
              "code": 3
            }
          ]
        }
      ]
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:downlink:01GA23CFR3958P09WZ0Z3B34QZ",
      "ns:transmission:01GA23CFR3Q4ZZK2QH10C6BZCZ",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CFR4WQ1DE9AYMKGV9D78"
  },
  {
    "name": "ns.down.join.schedule.attempt",
    "time": "2022-08-09T20:05:23.843083394Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.DownlinkMessage",
      "raw_payload": "IF8MVUBkiSB9tEjFPW2DGBYc5IM40cx4SF4cDoarzThY",
      "payload": {
        "m_hdr": {
          "m_type": "JOIN_ACCEPT"
        },
        "join_accept_payload": {
          "net_id": "000013",
          "dev_addr": "260B4A64",
          "dl_settings": {
            "rx2_dr": 2
          },
          "rx_delay": 5,
          "cf_list": {}
        }
      },
      "request": {
        "downlink_paths": [
          {
            "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCspqSTDRoLCIL8ypcGELPijRIg4MfL097gAg=="
          }
        ],
        "rx1_delay": 5,
        "rx1_data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "rx1_frequency": "923400000",
        "rx2_data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "rx2_frequency": "923200000",
        "priority": "HIGHEST",
        "frequency_plan_id": "AS_923_DT"
      },
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
        "ns:downlink:01GA23CFR3958P09WZ0Z3B34QZ",
        "ns:transmission:01GA23CFR3Q4ZZK2QH10C6BZCZ",
        "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
      ]
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:downlink:01GA23CFR3958P09WZ0Z3B34QZ",
      "ns:transmission:01GA23CFR3Q4ZZK2QH10C6BZCZ",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CFR37GWNJZY4ENCT90KA"
  },
  {
    "name": "ns.up.join.process",
    "time": "2022-08-09T20:05:22.243344906Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.UplinkMessage",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QCAJRTXcU=",
      "payload": {
        "m_hdr": {},
        "mic": "lFNdxQ==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0002"
        }
      },
      "settings": {
        "data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "coding_rate": "4/5",
        "frequency": "923400000",
        "timestamp": 3530101548
      },
      "rx_metadata": [
        {
          "gateway_ids": {
            "gateway_id": "pico-gw-647fdafffe004071",
            "eui": "647FDAFFFE004071"
          },
          "time": "2022-08-09T20:05:21.963Z",
          "timestamp": 3530101548,
          "rssi": -54,
          "channel_rssi": -54,
          "snr": 9,
          "location": {
            "latitude": 51.12005,
            "longitude": -114.04163,
            "altitude": 1057,
            "source": "SOURCE_REGISTRY"
          },
          "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCspqSTDRoLCIL8ypcGELPijRIg4MfL097gAg==",
          "received_at": "2022-08-09T20:05:22.037974323Z"
        }
      ],
      "received_at": "2022-08-09T20:05:22.038768445Z",
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
        "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
      ],
      "device_channel_index": 1,
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CE63GHFJD2XTDVCRS919"
  },
  {
    "name": "ns.up.join.cluster.success",
    "time": "2022-08-09T20:05:22.058685886Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.JoinResponse",
      "raw_payload": "IF8MVUBkiSB9tEjFPW2DGBYc5IM40cx4SF4cDoarzThY",
      "session_keys": {
        "session_key_id": "AYKENjgAFqpeEp6z5r8Jrw=="
      }
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CE0AVWYTY9TT4V8QSXXP"
  },
  {
    "name": "js.join.accept",
    "time": "2022-08-09T20:05:22.058147315Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000",
          "dev_addr": "260B4A64"
        }
      }
    ],
    "correlation_ids": [
      "rpc:/ttn.lorawan.v3.NsJs/HandleJoin:01GA23CDZT0YWQZSHZNYAWXGA5"
    ],
    "origin": "ip-10-100-15-50.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CE0AE7HHJF39VQ8D2C9D"
  },
  {
    "name": "ns.up.join.cluster.attempt",
    "time": "2022-08-09T20:05:22.042335607Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.JoinRequest",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QCAJRTXcU=",
      "payload": {
        "m_hdr": {},
        "mic": "lFNdxQ==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0002"
        }
      },
      "dev_addr": "260B4A64",
      "selected_mac_version": "MAC_V1_0_4",
      "net_id": "000013",
      "downlink_settings": {
        "rx2_dr": 2
      },
      "rx_delay": 5,
      "cf_list": {},
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
        "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
      ],
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CDZT205TH9RQBKKF3FYZ"
  },
  {
    "name": "ns.up.join.receive",
    "time": "2022-08-09T20:05:22.041822587Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.UplinkMessage",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QCAJRTXcU=",
      "payload": {
        "m_hdr": {},
        "mic": "lFNdxQ==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0002"
        }
      },
      "settings": {
        "data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "coding_rate": "4/5",
        "frequency": "923400000",
        "timestamp": 3530101548
      },
      "rx_metadata": [
        {
          "gateway_ids": {
            "gateway_id": "pico-gw-647fdafffe004071",
            "eui": "647FDAFFFE004071"
          },
          "time": "2022-08-09T20:05:21.963Z",
          "timestamp": 3530101548,
          "rssi": -54,
          "channel_rssi": -54,
          "snr": 9,
          "location": {
            "latitude": 51.12005,
            "longitude": -114.04163,
            "altitude": 1057,
            "source": "SOURCE_REGISTRY"
          },
          "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCspqSTDRoLCIL8ypcGELPijRIg4MfL097gAg==",
          "received_at": "2022-08-09T20:05:22.037974323Z"
        }
      ],
      "received_at": "2022-08-09T20:05:22.038768445Z",
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
        "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
      ],
      "device_channel_index": 1,
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23CDZP3DF20CHWJ08YEYBA",
      "ns:uplink:01GA23CDZPADMSRWKXG126W4AK",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23CDZPPEE7Q4FXCX0YRBZZ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23CDZS2GA033F9K6XCYG7B"
  },
  {
    "name": "ns.down.join.schedule.fail",
    "time": "2022-08-09T20:05:17.217836799Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.ErrorDetails",
      "namespace": "pkg/gatewayserver",
      "name": "schedule",
      "message_format": "failed to schedule",
      "correlation_id": "63b87f648f4b48da95380a23900beb9c",
      "code": 10,
      "details": [
        {
          "@type": "type.googleapis.com/ttn.lorawan.v3.ScheduleDownlinkErrorDetails",
          "path_errors": [
            {
              "namespace": "pkg/gatewayserver",
              "name": "schedule_path",
              "message_format": "failed to schedule on path `{gateway_uid}`",
              "attributes": {
                "gateway_uid": "pico-gw-647fdafffe004071@ttn"
              },
              "correlation_id": "71e9874abb5142b7acc3f27989020687",
              "cause": {
                "namespace": "pkg/gatewayserver/io",
                "name": "too_long",
                "message_format": "the payload length `{payload_length}` exceeds maximum `{maximum_length}` at data rate `{data_rate}`",
                "attributes": {
                  "data_rate": "lora:<bandwidth:125000 spreading_factor:10 > ",
                  "maximum_length": "24",
                  "payload_length": 33
                },
                "correlation_id": "e87ac654dd724aa19afecc7bf91fff54",
                "code": 3
              },
              "code": 3
            }
          ]
        }
      ]
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:downlink:01GA23C990JCXDG05Y9C2DTHN2",
      "ns:transmission:01GA23C99060ZG5TACN7PPHGY5",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C991EXSCG0X3QYHMFEP2"
  },
  {
    "name": "ns.down.join.schedule.attempt",
    "time": "2022-08-09T20:05:17.216354917Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.DownlinkMessage",
      "raw_payload": "ILTwQaZaGhmTDDqrft1AsR0KzXxq3rimbZal0eoqUX0c",
      "payload": {
        "m_hdr": {
          "m_type": "JOIN_ACCEPT"
        },
        "join_accept_payload": {
          "net_id": "000013",
          "dev_addr": "260B0D2A",
          "dl_settings": {
            "rx2_dr": 2
          },
          "rx_delay": 5,
          "cf_list": {}
        }
      },
      "request": {
        "downlink_paths": [
          {
            "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCEspmQDRoMCPv7ypcGEIWZ98MBIKDvrsbG4AI="
          }
        ],
        "rx1_delay": 5,
        "rx1_data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "rx1_frequency": "923400000",
        "rx2_data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "rx2_frequency": "923200000",
        "priority": "HIGHEST",
        "frequency_plan_id": "AS_923_DT"
      },
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
        "ns:downlink:01GA23C990JCXDG05Y9C2DTHN2",
        "ns:transmission:01GA23C99060ZG5TACN7PPHGY5",
        "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
      ]
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:downlink:01GA23C990JCXDG05Y9C2DTHN2",
      "ns:transmission:01GA23C99060ZG5TACN7PPHGY5",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-5-248.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C990VFMS1FJGMYKYX4SK"
  },
  {
    "name": "ns.up.join.process",
    "time": "2022-08-09T20:05:15.616565751Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.UplinkMessage",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QBAEJJkuo=",
      "payload": {
        "m_hdr": {},
        "mic": "QkmS6g==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0001"
        }
      },
      "settings": {
        "data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "coding_rate": "4/5",
        "frequency": "923400000",
        "timestamp": 3523631364
      },
      "rx_metadata": [
        {
          "gateway_ids": {
            "gateway_id": "pico-gw-647fdafffe004071",
            "eui": "647FDAFFFE004071"
          },
          "time": "2022-08-09T20:05:15.336Z",
          "timestamp": 3523631364,
          "rssi": -55,
          "channel_rssi": -55,
          "snr": 12.5,
          "location": {
            "latitude": 51.12005,
            "longitude": -114.04163,
            "altitude": 1057,
            "source": "SOURCE_REGISTRY"
          },
          "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCEspmQDRoMCPv7ypcGEIWZ98MBIKDvrsbG4AI=",
          "received_at": "2022-08-09T20:05:15.410897541Z"
        }
      ],
      "received_at": "2022-08-09T20:05:15.411656750Z",
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
        "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
      ],
      "device_channel_index": 1,
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C7Q0JRWZDB3923XZW6XC"
  },
  {
    "name": "ns.up.join.cluster.success",
    "time": "2022-08-09T20:05:15.424582004Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.JoinResponse",
      "raw_payload": "ILTwQaZaGhmTDDqrft1AsR0KzXxq3rimbZal0eoqUX0c",
      "session_keys": {
        "session_key_id": "AYKENh4ZqKoHM5BG5IX0pQ=="
      }
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C7H0GA7A5FZD2AB3ZHH6"
  },
  {
    "name": "js.join.accept",
    "time": "2022-08-09T20:05:15.424115441Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000",
          "dev_addr": "260B0D2A"
        }
      }
    ],
    "correlation_ids": [
      "rpc:/ttn.lorawan.v3.NsJs/HandleJoin:01GA23C7GQ8AZGCW87SYPY6W4S"
    ],
    "origin": "ip-10-100-5-104.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C7H0DVFRTWSPBTCJ0AQ1"
  },
  {
    "name": "ns.up.join.cluster.attempt",
    "time": "2022-08-09T20:05:15.414634825Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.JoinRequest",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QBAEJJkuo=",
      "payload": {
        "m_hdr": {},
        "mic": "QkmS6g==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0001"
        }
      },
      "dev_addr": "260B0D2A",
      "selected_mac_version": "MAC_V1_0_4",
      "net_id": "000013",
      "downlink_settings": {
        "rx2_dr": 2
      },
      "rx_delay": 5,
      "cf_list": {},
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
        "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
      ],
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C7GPXFGSETZC1SC9ZFTN"
  },
  {
    "name": "ns.up.join.receive",
    "time": "2022-08-09T20:05:15.414158418Z",
    "identifiers": [
      {
        "device_ids": {
          "device_id": "t0007938-a3-2207j0044-otaa",
          "application_ids": {
            "application_id": "lorawan-testing"
          },
          "dev_eui": "647FDA000000C6EE",
          "join_eui": "647FDA8010000000"
        }
      }
    ],
    "data": {
      "@type": "type.googleapis.com/ttn.lorawan.v3.UplinkMessage",
      "raw_payload": "AAAAABCA2n9k7sYAAADaf2QBAEJJkuo=",
      "payload": {
        "m_hdr": {},
        "mic": "QkmS6g==",
        "join_request_payload": {
          "join_eui": "647FDA8010000000",
          "dev_eui": "647FDA000000C6EE",
          "dev_nonce": "0001"
        }
      },
      "settings": {
        "data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 10
          }
        },
        "coding_rate": "4/5",
        "frequency": "923400000",
        "timestamp": 3523631364
      },
      "rx_metadata": [
        {
          "gateway_ids": {
            "gateway_id": "pico-gw-647fdafffe004071",
            "eui": "647FDAFFFE004071"
          },
          "time": "2022-08-09T20:05:15.336Z",
          "timestamp": 3523631364,
          "rssi": -55,
          "channel_rssi": -55,
          "snr": 12.5,
          "location": {
            "latitude": 51.12005,
            "longitude": -114.04163,
            "altitude": 1057,
            "source": "SOURCE_REGISTRY"
          },
          "uplink_token": "CiYKJAoYcGljby1ndy02NDdmZGFmZmZlMDA0MDcxEghkf9r//gBAcRCEspmQDRoMCPv7ypcGEIWZ98MBIKDvrsbG4AI=",
          "received_at": "2022-08-09T20:05:15.410897541Z"
        }
      ],
      "received_at": "2022-08-09T20:05:15.411656750Z",
      "correlation_ids": [
        "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
        "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
        "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
        "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
        "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
      ],
      "device_channel_index": 1,
      "consumed_airtime": "0.370688s"
    },
    "correlation_ids": [
      "gs:conn:01GA1QTMC5SY0BFKA1W67WHGQG",
      "gs:up:host:01GA1QTMC9DX4SNJZF9D7QPR3J",
      "gs:uplink:01GA23C7GJEZP47XPSQYVYT1GR",
      "ns:uplink:01GA23C7GK2Q11FC41KZZY2809",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01GA23C7GK2C6BC86FBTEVD3RJ"
    ],
    "origin": "ip-10-100-6-110.eu-west-1.compute.internal",
    "context": {
      "tenant-id": "CgN0dG4="
    },
    "visibility": {
      "rights": [
        "RIGHT_APPLICATION_TRAFFIC_READ"
      ]
    },
    "unique_id": "01GA23C7GP8AYA6AZXB6NAME2D"
  },
  {
    "time": "2022-08-09T20:04:31.294Z",
    "name": "synthetic.status.filter_disabled",
    "isError": false,
    "isSynthetic": true,
    "unique_id": "synthetic.1660075471294"
  },
  {
    "time": "2022-08-09T20:04:30.403Z",
    "name": "synthetic.status.filter_enabled",
    "isError": false,
    "isSynthetic": true,
    "unique_id": "synthetic.1660075470403",
    "data": {
      "id": "default",
      "filter": [
        "as.*.drop",
        "as.down.data.receive",
        "as.up.*.forward",
        "js.join.accept",
        "js.join.reject",
        "ns.up.data.process",
        "ns.down.data.schedule.attempt",
        "ns.mac.*.answer.reject",
        "*.warning",
        "*.fail",
        "end_device.*"
      ],
      "filterRegExp": [
        "/^as\\..*\\.drop$/",
        "/^as\\.down\\.data\\.receive$/",
        "/^as\\.up\\..*\\.forward$/",
        "/^js\\.join\\.accept$/",
        "/^js\\.join\\.reject$/",
        "/^ns\\.up\\.data\\.process$/",
        "/^ns\\.down\\.data\\.schedule\\.attempt$/",
        "/^ns\\.mac\\..*\\.answer\\.reject$/",
        "/^.*\\.warning$/",
        "/^.*\\.fail$/",
        "/^end_device\\..*$/"
      ],
      "confirmedFilter": [
        "as.down.data.decode.fail",
        "as.down.data.decode.warning",
        "as.down.data.drop",
        "as.down.data.encode.fail",
        "as.down.data.encode.warning",
        "as.down.data.receive",
        "as.mqtt.connect.fail",
        "as.packages.awsiot.fail",
        "as.packages.azure.iotcentral.fail",
        "as.packages.azure.iothub.fail",
        "as.packages.loraclouddmsv1.fail",
        "as.packages.loracloudglsv3.fail",
        "as.packages.storage.up.drop",
        "as.pubsub.fail",
        "as.up.data.decode.fail",
        "as.up.data.decode.warning",
        "as.up.data.drop",
        "as.up.data.forward",
        "as.up.join.drop",
        "as.up.join.forward",
        "as.up.location.forward",
        "as.up.service.forward",
        "as.webhook.fail",
        "dcs.end_device.claim.fail",
        "dcs.gateway.claim.fail",
        "end_device.create",
        "end_device.delete",
        "end_device.update",
        "gs.down.schedule.fail",
        "gs.down.tx.fail",
        "js.join.accept",
        "js.join.reject",
        "ns.down.data.schedule.attempt",
        "ns.down.data.schedule.fail",
        "ns.down.join.schedule.fail",
        "ns.down.transmission.fail",
        "ns.mac.beacon_freq.answer.reject",
        "ns.mac.command.parse.fail",
        "ns.mac.command.process.fail",
        "ns.mac.dl_channel.answer.reject",
        "ns.mac.link_adr.answer.reject",
        "ns.mac.new_channel.answer.reject",
        "ns.mac.rx_param_setup.answer.reject",
        "ns.up.data.process",
        "ns.up.join.cluster.fail",
        "ns.up.join.interop.fail"
      ]
    }
  },
  {
    "time": "2022-08-09T20:04:26.133Z",
    "name": "synthetic.status.cleared",
    "isError": false,
    "isSynthetic": true,
    "unique_id": "synthetic.1660075466133"
  }
]

URL

No response

Deployment

The Things Stack Community Edition

The Things Stack Version

v3.21.0

Client Name and Version

N/A

Other Information

Screenshot showing channel plan configuration for end-device: AS923-1 end-device with dwell time restrictions enabled Screenshot showing channel plan configuration for gateway: AS923-1 gateway with dwell time restrictions enabled Some quick tests confirmed that the same problem affects AS923-2, AS923-3, and AS923-4.

Proposed Fix

N/A

Contributing

  • [X] I can help by doing more research.
  • [ ] I can help by implementing a fix after the proposal above is approved.
  • [X] I can help by testing the fix before it's released.

Code of Conduct

cprovidenti avatar Aug 09 '22 22:08 cprovidenti