TV-Server on WHS - Collection of fixes and workarounds (2 Viewers)

vvulture

MP Donator
  • Premium Supporter
  • June 3, 2006
    483
    8
    52
    Sydney
    Home Country
    Australia Australia
    Ok Larry... all done.

    I have attached my logs, and also screenshot as per your instructions.

    You will see in the log that the script is trying to set my task for 47:00 PM

    The screen shot will also show you an error.

    I think this will be all you need to fix this ! :)


    Cheers
     

    Attachments

    • EasyCapture2.jpg
      EasyCapture2.jpg
      177.5 KB

    larry_S

    MP Donator
  • Premium Supporter
  • December 11, 2008
    1,443
    168
    Home Country
    Germany Germany
    AW: TV-Server on WHS - Collection of fixes and workarounds

    Ok, I think i can fix the error.
    But first I have to sleep a little bit....
     

    larry_S

    MP Donator
  • Premium Supporter
  • December 11, 2008
    1,443
    168
    Home Country
    Germany Germany
    AW: TV-Server on WHS - Collection of fixes and workarounds

    Hi vvulture,

    that's not so easy, i Think first.
    Microsoft wrote about the parameter:
    The format for StartDate varies with the locale selected for the local computer in Regional and Language Options in Control Panel. Only one format is valid for each locale.

    The valid date formats are listed in the following table. Use the format most similar to the format selected for Short date in Regional and Language Options in Control Panel on the local computer.

    The following code is for English (United States).
    If it doesen't work, i need your short Date Format.

    please replace the code after the SQL-Statement:
    Code:
    if err.number=0 then
              'Nur wenn kein Fehler aufgetreten ist, normales vorgehen
              if isdate(rs1("Start")) then 'Wenn Aufnahmen programmiert sind oder aktuelle eine läuft...
              Datu0=rs1("Start")
              Datu1=right("00"&month(datu0),2)&"/"&right("00"&day(datu0),2)&"/"&year(datu0)
              Datu2=right("00"&hour(datu0),2)&":"&right("00"&minute(datu0),2)
    
                 if rs1("Start")<now() then
    
                   'Es läuft gerade eine Aufnahme
                   aktiv=aktiv+1
                      if "A"&WshShell.RegRead("HKCU\SOFTWARE\AxoNet Software GmbH\LightsOut\MP_Aufnahme")<>"A"&"01.01.2020" then
                         Logdatei "Aktuelle Aufnahme: "&rs1("Channel")&"-"&rs1("Start")&"-"&rs1("endTime")& "-"&rs1("programName")
                         Logdatei "Ändere Taskplaner:  01.01.2020"
                         intReturn = WshShell.Run("SCHTASKS /change /ru "&lcase(net.computerName)&"\"&PLUser&" /RP "&chr(34)&PLPW&chr(34)&" /TN MP_Aufnahmen2 /ST 00:00 /SD 01/01/2020" , 1, true)
                         WshShell.RegWrite "HKCU\SOFTWARE\AxoNet Software GmbH\LightsOut\MP_Aufnahme","01.01.2020","REG_EXPAND_SZ"
                      else
                         Logdatei "Aktuelle Aufnahme: "&rs1("Channel")&"-"&rs1("Start")&"-"&rs1("endTime")& "-"&rs1("programName")
                         Logdatei "Taskplaner (keine Änderung) = "&rs1("Start")
                      end if
                 else
                   'Es ist eine Aufnahme geplant, ggf Starttask anlegen
                    'wenn Task nicht schon angelegt wurde, anlegen
                      if "A"&WshShell.RegRead("HKCU\SOFTWARE\AxoNet Software GmbH\LightsOut\MP_Aufnahme")<>"A"&rs1("Start") then
                         Logdatei "nächste Aufnahme: "&rs1("Channel")&"-"&rs1("Start")&"-"&rs1("endTime")& "-"&rs1("programName")
                         Logdatei "Ändere Taskplaner: "&rs1("Start")
                         Para="SCHTASKS /change /ru "&lcase(net.computerName)&"\"&PLUser&" /RP "&chr(34)&PLPW&chr(34)&" /TN MP_Aufnahmen2 /ST "&Datu2&" /SD "&Datu1
                         Logdatei Para
                         intReturn = WshShell.Run(Para, 1, true)
                         WshShell.RegWrite "HKCU\SOFTWARE\AxoNet Software GmbH\LightsOut\MP_Aufnahme",rs1("Start"),"REG_EXPAND_SZ"
                      else
                         Logdatei "nächste Aufnahme: "&rs1("Channel")&"-"&rs1("Start")&"-"&rs1("endTime")& "-"&rs1("programName")
                         Logdatei "Taskplaner (keine Änderung) = "&rs1("Start")
                      end if
                 end if
              end if
          else  ' Fehlermeldung loggen, kein Standby
          CheckFehler
          aktiv=aktiv+1
          end if
          db1.close
          'Fehlerprüfung wieder aktivieren
          on error goto 0
    end if
     

    vvulture

    MP Donator
  • Premium Supporter
  • June 3, 2006
    483
    8
    52
    Sydney
    Home Country
    Australia Australia
    Hi Larry.
    Sorry for my last post... I wasn't trying to rush you.

    I have tried the change and ran the syntax from log file in CMD prompt.
    The time is now correct, but the date is the wrong way arround.
    You have " MM/DD/YYYY" as in the US format.
    I have " DD/MM/YYYY" like european format.

    Screenshot and log attached.

    Cheers :)
     

    Attachments

    • EasyCapture3.jpg
      EasyCapture3.jpg
      134.3 KB

    larry_S

    MP Donator
  • Premium Supporter
  • December 11, 2008
    1,443
    168
    Home Country
    Germany Germany
    AW: TV-Server on WHS - Collection of fixes and workarounds

    Then you have to change the line with the Datu1 parameter:

    Old
    Code:
    Datu1=right("00"&month(datu0),2)&"/"&right("00"&day(datu0),2)&"/"&year(datu0)
    new:
    Code:
    Datu1=right("00"&day(datu0),2)&"/"&right("00"&month(datu0),2)&"/"&year(datu0)
     

    mguebert

    Portal Pro
    February 9, 2010
    82
    10
    Home Country
    United States of America United States of America
    Just wanted you guys to know, I used your guide to get tv server running on my WHS machine with success. The only changes I followed were to use the pdvd 9 trial. I could not find the pdvd8 trial without resorting to warez sites. Didn't want to go there :)

    Anyway, I did have to rename the config files as described in the thread, also I do get errors when going into the config for tvserver, saying it is an unsupported configuration. However it works fine.

    Other than live tv anyway.

    When viewing live tv after about 2 minutes the video and audio both start to freeze and restart about every 4 or 5 seconds like clockwork. The strange thing is I can record the same file and go into recorded tv and play from there while the file is still recording and it plays without issue.

    I am not using rtsp streaming as I have the 4tr plugin for tv with the use ts option selected.
     

    larry_S

    MP Donator
  • Premium Supporter
  • December 11, 2008
    1,443
    168
    Home Country
    Germany Germany
    AW: TV-Server on WHS - Collection of fixes and workarounds

    What hardware do You use at the HomeServer.

    This Weekend i Installed MP on an HomeServer with a Sempron 3000 CPU.
    The Server got an CPU-Usage at about 100 % every few minutes.

    I didn't had much Time to search for the problem.
    After i deactivate the Service of the Windows Desktop Search, the Server didn't reach the 100% CPU Usage and live TV didn't freeze.
     

    Users who are viewing this thread

    Top Bottom