tirtc-device-builder 0.9.1 → 0.9.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tirtc-device-builder",
3
- "version": "0.9.1",
3
+ "version": "0.9.2",
4
4
  "description": "Codex workflows for building and validating TiRTC device firmware across supported chip platforms.",
5
5
  "author": {
6
6
  "name": "TangeAI",
package/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  This project follows Semantic Versioning.
4
4
 
5
+ ## 0.9.2
6
+
7
+ - Pin ESP32 Device Kit 1.1.3 with captive portal discovery through DHCP option
8
+ 114, wildcard DNS, and HTTP fallback redirects.
9
+ - Require `captive_portal: true` in the selected SoftAP Hardware IR contract and
10
+ reject Kit packaging when the runtime, component wiring, or instructions omit
11
+ automatic portal discovery.
12
+
5
13
  ## 0.9.1
6
14
 
7
15
  - Pin ESP32 Device Kit 1.1.2 with an open `TiRTC-` SoftAP and provisioning at
package/README.md CHANGED
@@ -12,7 +12,7 @@ H5/AI 的 ESP32-S3 托管模板、协议文档和 TiRTC SDK 已打包在独立
12
12
 
13
13
  - npm 包:[tirtc-device-builder](https://www.npmjs.com/package/tirtc-device-builder)
14
14
  - GitHub 仓库:[tangeai/tirtc-device-builder](https://github.com/tangeai/tirtc-device-builder)
15
- - ESP32 Device Kit:[kit-esp32s3-v1.1.2](https://github.com/tangeai/tirtc-device-builder/releases/tag/kit-esp32s3-v1.1.2)
15
+ - ESP32 Device Kit:[kit-esp32s3-v1.1.3](https://github.com/tangeai/tirtc-device-builder/releases/tag/kit-esp32s3-v1.1.3)
16
16
 
17
17
  文档导航:
18
18
 
@@ -283,7 +283,7 @@ board-materials/
283
283
  | ESP-IDF | 5.5.x |
284
284
  | 自动安装版本 | ESP-IDF v5.5.4 |
285
285
  | TiRTC SDK | `espressif-esp32s3/2.3.0` |
286
- | ESP32 Device Kit | 1.1.2 |
286
+ | ESP32 Device Kit | 1.1.3 |
287
287
  | Node.js | 18 或更高版本 |
288
288
  | 支持自动安装的系统 | Linux、WSL、macOS |
289
289
  | 原生 Windows | 使用 Espressif 官方安装器准备 ESP-IDF,再重新运行检查 |
@@ -392,7 +392,7 @@ Cline 当前还需要在 `Settings → Features → Enable Skills` 中启用实
392
392
  |---|---|
393
393
  | Agent Skill | 上表中所选目录下的 `tirtc-esp32-builder` |
394
394
  | 托管根目录 | `~/.tirtc-device-builder` |
395
- | Device Kit | `~/.tirtc-device-builder/kits/esp32s3/1.1.2` |
395
+ | Device Kit | `~/.tirtc-device-builder/kits/esp32s3/1.1.3` |
396
396
  | ESP-IDF | `~/.tirtc-device-builder/esp-idf-v5.5.4` |
397
397
  | Espressif 工具 | `~/.tirtc-device-builder/espressif` |
398
398
  | 安装记录 | `~/.tirtc-device-builder/config.json` |
@@ -437,7 +437,7 @@ npx --yes tirtc-device-builder@latest setup esp32 --install \
437
437
 
438
438
  ```bash
439
439
  npx --yes tirtc-device-builder@latest setup esp32 --install \
440
- --kit-archive /absolute/path/tirtc-esp32s3-kit-1.1.2.tar.gz
440
+ --kit-archive /absolute/path/tirtc-esp32s3-kit-1.1.3.tar.gz
441
441
  ```
442
442
 
443
443
  安装器仍会核对固定的 SHA-256、目录结构、清单和每个资源文件,不接受未经验证的同名压缩包。
@@ -652,7 +652,7 @@ bootloader、分区表和应用镜像;无需手工维护多条 `esptool.py`
652
652
 
653
653
  ### Wi-Fi 凭证和设备绑定
654
654
 
655
- SoftAP 是可选方案,不是接入前提。Hardware IR 要根据 BSP 的实际能力和产品要求,选择 SoftAP、BLE、SmartConfig、安全工厂/NVS 注入、不纳入版本控制的开发配置,或有文档的自定义方案。若选择 SoftAP,热点名必须以 `TiRTC-` 开头、使用开放认证(无需密码),AP 网关和配网页面地址固定为 `192.168.6.1`(`http://192.168.6.1`)。这些值要写入 Hardware IR 并通过门禁;目标 WLAN 的 SSID 和密码仍不得写死在源码中。
655
+ SoftAP 是可选方案,不是接入前提。Hardware IR 要根据 BSP 的实际能力和产品要求,选择 SoftAP、BLE、SmartConfig、安全工厂/NVS 注入、不纳入版本控制的开发配置,或有文档的自定义方案。若选择 SoftAP,热点名必须以 `TiRTC-` 开头、使用开放认证(无需密码),AP 网关和配网页面地址固定为 `192.168.6.1`(`http://192.168.6.1`),并通过 DHCP Option 114、通配 DNS 和 HTTP 回退启用 captive portal 自动发现。系统没有自动弹窗时仍可手动打开该 HTTP 地址;HTTPS 不能透明重定向。这些值要写入 Hardware IR 并通过门禁;目标 WLAN 的 SSID 和密码仍不得写死在源码中。
656
656
 
657
657
  无论选择哪种方法,都要有当前 PCB/BSP 的支持证据,凭证不能进入 Git、源码或报告,并且要保留清除或重配入口。没有 SoftAP、但支持工厂 NVS 注入的设备同样可以接入。只要工程提交了明文密码,Hardware IR v2 门禁就会判为 `BLOCKED`。
658
658
 
@@ -820,7 +820,7 @@ npx --yes tirtc-device-builder@latest setup esp32 --install --force-skill
820
820
 
821
821
  ```bash
822
822
  npx --yes tirtc-device-builder@latest setup esp32 --install \
823
- --kit-archive /absolute/path/tirtc-esp32s3-kit-1.1.2.tar.gz
823
+ --kit-archive /absolute/path/tirtc-esp32s3-kit-1.1.3.tar.gz
824
824
  ```
825
825
 
826
826
  安装器会校验 SHA-256 和内部文件清单。如果校验不一致,请重新获取官方 Release 附件,不要跳过校验。
@@ -932,25 +932,25 @@ python3 ~/.codex/skills/.system/plugin-creator/scripts/validate_plugin.py .
932
932
  ```bash
933
933
  npm run pack:esp32-kit -- \
934
934
  --source /absolute/path/tirtc-server-example/thing-connect \
935
- --kit-version 1.1.2
935
+ --kit-version 1.1.3
936
936
  ```
937
937
 
938
938
  输出位于 `dist/`:
939
939
 
940
940
  ```text
941
- tirtc-esp32s3-kit-1.1.2.tar.gz
942
- tirtc-esp32s3-kit-1.1.2.tar.gz.sha256
941
+ tirtc-esp32s3-kit-1.1.3.tar.gz
942
+ tirtc-esp32s3-kit-1.1.3.tar.gz.sha256
943
943
  ```
944
944
 
945
945
  校验后推送独立的 `kit-esp32s3-v<version>` 标签。`publish-kit.yml` 会从 metadata 固定的上游 commit 重建压缩包、核对 SHA-256,并使用 GitHub Actions token 创建 Release:
946
946
 
947
947
  ```bash
948
948
  cd dist
949
- sha256sum -c tirtc-esp32s3-kit-1.1.2.tar.gz.sha256
949
+ sha256sum -c tirtc-esp32s3-kit-1.1.3.tar.gz.sha256
950
950
  cd ..
951
951
 
952
- git tag -a kit-esp32s3-v1.1.2 -m "TiRTC ESP32-S3 Device Kit 1.1.2"
953
- git push origin kit-esp32s3-v1.1.2
952
+ git tag -a kit-esp32s3-v1.1.3 -m "TiRTC ESP32-S3 Device Kit 1.1.3"
953
+ git push origin kit-esp32s3-v1.1.3
954
954
  ```
955
955
 
956
956
  metadata 中的版本、标签、上游 commit 和期望 SHA-256 必须与本地可复现打包结果一致;工作流不会从浮动的 `main` 取发布内容。
@@ -961,8 +961,8 @@ metadata 中的版本、标签、上游 commit 和期望 SHA-256 必须与本地
961
961
 
962
962
  ```bash
963
963
  npm test
964
- git tag -a v0.9.1 -m "v0.9.1"
965
- git push origin v0.9.1
964
+ git tag -a v0.9.2 -m "v0.9.2"
965
+ git push origin v0.9.2
966
966
  ```
967
967
 
968
968
  不要重复发布已经存在的 npm 版本。版本变化同步更新 `package.json`、`.codex-plugin/plugin.json` 和发布说明。
@@ -1,9 +1,9 @@
1
1
  export const ESP32_KIT = Object.freeze({
2
- archiveName: "tirtc-esp32s3-kit-1.1.2.tar.gz",
3
- archiveRoot: "tirtc-esp32s3-kit-1.1.2",
4
- releaseTag: "kit-esp32s3-v1.1.2",
5
- sha256: "93dc63ee6450d54e7f31f9a2f0880b462647faa52fd7e70c287bb71f8d3e0b47",
6
- sourceCommit: "9aaf47eb3e120ac146b72140e5357b36f4b131f5",
7
- url: "https://github.com/tangeai/tirtc-device-builder/releases/download/kit-esp32s3-v1.1.2/tirtc-esp32s3-kit-1.1.2.tar.gz",
8
- version: "1.1.2",
2
+ archiveName: "tirtc-esp32s3-kit-1.1.3.tar.gz",
3
+ archiveRoot: "tirtc-esp32s3-kit-1.1.3",
4
+ releaseTag: "kit-esp32s3-v1.1.3",
5
+ sha256: "3239d3045a82082beb73b9bbbd2217e9da278bf8fbbe2941ae9131a20830d45c",
6
+ sourceCommit: "e685e33c6622fedfed66e9132447ddaae1e2a40e",
7
+ url: "https://github.com/tangeai/tirtc-device-builder/releases/download/kit-esp32s3-v1.1.3/tirtc-esp32s3-kit-1.1.3.tar.gz",
8
+ version: "1.1.3",
9
9
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tirtc-device-builder",
3
- "version": "0.9.1",
3
+ "version": "0.9.2",
4
4
  "description": "Install and run TiRTC device-development Agent Skills across popular coding clients.",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -70,9 +70,9 @@ implementation and build facts. Stop before code only for a genuine user choice,
70
70
  unknown wiring/identity, unavailable matching SDK, or required public-contract
71
71
  change.
72
72
 
73
- When SoftAP is the selected Wi-Fi method, carry the fixed SSID, open-auth and
74
- IPv4 [product contract](references/hardware-ir.md#softap-product-contract) into
75
- the IR, generated adapter, user-facing instructions and build checks.
73
+ When SoftAP is the selected Wi-Fi method, carry the fixed SSID, open-auth, IPv4
74
+ and captive-portal [product contract](references/hardware-ir.md#softap-product-contract)
75
+ into the IR, generated adapter, user-facing instructions and build checks.
76
76
 
77
77
  ## 5. Generate and port
78
78
 
@@ -74,7 +74,7 @@ printf '%s\n' "$TIRTC_THING_CONNECT_ROOT"
74
74
  python3 <skill-dir>/scripts/doctor.py \
75
75
  --expected-idf 5.5 \
76
76
  --target esp32s3 \
77
- --thing-connect-root ~/.tirtc-device-builder/kits/esp32s3/1.1.2 \
77
+ --thing-connect-root ~/.tirtc-device-builder/kits/esp32s3/1.1.3 \
78
78
  --require-workspace
79
79
  ```
80
80
 
@@ -1 +1 @@
1
- 0.9.1
1
+ 0.9.2
@@ -27,7 +27,7 @@
27
27
 
28
28
  接入方式:
29
29
  - Wi-Fi:<选择一种,或写“根据 BSP 选择”>
30
- - 选择 SoftAP 时:热点名以 `TiRTC-` 开头、开放认证无需密码,AP 网关和配网页面为 `192.168.6.1` / `http://192.168.6.1`
30
+ - 选择 SoftAP 时:热点名以 `TiRTC-` 开头、开放认证无需密码,AP 网关和配网页面为 `192.168.6.1` / `http://192.168.6.1`,启用 DHCP/DNS/HTTP captive portal 自动发现并保留手动打开地址的回退说明
31
31
  - 设备绑定:<选择一种,或写“根据平台合同选择”>
32
32
 
33
33
  工程:
@@ -8,7 +8,7 @@
8
8
 
9
9
  ```bash
10
10
  export TIRTC_AGENT_CLIENT=codex
11
- npx --yes tirtc-device-builder@0.9.1 setup esp32 --install \
11
+ npx --yes tirtc-device-builder@0.9.2 setup esp32 --install \
12
12
  --client "$TIRTC_AGENT_CLIENT" --force-skill
13
13
  ```
14
14
 
@@ -17,11 +17,11 @@ npx --yes tirtc-device-builder@0.9.1 setup esp32 --install \
17
17
  本轮第一步先只读运行:
18
18
 
19
19
  ```bash
20
- npx --yes tirtc-device-builder@0.9.1 --version
21
- npx --yes tirtc-device-builder@0.9.1 setup esp32 --client "$TIRTC_AGENT_CLIENT"
20
+ npx --yes tirtc-device-builder@0.9.2 --version
21
+ npx --yes tirtc-device-builder@0.9.2 setup esp32 --client "$TIRTC_AGENT_CLIENT"
22
22
  ```
23
23
 
24
- 必须根据命令的实际输出和本机文件确认:npm 包为 0.9.1、已安装 Skill 的 `VERSION` 为 0.9.1、所选 Device Kit 的 `manifest.json` 中 `kit_version` 为 1.1.2,并且 Doctor 对 `--expected-kit 1.1.2` 输出 `OVERALL: PASS`。Plugin manifest 不属于这种 npm 安装方式的运行时前置条件,不得把不可访问的 Plugin 版本当作阻塞项。如果版本不一致、Skill 是在当前会话启动后才安装,或环境检查未通过,停止并报告前置条件不成立;不要在当前会话中替换 Skill 后继续生成工程。
24
+ 必须根据命令的实际输出和本机文件确认:npm 包为 0.9.2、已安装 Skill 的 `VERSION` 为 0.9.2、所选 Device Kit 的 `manifest.json` 中 `kit_version` 为 1.1.3,并且 Doctor 对 `--expected-kit 1.1.3` 输出 `OVERALL: PASS`。Plugin manifest 不属于这种 npm 安装方式的运行时前置条件,不得把不可访问的 Plugin 版本当作阻塞项。如果版本不一致、Skill 是在当前会话启动后才安装,或环境检查未通过,停止并报告前置条件不成立;不要在当前会话中替换 Skill 后继续生成工程。
25
25
 
26
26
  工作区与 clean-room 边界:
27
27
  - 将启动 Agent 客户端时的当前目录定义为 `WORKSPACE_ROOT`。
@@ -16,7 +16,7 @@ The automatic branch never runs `sudo` or modifies a persistent shell profile. W
16
16
  When `<setup-root>/env.sh` exists, use it only as an activation prefix for the current command:
17
17
 
18
18
  ```bash
19
- bash -lc '. "<setup-root>/env.sh" && python3 "<skill-dir>/scripts/doctor.py" --expected-idf 5.5 --expected-kit 1.1.2 --target esp32s3 --require-workspace'
19
+ bash -lc '. "<setup-root>/env.sh" && python3 "<skill-dir>/scripts/doctor.py" --expected-idf 5.5 --expected-kit 1.1.3 --target esp32s3 --require-workspace'
20
20
  ```
21
21
 
22
22
  The helper contains paths, not device or network credentials. Read `<setup-root>/config.json` when exact managed paths are needed; the environment helper does not authorize unrelated downloads, shell-profile changes, flashing, or credential writes.
@@ -26,7 +26,7 @@ Run the doctor before generation, build, flash, or monitor:
26
26
  ```bash
27
27
  python3 <skill-dir>/scripts/doctor.py \
28
28
  --expected-idf 5.5 \
29
- --expected-kit 1.1.2 \
29
+ --expected-kit 1.1.3 \
30
30
  --target esp32s3 \
31
31
  --require-workspace
32
32
  ```
@@ -73,11 +73,16 @@ When the selected method is SoftAP:
73
73
  - assign the AP netif, gateway and provisioning server `192.168.6.1/24`, serve
74
74
  the setup page at `http://192.168.6.1`, and lease clients from that subnet.
75
75
  With ESP-IDF, stop DHCP before changing the AP netif IP information and
76
- restart it afterward.
76
+ restart it afterward;
77
+ - enable captive portal discovery with DHCP option 114, wildcard DNS resolving
78
+ names to `192.168.6.1`, and an HTTP fallback redirect to the setup page. Keep
79
+ the direct HTTP address documented because client auto-popup is not
80
+ guaranteed and HTTPS cannot be transparently redirected.
77
81
 
78
82
  Record these values on the selected SoftAP method as `ssid_prefix: "TiRTC-"`,
79
- `auth_mode: "open"`, and `ipv4_address: "192.168.6.1"`. The Hardware IR gate
80
- returns `NEEDS_CONFIRMATION` when one is missing and `BLOCKED` when one differs.
83
+ `auth_mode: "open"`, `ipv4_address: "192.168.6.1"`, and
84
+ `captive_portal: true`. The Hardware IR gate returns `NEEDS_CONFIRMATION` when
85
+ one is missing and `BLOCKED` when one differs.
81
86
  Keep the provisioning endpoints available only while onboarding is active, and
82
87
  disable the AP or restart into STA mode after credentials are accepted.
83
88
 
@@ -64,6 +64,7 @@ WIFI_METHOD_TYPES = {
64
64
  SOFTAP_SSID_PREFIX = "TiRTC-"
65
65
  SOFTAP_AUTH_MODE = "open"
66
66
  SOFTAP_IPV4_ADDRESS = "192.168.6.1"
67
+ SOFTAP_CAPTIVE_PORTAL = True
67
68
  BINDING_METHOD_TYPES = {
68
69
  "verification_code",
69
70
  "factory_bound",
@@ -450,6 +451,11 @@ def validate_onboarding(
450
451
  if method_type == "softap":
451
452
  for field in ("ssid_prefix", "auth_mode", "ipv4_address"):
452
453
  nullable_string(method.get(field), f"{prefix}.{field}", errors)
454
+ nullable_bool(
455
+ method.get("captive_portal"),
456
+ f"{prefix}.captive_portal",
457
+ errors,
458
+ )
453
459
  nullable_bool(method.get("available"), f"{prefix}.available", errors)
454
460
  validate_verification(
455
461
  method.get("verification"), f"{prefix}.verification", errors
@@ -937,6 +943,7 @@ def wifi_requirement(onboarding: dict[str, Any]) -> Requirement:
937
943
  ("ssid_prefix", SOFTAP_SSID_PREFIX, "SSID prefix"),
938
944
  ("auth_mode", SOFTAP_AUTH_MODE, "authentication mode"),
939
945
  ("ipv4_address", SOFTAP_IPV4_ADDRESS, "IPv4 address"),
946
+ ("captive_portal", SOFTAP_CAPTIVE_PORTAL, "captive portal"),
940
947
  )
941
948
  for field, expected, label in softap_fields:
942
949
  value = method.get(field)