USB companion radio firmware on Heltec V4.3: when the name has length 6, APP_START requests stall
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 25/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 領域
- embedded-iot
調査の方向性
Start by reproducing with the reporter's shell script against a Heltec V4.3 running the companion USB firmware, using meshcli to set a six-character name and then time the infos command. The reporter links a 64-byte SELF_INFO reply for APP_START to the USB serial layer, so the serial transmit path is the place to look. Done means infos responds in milliseconds for a six-character name as it does for seven, and the fix is confirmed on hardware.
索引モデルが issue の本文から書いたものです。
説明
I am using a Heltec V4.3 OLED board with Companion radio USB v1.18.0-81dbae5 (14) firmware (heltec_v4_companion_radio_usb) and meshcli v1.6.10 on Ubuntu 26.04.
When the name has length of 6 characters, requesting "infos" via USB takes up to ~20 seconds instead of the usual milliseconds with other name lengths.
Reproducer script:
#!/bin/bash
PORT=${1:-/dev/ttyACM0}
for name in abcdef abcdefg; do
echo
echo "=== name '$name'"
uv run meshcli -s "$PORT" set name "$name"
sleep 5
for i in 1 2 3; do
echo "run $i:"
time uv run meshcli -s "$PORT" infos >/dev/null
sleep 1
done
done
Output:
=== name 'abcdef'
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdefg running on a v1.18.0-81dbae5 (14) fw.
ok
run 1:
INFO:meshcore:Serial Connection started
INFO:meshcore:No response from meshcore node, trying to force DTR = True
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdef running on a v1.18.0-81dbae5 (14) fw.
real 0m18.138s
user 0m0.099s
sys 0m0.021s
run 2:
INFO:meshcore:Serial Connection started
INFO:meshcore:No response from meshcore node, trying to force DTR = True
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdef running on a v1.18.0-81dbae5 (14) fw.
real 0m7.542s
user 0m0.104s
sys 0m0.019s
run 3:
INFO:meshcore:Serial Connection started
INFO:meshcore:No response from meshcore node, trying to force DTR = True
INFO:meshcore:Serial Connection started
INFO:meshcore:No response from meshcore node, trying to invert dtr (now False)
INFO:meshcore:Serial Connection started
ERROR:meshcore:No response from meshcore node, disconnecting
ERROR:meshcore:Are you sure your node is a serial companion ?
ERROR:meshcore:To connect to a repeater, use -r option.
real 0m8.127s
user 0m0.084s
sys 0m0.030s
=== name 'abcdefg'
INFO:meshcore:Serial Connection started
INFO:meshcore:No response from meshcore node, trying to force DTR = True
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdef running on a v1.18.0-81dbae5 (14) fw.
ok
run 1:
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdefg running on a v1.18.0-81dbae5 (14) fw.
real 0m0.116s
user 0m0.095s
sys 0m0.019s
run 2:
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdefg running on a v1.18.0-81dbae5 (14) fw.
real 0m0.115s
user 0m0.094s
sys 0m0.018s
run 3:
INFO:meshcore:Serial Connection started
INFO:meshcore:Connected to abcdefg running on a v1.18.0-81dbae5 (14) fw.
real 0m0.115s
user 0m0.089s
sys 0m0.023s
Note now with name length 7, the infos command takes about 100 ms (as expected), but with length 6 it can take up to ~20 s. This causes timeouts when trying to use this MeshCore device with Home Assistant (i.e. Home Assistant fails to connect to the device due to these timeouts).
An investigation performed by an AI agent suggests that this issue happens because when the name has length 6, the APP_START reply SELF_INFO payload has size 64 bytes, and the USB interface treats it as if the host is about to send more data (i.e. it waits and does not transmit it over USB).
A fork of MeshCore called Offband seems to had faced a similar issue and fixed it downstream: https://github.com/OffbandMesh/meshcore-firmware/issues/1037, https://github.com/OffbandMesh/meshcore-firmware/issues/1093.
Possibly related: MeshCore #3751 (ESP32-S3 HWCDC TX race on core 2.0.17, fixed by arduino-esp32 #12606 in core 3.3.9). That PR also has the ISR send a terminating ZLP once the TX ring is empty, so moving to core 3.3.9 or later may fix this too. Not tested.
- 主要言語
- C
- スター
- 3.9k
- フォーク
- 1.5k
- 平均マージ
- 2日 19時間
- マージ済み PR(30日)
- 61
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
meshcore-dev/MeshCore のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
meshcore-dev/MeshCore#4015 ·
メンテナーはふだん 2 日以内に返信
-
CMD_SET_DEFAULT_FLOOD_SCOPE leaves an older, longer name's tail after the new name対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
meshcore-dev/MeshCore#3891 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
meshcore-dev/MeshCore#3826 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
meshcore-dev/MeshCore#3825 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
meshcore-dev/MeshCore#3781 ·
メンテナーはふだん 2 日以内に返信
meshcore-dev/MeshCore の issue をすべて見る
似ている issue
-
CF_CFDP_S_SendFileData computes the file checksum from the SB buffer after CFE_SB_TransmitBufferオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
-
needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
389ds/389-ds-base#8251 ·
メンテナーはふだん 1 日以内に返信
-
bug data-types
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
ClickHouse/clickhouse-cpp#645 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
ROCm/hrx-system#3628 ·
メンテナーはふだん 1 日以内に返信