Two usability issues found while debugging .rpk installation on a Xiaomi Smart Band 10 Pro (M2552B1, global FW 3.201.016) in Chrome on macOS. BandBurg itself works well — the connection, device info and watchface list are all fine.
1. All WASM errors surface in the UI as undefined
The operation log only ever shows:
文件安装失败: xxx.rpk - 调用 miwear_install 失败: undefined
But the DevTools console has the actual reason:
wasm-client.js:329 调用WASM命令 miwear_install 失败: invalid watchface id
wasm-client.js:330 错误详情: undefined
wasm-client.js:329 调用WASM命令 miwear_install 失败:
watchface install failed: InstallFailed [modules\core\src\device\xiaomi\components\install.rs:340]
Those messages are precise and immediately actionable; undefined is not. The cause looks like the UI reading error.stack (undefined for values thrown from WASM) or error.message instead of the error value itself — note that line 330 already prints 错误详情: undefined for the same reason.
Suggestion: in the catch path, fall back to String(error) / error.toString() when message/stack are absent, and surface that in the operation log.
I spent several hours attributing undefined to hardware/connection problems when the WASM had been telling the truth all along.
2. The BLE option in 连接类型 does nothing
src/App.tsx offers:
<option value="SPP">SPP</option>
<option value="BLE">BLE</option>
but the bundled astrobox_ng_wasm.js contains no Web Bluetooth calls at all:
navigator.bluetooth / requestDevice / getPrimaryService → 0 occurrences
requestPort / SerialPort → 6 occurrences
wasm-client.js:228 also defaults to args.connect_type || 'SPP'. Selecting BLE still goes through navigator.serial.requestPort(), so on platforms where the band exposes no serial port the connection fails with Failed to execute 'requestPort' on 'Serial' regardless of the choice.
Suggestion: hide or disable the BLE option until the WASM build implements it, or note in the UI that only SPP is supported in the browser build.
Platform note that may help other macOS users
macOS only creates /dev/cu.XiaomiSmartBand10Pro9D83 after the band has been freshly paired via Settings → Connect new phone. Before that the Serial chooser is empty and the connection cannot be established — this is easy to mistake for a BandBurg bug. Chrome additionally logs Chooser dialog is not displaying a port blocked by the Serial blocklist for the band's other Bluetooth service UUIDs, which is expected noise.
Environment: Chrome 150, macOS 15, Smart Band 10 Pro M2552B1 FW 3.201.016, SPP.
Two usability issues found while debugging
.rpkinstallation on a Xiaomi Smart Band 10 Pro (M2552B1, global FW3.201.016) in Chrome on macOS. BandBurg itself works well — the connection, device info and watchface list are all fine.1. All WASM errors surface in the UI as
undefinedThe operation log only ever shows:
But the DevTools console has the actual reason:
Those messages are precise and immediately actionable;
undefinedis not. The cause looks like the UI readingerror.stack(undefined for values thrown from WASM) orerror.messageinstead of the error value itself — note that line 330 already prints错误详情: undefinedfor the same reason.Suggestion: in the catch path, fall back to
String(error)/error.toString()whenmessage/stackare absent, and surface that in the operation log.I spent several hours attributing
undefinedto hardware/connection problems when the WASM had been telling the truth all along.2. The
BLEoption in 连接类型 does nothingsrc/App.tsxoffers:but the bundled
astrobox_ng_wasm.jscontains no Web Bluetooth calls at all:wasm-client.js:228also defaults toargs.connect_type || 'SPP'. SelectingBLEstill goes throughnavigator.serial.requestPort(), so on platforms where the band exposes no serial port the connection fails withFailed to execute 'requestPort' on 'Serial'regardless of the choice.Suggestion: hide or disable the
BLEoption until the WASM build implements it, or note in the UI that only SPP is supported in the browser build.Platform note that may help other macOS users
macOS only creates
/dev/cu.XiaomiSmartBand10Pro9D83after the band has been freshly paired via Settings → Connect new phone. Before that the Serial chooser is empty and the connection cannot be established — this is easy to mistake for a BandBurg bug. Chrome additionally logsChooser dialog is not displaying a port blocked by the Serial blocklistfor the band's other Bluetooth service UUIDs, which is expected noise.Environment: Chrome 150, macOS 15, Smart Band 10 Pro
M2552B1FW3.201.016, SPP.