Was Processing ... Changed to Detecting commercials

I have a script that checks if someone is Watching, Recording or Processing so if this infact was changed can I get a YES?

What are you monitoring?
Is it /dvr/events/subscribe

http://ip:8089/dvr
I am directing to text and then grepping for those keywords. I guess i will have to start a short recording see what it displays.

The /dvr/events/subscribe endpoint is the proper place to monitor changes. You may want to adjust your scripts accordingly.

I do not think that helps all I get is

{"Type":"hello", "Version":"2021.09.04.2308"}

It will output whatever is shown under Activity on the web UI.
Something has to happen before you'll see it.

I have 2 recordings going ... the /dvr gives me more than enough ... I have a recording going I will see what it says when doing commercial detection.

Activity

Recording ch781 for Crocodile Dundee (1986) until 5:06PM.

Recording ch2.2 for Mama's Family until 5:01PM.

Watching ch2.2 METVN from 10.0.0.160

I run this Windows cmd script

echo Logging Channels_DVR#1 activity for 5hrs (5:00:00) on %DATE% %TIME% >Channels_DVR#1_ActivityLog.txt
curl -Ns -m 18000 http://192.168.1.4:8089/dvr/events/subscribe | jq -c --unbuffered ".At = (now | todate)" >>Channels_DVR#1_ActivityLog.txt
echo %DATE% %TIME% log ends >>Channels_DVR#1_ActivityLog.txt
EXIT

Which gives me this output

Logging Channels_DVR#1 activity for 5hrs (5:00:00) on Sun 09/05/2021 16:52:35.51 
{"Type":"hello","Version":"2021.09.04.2308","At":"2021-09-05T23:52:36Z"}
{"Type":"activities.set","Name":"6-scanner","Value":"Scanning for local content.","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"6-scanner","Value":"Scanning for movies in /volume1/arkives/testMovies","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"6-scanner","Value":"Scanning for movies in /volume1/arkives/ChannelsDVR/Imports/Movies","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"6-scanner","Value":"Scanning for TV shows in /volume1/arkives/ChannelsDVR/Imports/TV","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"6-scanner","Value":"Scanning for TV shows in /volume1/arkives/testTV","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"6-scanner","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"3-processor","Value":"Processing newly recorded files.","At":"2021-09-05T23:56:12Z"}
{"Type":"activities.set","Name":"3-processor","At":"2021-09-05T23:56:12Z"}

I see they did change it ....

Activity

Recording ch781 for Crocodile Dundee II (1988) until 7:36PM.

Detecting commercials in Crocodile Dundee (1986) 2021-09-05-1449.mpg.

I move recordings of movies to MASS Storage when nothing is happening ... Last night was moving while commercials were being detected. I was keying on Processing
CD /d "%~dp0"
:loop
timeout 300
curl.exe "http://127.0.0.1:8089/dvr">status.txt

findstr /I /C:"Recording" status.txt
set recording=%ERRORLEVEL%
if %recording% EQU 0 goto loop
findstr /I /C:"Detecting" status.txt
set recording=%ERRORLEVEL%
if %recording% EQU 0 goto loop
findstr /I /C:"Watching" status.txt
set recording=%ERRORLEVEL%
if %recording% EQU 0 goto loop

ROBOCOPY "Z:\ChannelsDVRMain\Movies" "R:\ChannelsDVRMain\Movies" /move /COPY:DT /minage:0 /e /R:2 /W:2
goto loop
Exit

Must have changed when we made comskip have its own queue.

1 Like

Thanks changed my script to look for busy":true in case anything else changes.

1 Like