diff --git a/fhem/CHANGED b/fhem/CHANGED index 420d0aa84..f4107483b 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,6 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - bugfix: 49_SSCam: fix noQuotesForSID using in streaming devices type mjpeg - feature: 74_GardenaSmartDevice: add lona readings, [fix] - setter procedure - feature: 14_CUL_TCM97001: add KW9015 (TFA 30.3161) diff --git a/fhem/FHEM/49_SSCam.pm b/fhem/FHEM/49_SSCam.pm index f3ff103a1..df90e6d17 100644 --- a/fhem/FHEM/49_SSCam.pm +++ b/fhem/FHEM/49_SSCam.pm @@ -185,6 +185,7 @@ BEGIN { # Versions History intern my %vNotesIntern = ( + "9.10.5" => "01.07.2022 fix noQuotesForSID using in streaming devices type mjpeg ", "9.10.4" => "03.06.2022 avoid warning 'No data for Cache with key: {LASTSNAP}' if no snap exists ", "9.10.3" => "23.11.2022 made SYNO.SurveillanceStation.AudioStream, SYNO.SurveillanceStation.VideoStream optional for SVS compatibility to 9.0.0 ", "9.10.2" => "03.11.2021 set SVS compatibility to 8.2.10 ", @@ -2582,15 +2583,15 @@ sub _setrunView { ## no critic "not used" $hash->{HELPER}{ALIAS} = "LiveView"; $hash->{HELPER}{RUNVIEW} = "live_open"; $hash->{HELPER}{ACTSTRM} = ""; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "live_link") { + } + elsif ($prop eq "live_link") { $hash->{HELPER}{OPENWINDOW} = 0; $hash->{HELPER}{WLTYPE} = "link"; $hash->{HELPER}{ALIAS} = "LiveView"; $hash->{HELPER}{RUNVIEW} = "live_link"; $hash->{HELPER}{ACTSTRM} = ""; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "lastrec_open") { + } + elsif ($prop eq "lastrec_open") { if ($prop1) { $hash->{HELPER}{VIEWOPENROOM} = $prop1; } @@ -2603,36 +2604,36 @@ sub _setrunView { ## no critic "not used" $hash->{HELPER}{ALIAS} = "LastRecording"; $hash->{HELPER}{RUNVIEW} = "lastrec_open"; $hash->{HELPER}{ACTSTRM} = ""; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "lastrec_fw") { # Video in iFrame eingebettet + } + elsif ($prop eq "lastrec_fw") { # Video in iFrame eingebettet $hash->{HELPER}{OPENWINDOW} = 0; $hash->{HELPER}{WLTYPE} = "iframe"; $hash->{HELPER}{ALIAS} = " "; $hash->{HELPER}{RUNVIEW} = "lastrec"; $hash->{HELPER}{ACTSTRM} = "last Recording"; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "lastrec_fw_MJPEG") { # “video/avi” – MJPEG format event + } + elsif ($prop eq "lastrec_fw_MJPEG") { # “video/avi” – MJPEG format event $hash->{HELPER}{OPENWINDOW} = 0; $hash->{HELPER}{WLTYPE} = "image"; $hash->{HELPER}{ALIAS} = " "; $hash->{HELPER}{RUNVIEW} = "lastrec"; $hash->{HELPER}{ACTSTRM} = "last Recording"; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "lastrec_fw_MPEG4/H.264") { # “video/mp4” – MPEG4/H.264 format event + } + elsif ($prop eq "lastrec_fw_MPEG4/H.264") { # “video/mp4” – MPEG4/H.264 format event $hash->{HELPER}{OPENWINDOW} = 0; $hash->{HELPER}{WLTYPE} = "video"; $hash->{HELPER}{ALIAS} = " "; $hash->{HELPER}{RUNVIEW} = "lastrec"; $hash->{HELPER}{ACTSTRM} = "last Recording"; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "live_fw") { + } + elsif ($prop eq "live_fw") { $hash->{HELPER}{OPENWINDOW} = 0; $hash->{HELPER}{WLTYPE} = "image"; $hash->{HELPER}{ALIAS} = " "; $hash->{HELPER}{RUNVIEW} = "live_fw"; $hash->{HELPER}{ACTSTRM} = "MJPEG Livestream"; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "live_fw_hls") { + } + elsif ($prop eq "live_fw_hls") { if(!IsCapHLS($hash)) { return qq{API "SYNO.SurveillanceStation.VideoStream" is not available or Reading "CamStreamFormat" is not "HLS". May be your API version is 2.8 or lower.}; } @@ -2642,8 +2643,8 @@ sub _setrunView { ## no critic "not used" $hash->{HELPER}{ALIAS} = "View only on compatible browsers"; $hash->{HELPER}{RUNVIEW} = "live_fw_hls"; $hash->{HELPER}{ACTSTRM} = "HLS Livestream"; # sprechender Name des laufenden Streamtyps für SSCamSTRM - - } elsif ($prop eq "lastsnap_fw") { + } + elsif ($prop eq "lastsnap_fw") { $hash->{HELPER}{LSNAPBYSTRMDEV} = 1 if($prop1); # Anzeige durch SSCamSTRM-Device ausgelöst $hash->{HELPER}{LSNAPBYDEV} = 1 if(!$prop1); # Anzeige durch SSCam ausgelöst $hash->{HELPER}{OPENWINDOW} = 0; @@ -5707,8 +5708,8 @@ sub _Oprunliveview { if($part) { # API "SYNO.SurveillanceStation.VideoStream" vorhanden ? (removed ab API v2.8) $exturl .= qq{/webapi/$hash->{HELPER}{API}{$vkey}{PATH}?}.$part; $url = qq{$proto://$serveraddr:$serverport/webapi/$hash->{HELPER}{API}{$vkey}{PATH}?}.$part; # interne URL - - } elsif ($hash->{HELPER}{STMKEYMJPEGHTTP}) { + } + elsif ($hash->{HELPER}{STMKEYMJPEGHTTP}) { $url = $hash->{HELPER}{STMKEYMJPEGHTTP}; } } @@ -7757,6 +7758,7 @@ sub streamDev { ## no critic 'comp camid => $hash->{CAMID}, sid => $hash->{HELPER}{SID}, proto => $hash->{PROTOCOL}, + noQuotesForSID => AttrVal($camname, "noQuotesForSID",0), cmdstop => $cmdstop, cmdhlsreact => $cmdhlsreact, cmdmjpegrun => $cmdmjpegrun, @@ -7858,6 +7860,7 @@ sub _streamDevMJPEG { ## no critic 'complexity not my $ha = $params->{ha}; my $hb = $params->{hb}; my $hau = $params->{hau}; + my $noQuotesForSID = $params->{noQuotesForSID}; my $serveraddr = $params->{serveraddr}; my $serverport = $params->{serverport}; @@ -7879,7 +7882,8 @@ sub _streamDevMJPEG { ## no critic 'complexity not my $imgdosnap = $params->{imgdosnap}; my ($link,$audiolink); - my $ret = ""; + my $quote = $noQuotesForSID ? qq{"} : qq{}; + my $ret = ""; if(ReadingsVal($camname, "SVSversion", "") eq "8.2.3-5828" && ReadingsVal($camname, "CamVideoType", "") !~ /MJPEG/x) { $ret .= "