PicoBoot icon indicating copy to clipboard operation
PicoBoot copied to clipboard

Debug LED behavior

Open webhdx opened this issue 3 years ago • 1 comments

Current behavior:

The builtin LED is enabled during boot up and doesn't provide any sensible information apart from the fact that PicoBoot code is flashed correctly.

How can we improve?

Use the LED to signal diagnostic information. It can use different blinking patterns to differentiate a few things:

  1. CS data line missing
  2. CLK data line missing
  3. MISO data line missing
  4. MOSI data line missing (not used in current impl.)

Blinking patterns

Scenario Blinking pattern Description
All OK * * * * * 5 short pulses
CS data line missing - * * * * 1 long, 4 short pulses
CLK data line missing - - * * * 2 long, 3 short pulses
MISO data line missing - - - * * 3 long, 2 short pulses
MOSI data line missing - - - - * 4 long, 1 short pulse
  • After 5 long pulses ("All OK") the LED should turn solid green for the rest of operation
  • In case of error patterns should repeat indefinitely with a longer pause in between

webhdx avatar Nov 15 '22 09:11 webhdx

Maybe another option is to use some GPIOs to output a status byte, and let people connect LEDs to them?

RenaKunisaki avatar Sep 08 '23 20:09 RenaKunisaki