Take snapshot with camera when ringing doorbell

Topics (not sure which fora)
when not sure where to post, post here and mods will move it to right forum.

Moderators: leecollings, remb0

Atis
Posts: 37
Joined: Monday 30 March 2020 7:30
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Take snapshot with camera when ringing doorbell

Post by Atis »

EddyG wrote: Monday 23 November 2020 9:07 It's clear that your version of ffmpeg needs the output format as a parameter, so just add that one.
Evaluate the next possible error and add possible next parameter.
In Linux the sudo command has to be:

Code: Select all

sudo <full path>/video.sh
or if you are already in that path

Code: Select all

sudo ./video.sh
Then sudo will find your script.
B.t.w. What is your Linux version and what is your ffmpeg version.

Code: Select all

uname -a
ffmpeg -version

Sudo comand-> command not found

Linux AtisServer1 4.4.59+ #25426 SMP PREEMPT Wed Jul 8 03:21:29 CST 2020 x86_64 GNU/Linux synology_apollolake_1019+

ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 4.9.3 (crosstool-NG 1.20.0) 20150311 (prerelease)

I try another video and file type (mov). Same error. I think the ffmpeg catch the file.
EddyG
Posts: 1042
Joined: Monday 02 November 2015 5:54
Target OS: -
Domoticz version:

Re: Take snapshot with camera when ringing doorbell

Post by EddyG »

So your are on a Synology, missed that. You don't need sudo if you are admin user.
Try doing everything in your local dir e.g. /volume1/homes/admin (if you logged in with admin) and all the paths point to that dir even the video file.
So the video file get create in your home dir.
Atis
Posts: 37
Joined: Monday 30 March 2020 7:30
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Take snapshot with camera when ringing doorbell

Post by Atis »

EddyG wrote: Monday 23 November 2020 20:08 So your are on a Synology, missed that. You don't need sudo if you are admin user.
Try doing everything in your local dir e.g. /volume1/homes/admin (if you logged in with admin) and all the paths point to that dir even the video file.
So the video file get create in your home dir.
Not good. I think the problem not the right.

OK. I find the problem, but can not understand. The ffmpeg create the file name camera1.mp4^M (In dir command camera1.mp4? file name). If I rename camera1.mp4 everything works, but I runing the script again ffmpeg create error camera1.mp4^M file :(
EddyG
Posts: 1042
Joined: Monday 02 November 2015 5:54
Target OS: -
Domoticz version:

Re: Take snapshot with camera when ringing doorbell

Post by EddyG »

The ^M comes probably from CR a leftover from the Windows editor?
So edit your script carefully again or retype it in Synology with a nano editor.
Atis
Posts: 37
Joined: Monday 30 March 2020 7:30
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Take snapshot with camera when ringing doorbell

Post by Atis »

EddyG wrote: Tuesday 24 November 2020 10:31 The ^M comes probably from CR a leftover from the Windows editor?
So edit your script carefully again or retype it in Synology with a nano editor.
Problem Solved. Thank you your help.
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 1 guest