|
Post by SDL on Nov 10, 2019 18:23:59 GMT -8
BTW,
why not login using SSH to your system rather than with a monitor or keyboard? You might check out VNC too. All these work well on the Raspberry Pi.
BP
|
|
|
Post by Powderjockey on Nov 10, 2019 19:54:57 GMT -8
BTW, why not login using SSH to your system rather than with a monitor or keyboard? You might check out VNC too. All these work well on the Raspberry Pi. BP I have been, but when didn't autostart properly, I could not get to the Pi with VNC nor SSH, hence the reason for the monitor outside. I was using the script from the setup manual that was to be placed into the rc.local.
|
|
|
Post by SDL on Nov 11, 2019 10:58:50 GMT -8
Hmm. You have a different problem than just not starting. Do you have another Pi? Install SKyWeather on that Pi and see if it starts up. You have a problem with one of the three things I thing: 1) The Pi has a problem 2) Your image has a problem 3) You have a power problem.
What do you see on the monitor when the Pi does not autostart?
BP
|
|
|
Post by Powderjockey on Nov 20, 2019 18:48:47 GMT -8
OK, For the past 10 days I've monitored the system. Every 5 days the Pi reboots and the SkyWeather does not start. I placed the required "script" into the /etc/rc.local prior to the 10 days. When I go to start the SkyWeather the following is what I get.
pi@skyweather:~ $ cd SDL_Pi_SkyWeather pi@skyweather:~/SDL_Pi_SkyWeather $ sudo pigpiod 2019-11-20 19:42:54 initInitialise: Can't lock /var/run/pigpio.pid Can't initialise pigpio library pi@skyweather:~/SDL_Pi_SkyWeather $ sudo python SkyWeather.py (0.0, 0, 0) () ('Pi Camera Revision', u'ov5647') ('after bme680', True) as3935 start I/O error(121): Remote I/O error after SHT30 outsideTemperature: -3.0 C outsideHumidity: 99.9 % crc: 0x53a0
SkyWeather Weather Station Version 052 - SwitchDoc Labs......... I appears the pigpiod starts, but the python file for the SkyWeather does not.
File details for the rc.local are as follow:
#!/bin/sh -e # # rc.local # # This script is executed at the end of each multiuser runlevel. # Make sure that the script will "exit 0" on success or any other # value on error. # # In order to enable or disable this script just change the execution # bits. # # By default this script does nothing.
# Print the IP address _IP=$(hostname -I) || true if [ "$_IP" ]; then printf "My IP address is %s\n" "$_IP" fi
pigpiod cd /home/pi/SDL_Pi_SkyWeather nohup sudo python SkyWeather.py &
exit 0
|
|
|
Post by SDL on Nov 25, 2019 11:03:38 GMT -8
Your code looks good. But this is odd:
2019-11-20 19:42:54 initInitialise: Can't lock /var/run/pigpio.pid Can't initialise pigpio library
Go into /var/run and delete pigpio.pid
sudo rm /var/run/pigpio.pid
That might fix it.
BP
|
|
|
Post by Powderjockey on Nov 27, 2019 17:58:41 GMT -8
Your code looks good. But this is odd: 2019-11-20 19:42:54 initInitialise: Can't lock /var/run/pigpio.pid Can't initialise pigpio library
Go into /var/run and delete pigpio.pid sudo rm /var/run/pigpio.pid That might fix it. BP I removed the file. Then reboots the Pi. It rebooted fine, but the SkyWeather did not start according to the data in Wunderground and WeatherStem.
Is there a way to to see if it is running after the Pi is up and running?
I went thru the process of changing into the Weather directory and ran sudo pigpiod again and received the same error as above.
|
|
|
Post by SDL on Nov 29, 2019 15:21:30 GMT -8
PowderJocky,
A couple of different ways:
ps xaf | grep pigpiod
Have you checked nohup.out in the SkyWeather directory?
sudo tail -f nohup.out
BP
|
|
|
Post by Powderjockey on Dec 1, 2019 9:28:19 GMT -8
pi@skyweather:~ $ ps xaf | grep pigpiod] 27432 pts/1 S+ 0:00 | \_ grep --color=auto pigpiod] pi@skyweather:~ $ sudo tail -f nohup.out tail: cannot open 'nohup.out' for reading: No such file or directory tail: no files remaining pi@skyweather:~ $
|
|
|
Post by SDL on Dec 2, 2019 9:44:04 GMT -8
You aren't in the correct directory. cd SDL_Pi_SkyWeather
Then "ls"
and make sure you are in the correct directory.
Then do the
sudo tail -f nohup.out
BP
|
|
|
Post by Powderjockey on Dec 2, 2019 17:08:10 GMT -8
You aren't in the correct directory. cd SDL_Pi_SkyWeather Then "ls" and make sure you are in the correct directory. Then do the sudo tail -f nohup.out BP Jus let that run until it reboots?
|
|
|
Post by SDL on Dec 3, 2019 10:15:48 GMT -8
Try
sudo ps xaf | grep pigpiod
You had a "]" in your command.
BP
|
|
|
Post by Powderjockey on Dec 15, 2019 9:22:07 GMT -8
pi@skyweather:~ $ sudo ps xaf | grep pigpiod 845 pts/1 S+ 0:00 | \_ grep --color=auto pigpiod 477 ? SLsl 528:26 pigpiod pi@skyweather:~ $ Doesn't look any different.
Could I try to place the startup in a different location?
|
|
|
Post by SDL on Dec 17, 2019 4:16:34 GMT -8
Looks like it is running to me.
BP
|
|
|
Post by Powderjockey on Dec 19, 2019 17:07:47 GMT -8
Looks like it is running to me. BP Yes I think the pigpiod is loading, but the actual sudo python SkyWeather.py doesn't load.
|
|
|
Post by SDL on Dec 20, 2019 3:26:44 GMT -8
Show me your code again that you are running at startup.
BP
|
|