¿ªÔÆÌåÓý

Re: ZBitx Shutdown Function #zbitx


 

That's an interesting thought regarding the shutdown process for the ZBitx. Expanding on your idea, it seems quite logical to have a dedicated button displayed on the user interface that initiates the shutdown procedure for the primary Raspberry Pi Zero. Following the activation of this shutdown command, once the Pi Zero has completed its shutdown sequence, it would cease transmitting data via the I2C communication protocol. The secondary microcontroller, in this case, the Pico, could then be programmed to monitor the I2C bus for the absence of this data. Upon detecting that the Pi Zero is no longer sending any I2C signals, the Pico could then trigger a visual cue on the screen, perhaps a message indicating that it is now safe to disconnect the power supply.

This approach offers a more user-friendly and potentially safer method for powering down the ZBitx, particularly in situations where accessing a terminal to issue a shutdown command is not feasible. It elegantly utilizes the existing communication pathway between the main processor and the display controller to provide a clear indication to the user when it is appropriate to remove the power.

Thanks,
David


On Sat, May 17, 2025, 4:54?PM Dave, N1AI via <n1ai=[email protected]> wrote:
On Sat, May 17, 2025 at 10:43 AM, AndyH wrote:
Even well behaved Pis corrupt and SD card from time to time, so it's "always" a good idea to have a ready backup or three regardless.
?
Correct, yet corruption is even less likely if you do an orderly shutdown.? The OP coded a way to do that when you don't have a keyboard, which is supposed to be a major use case for zbitx.
?
It feels to me that this point is being missed, quite possibly because the community has not found a good way to get fixes/improvements into the official code base.
?
If you really want to test your backups, I could write a program that you could install that occasionally zeros out random blocks on your SD card just to see how long it takes to corrupt something important.? If the next boot happens to be at a POTA/SOTA site and the boot code needs info from that zero'd block, it'll teach a lesson about how important it is to bring up-to-date backups with you everywhere you intend to operate.
?
I think the idea is to both have good backups, and to not need those good backups.
?
Yet, as above, the fix/improvement will probably end up living on only in unofficial forks.
?
--
Regards,
Dave, N1AI

Join [email protected] to automatically receive all group messages.