LEAPS 网关

LEAPS网关是 UWB 和 TCP/IP 网络之间的桥梁.


主要功能

  • @Todo: will be correct soon

  • @Todo: will be correct soon

  • 与 UWBS 的互连,是通过专用LEAPS网关嵌入式装置上的 SPI 来完成的. 当通过 USB 与LEAPS UWBS互联时,例如 UDK1 设备,LEAPS网关会以守护进程服务的方式运行在 Linux 平台上.


安装

系统要求

Docker的系统要求因操作系统而异.

  • 对于 Linux,您需要 64 位架构、兼容的内核版本和特定的内核功能.

  • 在 Windows 上,在启用虚拟化的 Windows 10上使用 Docker Desktop

  • 在 macOS 上,请使用配备 macOS 10.13 或更新版本的Docker Desktop. 在硬件方面,建议至少配备 2GB 内存以及足够的 CPU 和磁盘空间.

注解

有关最新详情,请参阅`Docker <https://docs.docker.com/>`_官方文档.


说明

  1. 在电脑上安装 Docker

在 Linux 上安装 Docker Desktop <https://docs.docker.com/desktop/install/linux-install/>`_

此外,您还可以参考以下命令进行安装:

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh ./get-docker.sh
sudo usermod -aG docker $USER

在 Windows 上安装 Docker Desktop <https://docs.docker.com/desktop/install/windows-install/>`_

  1. @Todo: will be correct soon

#######################################################################
# LEAPS Gateway settings
#

# -----------------------------------------------------------------
# Logging
# -----------------------------------------------------------------
log_level = 0 #  Logging level, default is 0 (0=none, 1=fatal, 2=error, 3=warning, 4=info, 5=debug, 6=verbose)

# Path to log file. Comment out to disable logging to file (log to stdio instead).
# log-file = leaps-gateway.log


# LEAPS Server host
# Default: localhost
leaps-server-host = localhost # Or your Computer's IP Address

# LEAPS Server port
# Default: 7777
leaps-server-port = 7777

# -----------------------------------------------------------------
# UWBS USB Device VID/PID
# -----------------------------------------------------------------
#

# Vendor ID, default is 0x1915, possible values are (0x1915-Nordic, 0x04d8-Microchip)
# Allowed values: 16-bit number in decimal, hexadecimal or octal format
# uwbs-usb-dev-vid = 0x04d8
uwbs-usb-dev-vid = 0x1915

# Product ID, default is 0xe8e3 for LEAPS RTLS devices
# Allowed values: 16-bit number in decimal, hexadecimal or octal format
uwbs-usb-dev-pid = 0xe8e3

# -----------------------------------------------------------------
# UWBS device configurations
# -----------------------------------------------------------------
#

# Bridge mode
# Allowed values: 0=Disable 1=Enable
# Default: (keep-current)
# uwbs-bridge = 0

# Initiator mode
# Allowed values: 0=Disable 1=Enable
# Default: (keep-current)
# uwbs-initiator = 0

# UWBMAC Profile ID
# Default: (keep-current)
# uwbs-profile-id = 0

# LEDs mode
# Allowed values: 0=Disable 1=Enable
# Default: (keep-current)
# uwbs-led = 1

# UWB encryption
# Allowed values: 0=Disable 1=Enable
# Default: (keep-current)
# uwbs-enc = 0

# UWB firmware update
# Allowed values: 0=Disable 1=Enable
# Default: (keep-current)
# uwbs-fwup = 0

# UWB mode
# Allowed values: 0=Off 1=Passive 2=Active
# Default: (keep-current)
# uwbs-uwb = 2

# UWB Backhaul Routing
# Allowed values: 0=Off 1=On 2=Auto
# Default: (keep-current)
uwbs-bh = 1

# BLE
# Allowed values: 0=Off 1=On
# Default: (keep-current)
# uwbs-ble = 1

# UWB encryption key
# Allowed values: 128-bit number in hexadecimal format
# Default: (keep-current)
# uwbs-enc-key = 11111111222222223333333344444444

# UWB network PANID
# Allowed values: 16-bit number in decimal, hexadecimal or octal format
# Default: (keep-current)
# uwbs-panid = 0x0000

# Device label
# Default: (keep-current)
# uwbs-label = gw-uwbs

# Device position in mm [x, y, z]
# Default: (keep-current)
# uwbs-pos-x = 0
# uwbs-pos-y = 0
# uwbs-pos-z = 0
  1. 在电脑上打开命令提示符或终端窗口.

  • @Todo: will be correct soon

例如,在 Ubuntu (Linux) 上:

cd leaps_gateway_hub/
  1. 安装 LEAPS 网关 Docker 软件包并运行:

注解

@Todo: will be correct soon

sudo docker run -d -it --name some_name --privileged -v /dev/bus/usb:/dev/bus/usb -v /path/to/data/data/:/app/data/ leapslabs/leaps_gateway:tag /app/leaps_gateway --cfg /app/data/leaps_gateway.conf

@Todo: will be correct soon

  • 推荐的运行选项

    • --user $(id -u):$(id -g) 在特定用户和组下运行实例.

    • @Todo: will be correct soon

  1. @Todo: will be correct soon

例如,在 Ubuntu (Linux) 上:

sudo docker run -d -it --name leaps_gateway --privileged -v /dev/bus/usb:/dev/bus/usb -v "$(pwd)"/data/:/app/data leapslabs/leaps_gateway:latest /app/leaps-gateway -c /app/data/leaps-gateway.conf

Unable to find image 'leapslabs/leaps_gateway:latest' locally
latest: Pulling from leapslabs/leaps_gateway
a458657ccc71: Pull complete
Digest: sha256:a19b127656d41d8607f043c2c83924e5b9a5cbd4dc23cfbed070be3b9cfc6b9a
Status: Downloaded newer image for leapslabs/leaps_gateway:latest
320d3768289874e063619f75faca7a24dd75a08884df8cd8fb2cc9b54c6f0a46
  1. 确认安装成功,运行:

例如,在 Ubuntu (Linux) 上:

sudo docker ps

CONTAINER ID   IMAGE                    COMMAND                  CREATED          STATUS                          PORTS     NAMES
b1145b72db35   leapslabs/leaps_gateway:latest   "sh -c 'cd /app &&  …"   37 seconds ago   11 seconds ago                           leaps_gateway

@Todo: will be correct soon


@Todo: will be correct soon

@Todo: will be correct soon

  • @Todo: will be correct soon

  • @Todo: will be correct soon

  • @Todo: will be correct soon

  • @Todo: will be correct soon


网络配置

  • 记录

    # Logging level, default is 3 (0=none, 1=error, 2=warning, 3=info, 4=debug, 5=verbose).
    log-level = 0
    
    # Path to log file. Comment out to disable logging to file (log to stdio instead).
    log-file = leaps-gateway.log
    
  • @Todo: will be correct soon

    # Default: localhost
    leaps-server-host = 192.168.1.1 # Your Computer's IP Address
    
    # LEAPS Server port
    # Default: 7777
    leaps-server-port = 7777
    
  • @Todo: will be correct soon

    # Vendor ID, default is 0x1915, possible values are (0x1915-Nordic, 0x04d8-Microchip)
    # Allowed values: 16-bit number in decimal, hexadecimal or octal format
    # uwbs-usb-dev-vid = 0x04d8
    uwbs-usb-dev-vid = 0x1915
    
    # Product ID, default is 0xe8e3 for LEAPS RTLS devices
    # Allowed values: 16-bit number in decimal, hexadecimal or octal format
    uwbs-usb-dev-pid = 0xe8e3
    
  • @Todo: will be correct soon

    # Bridge mode
    # Allowed values: 0=Disable 1=Enable
    # Default: (keep-current)
    uwbs-bridge = 0
    
    # Initiator mode
    # Allowed values: 0=Disable 1=Enable
    # Default: (keep-current)
    uwbs-initiator = 0
    
    # UWBMAC Profile ID
    # Default: (keep-current)
    uwbs-profile-id = 0
    
    # LEDs mode
    # Allowed values: 0=Disable 1=Enable
    # Default: (keep-current)
    uwbs-led = 1
    
    # UWB encryption
    # Allowed values: 0=Disable 1=Enable
    # Default: (keep-current)
    uwbs-enc = 0
    
    # UWB firmware update
    # Allowed values: 0=Disable 1=Enable
    # Default: (keep-current)
    uwbs-fwup = 0
    
    # UWB mode
    # Allowed values: 0=Off 1=Passive 2=Active
    # Default: (keep-current)
    uwbs-uwb = 2
    
    # UWB Backhaul Routing
    # Allowed values: 0=Off 1=On 2=Auto
    # Default: (keep-current)
    uwbs-bh = 1
    
    # BLE
    # Allowed values: 0=Off 1=On
    # Default: (keep-current)
    uwbs-ble = 1
    
    # UWB encryption key
    # Allowed values: 128-bit number in hexadecimal format
    # Default: (keep-current)
    uwbs-enc-key = 11111111222222223333333344444444
    
    # UWB network PANID
    # Allowed values: 16-bit number in decimal, hexadecimal or octal format
    # Default: (keep-current)
    uwbs-panid = 0x0000
    
    # Device label
    # Default: (keep-current)
    uwbs-label = gw-uwbs
    
    # Device position in mm [x, y, z]
    # Default: (keep-current)
    uwbs-pos-x = 0
    uwbs-pos-y = 0
    uwbs-pos-z = 0
    

故障排除

  • @Todo: will be correct soon

  • @Todo: will be correct soon