rust-embedded/rust-raspberrypi-OS-tutorials

minipush.rb default timout of 7 seconds is too short when externally powering an RPi 4B

rpwjanzen opened this issue · 1 comments

When powering a RPi 4B externally (+5v power pin is disconnected) and running 'BSP=rpi4 make chainboot', the minipush timeout of 7 seconds occurs before the RPi has booted the kernel8.img and output what minipush is expecting. This causes minipush to display the generic "Protocol Error" message.

Increasing the timeout to 30 seconds allows the user to perform the following steps without the timeout occurring.

  1. Assume that USB to serial device is already "working"
  2. Run 'BSP=rpi4 make chainboot'
  3. Manually power up the RPi 4B (1 - 5 seconds for user to toggle power)
  4. Allow the RPi 4B time to boot the kernel8.img (12 seconds)
  5. Allow the transfer of the image to the RPi

Please increase the default timeout to more than 7 seconds. Please note that pushing larger images appears to take more time during which the timeout can occur.

Done.

By the way, I already have it on my agenda to change the instructions to externally powered RPi only, since I had cases in the past where powering the Pi using the USB serial didn't work.

This might change the Minipush protocol slightly, but I have yet to sketch it out.