Saturday, December 27, 2014

Raspistill Instant Capture

If you run raspistill each time you want to take a shot, it does not work fast enough. In order to get instant shots it is much more useful to use the "signal mode".

In signal mode, raspistill waits for a SIGUSR1 signal from another process. You can invoke it like this:

raspistill -t 0 -s -o /tmp/shot.jpg

-s signal mode
-o output file
-t 0 disable default 5s timeout

and then when ready, send the signal to take a shot:

pkill -SIGUSR1 raspistill

or

pkill -10 raspistill

that's it.

* If you don't specify -t 0 parameter and disable default 5s timeout, raspistill will quit after 2 or 3 shots (actually will quit after spending total 5 seconds).

1 comment: