Cool stuff for Raspberry Pi, Arduino and all electronics hobby projects
Notifications
Clear all

[Solved / Archived] Witty Pi 4 L3V7 - not shutting down

5 Posts
2 Users
0 Likes
298 Views
(@andrew-simpson17)
Posts: 79
Estimable Member Customer
Topic starter
 

Hi

I have a usb power bank supplying power. I also have a 18630 battery to keep your board 'alive' when the usb power bank is not connected.

I do this test:

 

I issue a shutdown command via my code:

I set the GPIO 4 to a high value.

I then issue: 

 

shutdown -h now

I disconnect the usb power bank.

After a while the Rpi restarts (powered from the 18630 battery).

I go to the wittypi folder.

I startup your utils.

I can see that it says the 18630 battery is discharging.

But, the value constantly shows Vin =4.12V.

I do not know why the Rpi is restarting at all. It should remain on 'standby' until the usb power bank is reconnected?

 

ADDITONAL

Further testing shows that if i disconnect the usb power bank 1st and then issue those shutdown commands it works and remains on standbye.

 

I am confused 🙂

 

 

 

 
Posted : 29/06/2024 4:23 pm
(@andrew-simpson17)
Posts: 79
Estimable Member Customer
Topic starter
 

Subscribe to this topic

 
Posted : 29/06/2024 4:29 pm
(@admin)
Posts: 479
Member Admin
 

@andrew-simpson17 the straightforward way to find out, is to check the wittyPi.log file, there it should tell why it boots up your Pi.

It can tell because the reason of recent startup/shutdown action is stored in the I2C register #11 (I2C_ACTION_REASON)

Maybe you have configured temerature related action?

 
Posted : 30/06/2024 1:27 pm
(@andrew-simpson17)
Posts: 79
Estimable Member Customer
Topic starter
 

Hi

Sorry for the delay. Health issues 🙁

 

I just rerun the test. Same thing happened.

 

This is the log file

 

[2024-06-29 15:56:27] File "schedule.wpi" not found, skip running schedule script.
[2024-07-08 08:43:19] Shutting down system because button is clicked or GPIO-4 is pulled down.
[2024-07-08 08:43:19] Halting all processes and then shutdown Raspberry Pi...
[xxxx-xx-xx xx:xx:xx] Witty Pi daemon (v4.13) is started.
[xxxx-xx-xx xx:xx:xx] Running on Raspberry Pi Zero 2 W Rev 1.0
[xxxx-xx-xx xx:xx:xx] Seems RTC has good time, write RTC time into system
[xxxx-xx-xx xx:xx:xx] Writing RTC time to system...
[2024-07-08 08:45:23] Done 🙂
[2024-07-08 08:45:23] Firmware ID: 0x37
[2024-07-08 08:45:23] Firmware Revison: 0x05
[2024-07-08 08:45:23] Current Vout=5.27V, Iout=0.23A
[2024-07-08 08:45:23] System starts up because USB 5V is connected.
[2024-07-08 08:45:28] Send out the SYS_UP signal via GPIO-17 pin.
[2024-07-08 08:45:29] Pending for incoming shutdown command...
[2024-07-08 08:45:29] File "schedule.wpi" not found, skip running schedule script.

 

Thanks

 
Posted : 08/07/2024 10:05 am
(@andrew-simpson17)
Posts: 79
Estimable Member Customer
Topic starter
 

May have found the issue and I do not want to put you out trying to find the 'problem'.

I repeated the test and this time in the log it says tjis:

 

[2024-07-08 09:04:35] System starts up because USB 5V is connected.

 

which was not there before for some reason.

 

My hardward architecture has given me this unforseen issue!

 

Sorry for wasting your time!

 
Posted : 08/07/2024 10:09 am
Join Waitlist We will inform you when the product arrives in stock. Please leave your valid email address below.