Skip to content

Instantly share code, notes, and snippets.

@ArtBIT
Last active October 1, 2021 15:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ArtBIT/b4e6a847c53a6b7139b8ba297caf72c3 to your computer and use it in GitHub Desktop.
Save ArtBIT/b4e6a847c53a6b7139b8ba297caf72c3 to your computer and use it in GitHub Desktop.
RPI9000 Webcam Script
#!/bin/bash
IMAGE=/tmp/webcam.jpg
# Save the webcam image to a file
fswebcam \
-d /dev/video0 \
-p YUYV \
-r 1600x1200 \
--jpeg 85 \
-F 4 \
--set Gamma=4 \
--no-banner \
--overlay $HOME/hal9000.png \
$IMAGE
# copy it to my host computer
scp $IMAGE $HOST_IP:/home/artbit/rpi/$(date +\%Y\%m\%d\%H\%M).jpeg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment