rp2040, rp2350: board stops responding after tinygo flash and ignores the 1200 bps reset

オープン
#6,036 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
go

調査の方向性

Start by reading the qbs reproduction from linked issue #6037 and trace how its four programs are flashed and their serial output checked. The report does not identify a likely source file or explain what differs from successful banner-only flashes, so first compare those program behaviors and reproduce the failure. Done means identifying and fixing the cause so repeated flash and reset cycles succeed on the affected RP2040 and RP2350 boards.

索引モデルが issue の本文から書いたものです。

説明

Symptom

On the Pico 2 W, Pico 2 and Pico, a board sometimes stops working after tinygo flash. On the RP2350 boards it still enumerates as the TinyGo USB device, but it sends no serial output and ignores the 1200 bps reset, so the next tinygo flash fails with unable to locate any volume: [RP2350]. Holding BOOTSEL and replugging recovers it. On the RP2040 it once disappeared from USB completely, with no RPI-RP2 drive either.

This is on one Apple silicon MacBook, with two different USB-A to USB-C adapters. TinyGo is dev at a0798aff built with LLVM 23. I have not tried another computer or a Linux host, so I do not know if TinyGo, macOS or the boards are at fault.

How to reproduce

Use qbs from #6037 on a Pico 2 W. It flashes four small programs in turn and checks their serial output. Run it in a loop until it stops finding the board:

while go run ./tools/qbs -target pico2-w; do :; done

Each time I tried, a board failed within 1 to 6 runs, on all three boards. An Arduino Uno R4 WiFi passed the one full run I did.

Probably ruled out

  • The pico2-w target. Its image is byte identical to pico2.
  • The two recent USB serial commits 83ce7e39 and fed7ac03. It still failed with both reverted.
  • DTR and RTS on the host. Toggling them on a stuck board did nothing.
  • Stale EP0 state after a bus reset. A change that clears it did not help.
  • Idle time before the reset, and USB selective suspend. Cycles with gaps of 0.5 s and 10 s did not fail.
  • How tinygo flash is called, and the host serial library. Python and Go hosts both failed, and so did runs that did and did not pass -port.
  • The adapter and cable.

More than 150 flashes of images that only printed a banner never failed when tinygo flash found the port itself. I do not know what the test programs do differently.

主要言語
Go
スター
17.8k
フォーク
1.1k
平均マージ
1日 4時間
マージ済み PR(30日)
380

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

tinygo-org/tinygo のほかの issue

tinygo-org/tinygo の issue をすべて見る

似ている issue

Go の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。