From 69f1daf6dbb12b151183478f790f7afe19399d74 Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Mon, 4 Mar 2024 10:38:15 -0500 Subject: [PATCH] [bin] Add west cam to webcam capture script --- bin/.bin/webcam-capture | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 bin/.bin/webcam-capture diff --git a/bin/.bin/webcam-capture b/bin/.bin/webcam-capture new file mode 100755 index 0000000..49c54af --- /dev/null +++ b/bin/.bin/webcam-capture @@ -0,0 +1,17 @@ +#!/bin/sh +host = "loge.local" + +if [ "$1" = "east" ]; then + port=8082 +fi + +if [ "$1" = "basement" ]; then + port=8081 +fi + +if [ "$1" = "west" ]; then + port=8081 + host="atlas.local" +fi + +curl $host:$port/snapshot -o /media/photos/webcams/$1/$(date +%Y%m%d%H%M%S).jpg