lorawan-stack

TheThingsNetworkApache-2.0活跃维护

开源 LoRaWAN 网络服务器,用于接入和管理 LoRa 物联网设备,提供设备注册、数据路由与网络运维能力。

The Things Stack, an Open Source LoRaWAN Network Server

v3.37.0发布于 2026-11-04 18:44 UTC1,176star362fork同步于 2026-11-10 05:55 UTC

怎么上手

由 README 提炼,执行前请确认
README 未给出安装命令,仅指向 Getting Started 指南:https://ttn.fyi/v3/getting-started
硬件要求按 README 说明

README 未说明

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

开源 LoRaWAN 网络服务器,适合搭建从本地到全球规模的公有或私有物联网网络

开源 LoRaWAN 网络服务器,用于接入和管理 LoRa 物联网设备,提供设备注册、数据路由与网络运维能力。

核心能力

  • 实现 LoRaWAN 网络服务器,支持 1.0 至 1.1 及多版区域参数
  • 支持 Class A/B/C 设备与 OTAA、ABP 入网及 MAC 命令
  • 内置应用服务器,支持 MQTT、HTTP Webhook 与自定义 JS 载荷转换
  • 提供 OAuth 2.0 身份服务器、gRPC/HTTP API 与命令行工具
  • 附带 Web Console 管理应用、终端设备与网关

容易踩的坑

README 未提供安装步骤,需按官方 Getting Started 指南操作;升级前应阅读 release notes,因为新版本会引入新配置和默认值;本地开发环境需参考 DEVELOPMENT.md 单独配置

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v3.37.0
  1. v3.37.0最新正式版2026-11-04 · 2026-11-04 18:44 UTC

    Added

    • gs_gateways_disconnected_total metric, counting gateway disconnections by protocol and by the error the connection was disconnected with. This makes disconnection reasons (such as gateways disappearing without a close handshake, or missing too many pongs) observable as a rate, instead of only through logs.
    • ttgc.managed-gateway-euis configuration option: Gateway EUI prefixes of managed gateways, defaulting to the EUI prefix of The Things Industries managed gateways. Gateways outside these prefixes are reported as not managed in the claiming info.
    • ttgc.lbscups.lns-port configuration option: the LoRa Basics Station LNS port of the Gateway Server, defaulting to 8887.
    • Downlink scheduling on all antennas of a gateway. Previously, only the first antenna could be used as a downlink path, and uplinks received on any other antenna had their downlink path disabled.
    • events.redis.store.expire-limiter-size configuration option: how many entity event streams the PEXPIRE rate limiter tracks, at 8 bytes each, defaulting to 4194304 (32 MiB). A negative value refreshes the TTL on every event.

    Changed

    • In the Semtech UDP Packet Forwarder protocol, PUSH_ACK and PULL_ACK are only sent after the gateway has connected to the Gateway Server and the gateway's PUSH_DATA or PULL_DATA respectively has been accepted.
    • Don't log a Task failed warning in GS for every task attached to a gateway connection when that connection is closed. The tasks that run for the lifetime of a gateway connection now stop without an error when the connection is closed, and the disconnection is logged once, as Disconnected, including the reason. This removes several duplicate warnings per gateway disconnection, which were particularly noisy for gateways on unreliable backhaul.
    • Websocket close errors on the LoRa Basics Station frontend (such as websocket: close 1006 (abnormal closure): unexpected EOF, which is what a gateway disappearing without a close handshake looks like) are now reported as the defined error pkg/gatewayserver/io/semtechws:websocket_closed, with the close code as an attribute and the original error as the cause. As a result, the gs.gateway.disconnect event for these disconnections now carries structured error details instead of a plain string; consumers that parse the event data should expect the ErrorDetails format.
    • The events Redis store now refreshes each per-entity event stream's TTL at most once per half of the configured events.redis.store.entity-ttl, instead of on every published event, to reduce PEXPIRE command load (and therefore CPU) on the events Redis. The refresh is rate limited with a fixed-size table allocated at startup, so memory does not grow with the number of entities. Event history retention is unchanged.

    Fixed

    • Parsing of the rctx field in the upinfo object of upstream messages received via the LoRa Basics Station LNS protocol. The field name was misspelled as rtcx, so the radio context reported by gateways was ignored. The antenna index in the uplink metadata now reflects the reported radio context and is echoed back in class A downlinks, instead of always being 0.
    • The antenna gain sent to LoRa Basics Station gateways in the router configuration. Each board's radio configuration now uses the gain of its own antenna instead of applying the first antenna's gain to all boards, and fractional gains are no longer truncated.
  2. v3.36.22026-08-17 · 2026-08-17 12:53 UTC
    查看更新说明

    Fixed

    • Applying the MAC settings profile values to the device's MAC state during the join procedure (OTAA) or factory reset (ABP).
  3. v3.36.12026-06-22 · 2026-06-22 12:52 UTC
    查看更新说明

    Added

    • Count RPC on EndDeviceRegistry to efficiently retrieve the number of end devices in an application.
    • Add tracing for LBS LNS and TTIGW protocol handlers.
    • TTGC LBS Root CUPS claiming support.
    • Configurable Identity Server user login session TTL via is.user-login.session-ttl:
      • Defaults to 0 (no expiry, matching previous behavior).
      • When set, the auth cookie becomes persistent with a matching Max-Age, and OAuth access tokens linked to a session are rejected once the session has expired.

    Changed

    • During the process of claiming a managed gateway, create the gateway in the registry before claiming it, not after.

    Fixed

    • Mutex locking that caused the rights to be fetched for authorization checks sequentially. This caused gateways to reconnect slowly after Gateway Server restarts and rpcs to timeout that were asserting gateway rights.
  4. v3.36.02026-04-03 · 2026-04-03 09:24 UTC
    查看更新说明

    Fixed

    • The timestamp of the udp packet is now always correct when the 'Schedule downlink late' is enabled for the gateway and downlink scheduling hits the duty cycle limit.
  5. v3.35.22026-01-30 · 2026-01-30 14:10 UTC
    查看更新说明

    Changed

    • Rate limiting for downlink queue operations (DownlinkQueuePush, DownlinkQueueReplace) is now applied at the application level instead of per-device. This may result in more ResourceExhausted (429) errors when multiple devices under the same application perform downlink queue operations concurrently.

    Fixed

    • Application Server webhook registry now uses read-only Redis client for non-paginated list operations, reducing connection holding time during high traffic.

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    The Things Stack, an open source LoRaWAN Network Server

    The Things Stack is an open source LoRaWAN network stack suitable for large, global and geo-distributed public and private networks as well as smaller networks. The architecture follows the LoRaWAN Network Reference Model for standards compliancy and interoperability. This project is actively maintained by The Things Industries.

    LoRaWAN is a protocol for low-power wide area networks. It allows for large scale Internet of Things deployments where low-powered devices efficiently communicate with Internet-connected applications over long range wireless connections.

    Features

    • LoRaWAN Network Server
      • Supports LoRaWAN 1.0
      • Supports LoRaWAN 1.0.1
      • Supports LoRaWAN 1.0.2
      • Supports LoRaWAN 1.0.3
      • Supports LoRaWAN 1.0.4
      • Supports LoRaWAN 1.1
      • Supports LoRaWAN Regional Parameters 1.0
      • Supports LoRaWAN Regional Parameters 1.0.2 rev B
      • Supports LoRaWAN Regional Parameters 1.0.3 rev A
      • Supports LoRaWAN Regional Parameters 1.1 rev A
      • Supports LoRaWAN Regional Parameters 1.1 rev B
      • Supports Class A devices
      • Supports Class B devices
      • Supports Class C devices
      • Supports OTAA devices
      • Supports ABP devices
      • Supports MAC Commands
      • Supports Adaptive Data Rate
      • Implements LoRaWAN Back-end Interfaces 1.0
    • LoRaWAN Application Server
      • Payload conversion of well-known payload formats
      • Payload conversion using custom JavaScript functions
      • MQTT pub/sub API
      • HTTP Webhooks API
      • Implements LoRaWAN Back-end Interfaces 1.0
    • LoRaWAN Join Server
      • Supports OTAA session key derivation
      • Supports external crypto services
      • Implements LoRaWAN Back-end Interfaces 1.0
      • Implements LoRaWAN Back-end Interfaces 1.1 draft 3
    • OAuth 2.0 Identity Server
      • User management
      • Entity management
      • ACLs
    • GRPC APIs
    • HTTP APIs
    • Command-Line Interface
      • Create account and login
      • Application management and traffic
      • End device management, status and traffic
      • Gateway management and status
    • Web Interface (Console)
      • Create account and login
      • Application management and traffic
      • End device management, status and traffic
      • Gateway management, status and traffic

    Getting Started

    You want to install The Things Stack? Fantastic! Here's the Getting Started guide.

    Do you want to set up a local development environment? See the DEVELOPMENT.md for instructions.

    Do you want to contribute to The Things Stack? Your contributions are welcome! See the guidelines in CONTRIBUTING.md.

    Are you new to LoRaWAN and The Things Network? See the general documentation at thethingsnetwork.org/docs.

    Commitments and Releases

    Open source projects are great, but a stable and reliable open source ecosystem is even better. Therefore, we make the following commitments:

    1. We will not break the API towards gateways and applications within the major version. This includes how gateways communicate (with Gateway Server) and how applications work with data (with Application Server)
    2. We will upgrade storage from older versions within the major version via migrations. This means that you can migrate an older setup without losing data.
    3. We will not require storage migrations within the minor version. This means that you can update patches without database migrations.
    4. We will not break the public command-line interface and configuration within the major version. This means that you can safely build scripts and migrate configuration.
    5. We will not break the API between components and events within minor versions. So at least the same minor versions of components are compatible with each other.
    6. We reserve the right to fix bugs in API, configuration and storage in patches and minor updates. This may break components, gateways and applications that rely on buggy behavior.

    As we are continuously adding functionality and fixes in new releases, we are also introducing new configurations and new defaults. We therefore recommend reading the release notes before upgrading to a new version.

    You can find the releases and their notes on the Releases page.

    Support