← 返回
未分类 中文

Claw Keyboard

Control keyboard RGB backlight, custom LEDs, macros, key mapping, and profile settings via USB HID. Use when the user asks to control keyboard lighting, mana...
通过USB HID控制键盘RGB背光、自定义LED、宏、按键映射和配置文件设置。用于用户需要控制键盘灯光、管理...
dionren dionren 来源
未分类 clawhub v1.0.4 1 版本 99783.5 Key: 无需
★ 0
Stars
📥 461
下载
💾 2
安装
1
版本
#latest

概述

claw-keyboard

Use claw-keyboard to discover and control USB keyboards that support the vendor HID protocol (UsagePage 0xFF60, Usage 0x61). Tested with LUXSWH R68pro. Supports RGB backlight, custom per-key LEDs, macros, key remapping, profile tuning, KLE layout rendering, and multi-keyboard management.

Quick start

  • claw-keyboard discover — scan for connected keyboards
  • claw-keyboard info — show keyboard details (rows, cols, firmware, mode, RGB state)
  • claw-keyboard rgb color red — set backlight to red
  • claw-keyboard rgb brightness 128 — set brightness (0-255)
  • claw-keyboard rgb effect 1 — set lighting effect mode (0-20)
  • claw-keyboard rgb save — persist current settings to flash

Device selection

When multiple keyboards are connected, use --device to target a specific one. Run discover to list available paths.

RGB control

  • claw-keyboard rgb status — show current brightness, effect, speed, color
  • claw-keyboard rgb color — set color by name (red, green, blue, cyan, purple, orange, yellow, white) or hue value (0-255)
  • claw-keyboard rgb brightness <0-255> — set LED brightness
  • claw-keyboard rgb effect <0-20> — set lighting effect mode (0 = rainbow, 1 = solid, 2-20 = animations)
  • claw-keyboard rgb speed <0-5> — set animation speed (0 = slowest, 5 = fastest)
  • claw-keyboard rgb save — write current config to flash (avoid frequent calls — flash has limited write cycles)

Custom LED control

  • claw-keyboard led on — turn on a single LED at row/col position
  • claw-keyboard led off — turn off a single LED
  • claw-keyboard led clear — turn off all LEDs
  • claw-keyboard led list — list currently lit LED positions
  • claw-keyboard led sync-start — start onboard LED effect sync (keyboard reports LED data to PC)
  • claw-keyboard led sync-stop — stop onboard LED effect sync

Key mapping

  • claw-keyboard keymap read — dump current key layout (all layers)
  • claw-keyboard keymap layers — show number of supported layers
  • claw-keyboard keymap get — read the 2-byte HID key value at a position
  • claw-keyboard keymap set — set a single key (4-digit hex, e.g. 0029 = Escape). Requires user confirmation — this changes a physical key binding on the keyboard.
  • claw-keyboard keymap write — write complete keymap from hex file. Requires user confirmation — this overwrites all key bindings.

Macro management

  • claw-keyboard macro list — show macro count, storage usage, and parsed macros
  • claw-keyboard macro clear — erase all macros. Requires user confirmation — this deletes all macros permanently.
  • claw-keyboard macro dump — hex dump of raw macro storage data
  • claw-keyboard macro set [...] — configure macros from action strings (replaces all existing macros). Requires user confirmation.
  • Action format: tap:, press:, release:, delay: separated by commas
  • Example: claw-keyboard macro set "press:0xE0,tap:0x06,release:0xE0" (Ctrl+C)

Profile parameters

  • claw-keyboard profile get — read profile parameters (debounce, TAP layer, sleep, power-down)
  • claw-keyboard profile set — configure profile parameters (use --debounce, --tap, --sleep, --powerdown flags)

KLE layout tools

  • claw-keyboard kle info — show parsed KLE layout summary
  • claw-keyboard kle render — render KLE JSON layout to SVG

Other

  • claw-keyboard reset — factory reset keyboard. Requires explicit user confirmation — this permanently erases all settings, key mappings, and macros from the keyboard, restoring it to factory defaults. Only run when the user explicitly requests a factory reset.

Safety

The following commands modify keyboard hardware state and should only be run with explicit user confirmation. Never run these autonomously:

  • reset — factory reset (irreversible, erases everything)
  • macro clear / macro set — erases or replaces all macros
  • keymap set / keymap write — changes key bindings
  • rgb save — writes to flash (limited write cycles)

Read-only commands (discover, info, rgb status, keymap read, macro list, profile get, kle info) are always safe to run.

Notes

  • The tool auto-discovers keyboards by scanning for HID interfaces with UsagePage 0xFF60 and Usage 0x61, then verifying via a challenge-response handshake.
  • Not all keyboards expose the vendor HID interface. If discover finds nothing, the keyboard may not support this protocol.
  • On macOS, you may need to grant HID access permission to the terminal application in System Settings > Privacy & Security > Input Monitoring.
  • On Linux, you may need udev rules to access USB HID devices without root. Create /etc/udev/rules.d/99-claw-keyboard.rules with SUBSYSTEM=="hidraw", ATTRS{idVendor}=="1a86", MODE="0666" and run sudo udevadm control --reload-rules.
  • SHA256 checksums for all binaries are available in the SHA256SUMS file on the GitHub Releases page. Verify after downloading: shasum -a 256 -c SHA256SUMS.
  • Use --json flag for machine-readable output.

版本历史

共 1 个版本

  • v1.0.4 当前
    2026-03-30 19:04 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

dev-programming

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 72 📥 181,758
dev-programming

Mcporter

steipete
使用 mcporter CLI 直接列出、配置、认证及调用 MCP 服务器/工具(支持 HTTP 或 stdio),涵盖临时服务器、配置编辑及 CLI/类型生成功能。
★ 195 📥 67,608
ai-agent

Adb Claw

dionren
Your eyes, hands, and ears on Android. See the screen (screenshot + indexed UI tree), interact (tap, swipe, scroll, type
★ 2 📥 1,224