piface / PiFace-Real-Time-Clock

Installation script for PiFace Real Time Clock.
MIT License
13 stars 13 forks source link

problem with "cold boot" (and possible fix) #11

Open pjritee opened 7 years ago

pjritee commented 7 years ago

I tried both the new installation script and the old one (and other variants from googling) and I always get the same problem. If I have the Raspberry Pi turned off for some time and boot it up then /dev/rtc does not exist before pifacertc is run. However if I reboot then everything is OK. After even more googling I came across https://www.raspberrypi.org/forums/viewtopic.php?f=44&t=16218 I purged fake-hwclock but that didn't fix the problem. However the suggestion to change hwclock.sh to have

Required-Start: mountdevsubfs kmod

X-Start-Before:

Note: it was

X-Start-Before: checkroot

but that gives a loop when running update-rc.d hwclock.sh enable

Knock on wood but I have tried a cold boot twice now and it succeeded both times whereas it used to fail all the time.

Maybe worth considering modifying the install script to do these edits in hwclock.sh if you manage to reconstruct the problem (and this solution works).

pjritee commented 7 years ago

Spoke too soon - I booted it this morning after the night turned off and it failed. I didn't have the WiFi dongle plugged in though (for the first time).