I worked out a script to get still images from my Amcrest security camera in my garage and tied it to a motion sensor:
- alias: Garage Motion
trigger:
platform: state
entity_id: binary_sensor.aeotec_zw100_multisensor_6_sensor_26_0
to: 'on'
action:
- service: script.garagewget
However, it is not getting the images as it should. I can run the script manually and it works perfectly. I have another script that is used to backup my configuration directory. I can tie the motion sensor to that and it works every time motion is detected. So I am not sure what else to look for.
I have HA installed on a server (not using the all in one installer) and everything else is working as it should. I see no error messages in HA or anything in the logs on the camera itself. The camera is connected with WiFi, so I did expect it to be a little slower than it would be if over Ethernet, but I can remotely log into the camera without issues.
I can see the two scripts I have set up in the entities list. I can go into HA services and I can manually run the backup script from HA and it works perfectly, but when I try to run the script to get the camera images manually, nothing happens. Both scripts have the same permissions as well.
If anyone has any ideas, I would greatly appreciate it.