# Claude Meter

Claude Code usage limits and session state on an AWTRIX pixel clock

把 Claude Code 的用量限额搬到局域网里的像素钟上。

- id: tolixx-claude-meter
- author: tolixx
- repository: https://github.com/tolixx/claude-meter
- license: MIT
- shape: matrix
- scenes: home, ai
- boards: ESP32
- browser_playable: no
- preview: Project screenshots
- html: https://esp32gallery.com/projects/tolixx-claude-meter/
- html_zh: https://esp32gallery.com/zh/projects/tolixx-claude-meter/
- json: https://esp32gallery.com/data/catalog/projects/tolixx-claude-meter.json

## Hardware

Supported hardware: ESP32. Confirm the exact board revision and pin map in the upstream repository.

支持硬件：ESP32。烧录前请在上游仓库核对板卡版本与引脚定义。

## English

```
Your Claude Code rate limits, moved onto a pixel clock on the LAN. A Python daemon reads the rate_limits blob that Claude Code already hands to its status line command, plus small state files written by hooks, and pushes them to an AWTRIX 3 clock as a custom app: the 5-hour and weekly percentages on top, a bar underneath where a white pixel marks how much of the week has elapsed, and a blinking red dot when a session is waiting on a permission prompt. No API keys, no requests to Anthropic, Python 3 standard library only. A WAIT notification pops up with the project folder name and a short two-note beep. Frames carry a 15 minute lifetime so the display clears itself if the daemon dies. An optional handheld server on port 8787 answers permission prompts from an Anbernic RG40XX H.
```

## 中文

```
把 Claude Code 的用量限额搬到局域网里的像素钟上。一个 Python 守护进程去读 Claude Code 本来就会交给状态栏命令的 rate_limits，再读几个钩子写出的小状态文件，然后以自定义 app 的形式推给 AWTRIX 3 时钟：上面是五小时窗口和周用量两个百分比，下面一条进度条，白点标出这一周过去了多少，还有一颗红点在有会话等你批准权限时闪烁。整个过程不打 Anthropic 的接口，也不要 API key，只用 Python 3 标准库。有会话开始等待时，屏幕会弹出 WAIT 加项目文件夹名，并响一声两音提示。推上去的画面有 15 分钟有效期，守护进程挂了画面会自己消失。可选的掌机端服务跑在 8787 端口，用 Anbernic RG40XX H 远程批准权限询问。
```
