John Shovic's Google Plus Switch: pi camera / raspistill problem behavior change

Monday, January 20, 2014

pi camera / raspistill problem behavior change

Yesterday, we installed all the new updates and upgrades to the Raspberry Pi in preparation for the trip to Curacao (we leave at the end of February).  When we looked at the power system display this morning, we were surprised to see that the Pi was now taking  350ma or more instead of the around 200ma it had been taking on the average.

RasPiConnect Power Subsystem Screen

Something about the update increased current consumption by 75%.  After noticing that the camera was no longer working, we looked at the processes running (ps axf) and we found that the camera process seemed hung.

After some experimenting (running the command by hand with the '-v' option), we found that in the latest update, raspistill had changed the behavior of the '-t' option.  The new behavior had the camera continually taking new pictures, rather than just one.  This means that the process never exited and used a ton of current taking pictures, one after another.

The old command (which had been working for months):

raspistill -o /home/pi/RasPiConnectServer/static/picameraraw.jpg -t 0

The new command (which now works correctly - only one picture):

raspistill -o /home/pi/RasPiConnectServer/static/picameraraw.jpg -t 100

So the behavior of the '-t' option changed.  '0' now means capture pictures for ever and we have to give a value > 0 for single capture.


We also added the command:

/opt/vc/bin/tvservice -off

in /etc/local.rc to turn off the HDMI/PAL outputs on the Pi since we don't use them.  This reduced the current draw about 20ma.  You can see the 20ma drop in the base Pi current (green on the graph above).

No comments:

Post a Comment