motioneye-project / motioneye

A web frontend for the motion daemon.
GNU General Public License v3.0
3.97k stars 652 forks source link

Telegram motion notifications not working #2708

Open DeadlySin2 opened 1 year ago

DeadlySin2 commented 1 year ago

I have the following settings of my Motioneye 1 2 I'm trying to make motion notifications working but they refuse to. My Home Assistant is detecting motion from a curl command, so as i think motioneye is able to detect motion. If i click Test button below Telegram settings i recieve test message to my Telegram bot, but the are no notifications about motion detected and no still images. My motioneye is installed in docker container from this repo:

motionEye Version | 0.43.0 Motion Version | 4.5.1 OS Version | Linux 4.4.180+

Please help to make notifications work. Thanks for your support.

s17534 commented 1 year ago

... but you have set: Capture mode in Still images section to manual, so until you manually press snapshot button AND if time which passed from start of the motion detection to that moment of snapshot is not greater than Attached Images Time in Telegram settings section it should work.

So imo you should set Capture Mode to Motion Triggered [ One Picture ] and adjust Attached Images Time accordingly.

Linked above Telegram optimizations is another way of dealing with that issue.

zagrim commented 1 year ago

I think @s17534 is correct about the capture mode of still images. @DeadlySin2 did you get any notification even without pictures? I think you should get, even if there are no images found, but how about if you change that mode?

DeadlySin2 commented 1 year ago

No I can't manage it working, so i just made some motion sensors in my Home assistant and recieve notification from there.

inuonly commented 7 months ago

I was having the same isuse but managed to get it working by tinkering the time settings and frame settings. i have disabled manual capture as intructed and set it to motion capture. I think it is related to your camera fps (you have set while camera setup) , and time between frames, and also other time setting, dont remember all of them now.

What i see here as an opportunity to present a solution is that either the calculation be added to documentation or else a frontend validation of frames and time settings be done via a js (script) and a tooltip be presented warning user that image will not be displayed . justification : As stated above by two peopel in replies, what is to be done was understood like you need to get the timing s match and be right, but how that was to be achived was not clear. Also despite me able to figure out time and frame issue i still could not get it working in one go i just randomly did something and it worked and then thee onwards tweaked one by one.

Hope this helps on how to close this one. Good luck.

zagrim commented 7 months ago

I do agree that the help/tooltip text for "Attached Images Time" is not as good as it should be, but I do not think there's much mystery in how that works (or at least how it should work based on code): The specified time span should be long enough that images captured during the motion event can be found within that time span (counting backwards from end of the event).

So, the suggested default 30 seconds means that any images saved within the previous 30 seconds should be attached. Whether there are any saved images depends on how long the motion event is, and if still images are saved for every motion frame or only for the "best" frame selected by Motion. The length of the motion event cannot be known except for "Maximum Movie Length" under "Movies" if that is specified.

Frame count related settings effect motion detection, but I don't immediately see how they could interfere with image attachment to notification... "Maximum Movie Length" can, in case of long max length and still image capture mode of "Motion Triggered (One Picture)" together with short "Attached Images Time".

Perhaps some useful validation between settings could be done, but in general that might quickly go pretty complex and not very stable :thinking:

inuonly commented 7 months ago

for me default settings didn't work so just shared my experience . may i dont understand that much on how it works , i am on the user end only understood that default setting did not work and i changed it to sometiing random and it worked. although i still am not able to control the frequency of how many images it sends but atleast its sending which is one step ahead than not sending previously. i even tried the ? mark and move mouse on that , it didnt help. may be i just got lucky with random number.

On Wed, 20 Mar 2024, 9:48 pm Esa Tikka, @.***> wrote:

I do agree that the help/tooltip text for "Attached Images Time" is not as good as it should be, but I do not think there's much mystery in how that works (or at least how it should work based on code): The specified time span should be long enough that images captured during the motion event can be found within that time span (counting backwards from end of the event).

So, the suggested default 30 seconds means that any images saved within the previous 30 seconds should be attached. Whether there are any saved images depends on how long the motion event is, and if still images are saved for every motion frame or only for the "best" frame selected by Motion. The length of the motion event cannot be known except for "Maximum Movie Length" under "Movies" if that is specified.

Frame count related settings effect motion detection, but I don't immediately see how they could interfere with image attachment to notification... "Maximum Movie Length" can, in case of long max length and still image capture mode of "Motion Triggered (One Picture)" together with short "Attached Images Time".

Perhaps some useful validation between settings could be done, but in general that might quickly go pretty complex and not very stable 🤔

— Reply to this email directly, view it on GitHub https://github.com/motioneye-project/motioneye/issues/2708#issuecomment-2009970483, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGLTF5LQRTZ33M6CLY6GRIDYZGZETAVCNFSM6AAAAAAVNFVSJWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMBZHE3TANBYGM . You are receiving this because you commented.Message ID: @.***>