If have read through several threads of this forum and been searching the internet for several days – still no solution in sight.
I have two Cameras in my House, one INSTAR 9008 and one WANSVIEW 1080p. My goal is to send snapshots via PUSHOVER to my phone. For the Instar this was no big problem and is working now. The Wansview is resisting my demands until today
I looked up and tried several different snapshot URLs from the internet and the user manual – without success. When I use Chrome with one of the URLs, I get a snapshot shown, so I suspect the executeCommand to save the file to /tmp to not be working properly…
I also used different commands (wget, curl) for saving the files - didn’t work either.
A file “Durchgang.jpg” is available, as i placed a dummy at the specific location. The dummy is sent via pushover but never changed by the rule/camera.
I have the IPCAM bining installed, but it shouldn’t be required for this purpose, right? As I understood the image item is endcoded somehow and cannot easily be sent as an attachment.
Has someone else had the same problem or can point me in the right direction?
(I am using latest openhab/openhabian 2.4 on raspberry pi)
Is any additional information required (i’m posting for the first time here )
rule "Briefkasten Snapshot" when Item XI_WDS_EG_BRIEFKASTEN_Status changed from CLOSED to OPEN then var FrontDoorCam = "FrontDoor.jpg" var Location = "/tmp/" executeCommandLine("wget http://192.168.2.151:80/tmpfs/snap.jpg?usr=admin&pwd=********* -O " + Location + FrontDoorCam) createTimer(now.plusSeconds(1), [ | sendPushoverMessage(pushoverBuilder("Briefkasten").withTitle("Die Post war da").withAttachment("/tmp/FrontDoor.jpg")) ]) end
WANSVIEW (not working)
rule "Wansview Snapshot" when Item TestSchalter changed from OFF to ON then //http://username:password@ipaddresse/mjpeg/snap.cgi?chn=0 //http://username:password@ipaddress:port/mjpeg/snap.cgi?chn=0 //http://username:email@example.com:554/mjpeg/snap.cgi?chn=0 //http:/username:password @192.168.2.112/tmpfs/auto.jpg? //executeCommandLine("curl --user admin:********* http://admin:*********@192.168.2.112:554/mjpeg/snap.cgi?chn=0 --digest -o /tmp/Durchgang.jpg") //executeCommandLine("wget --user=admin --password=********* http://192.168.2.112:554/mjpeg/snap.cgi?chn=0 -O /tmp/Durchgang.jpg") executeCommandLine("wget http://192.168.2.112:554/mjpeg/snap.cgi?chn=0 -O /tmp/Durchgang.jpg") createTimer(now.plusSeconds(1), [ | sendPushoverMessage(pushoverBuilder("Bewegung erkannt").withTitle("Kamera Snapshot: Durchgang Garage").withAttachment("/tmp/Durchgang.jpg")) ]) end
LOG (when the item change is received)
2019-06-27 23:40:52.713 [INFO ] [lipse.smarthome.io.net.exec.ExecUtil] - executed commandLine 'curl --user admin:********* http://192.168.2.112:554/mjpeg/snap.cgi?chn=0 --digest -o /tmp/Durchgang.jpg
Thanks a lot