IS there an Option to retune the tuned Channel on Errors? (1 Viewer)

MaxT

MP Donator
  • Premium Supporter
  • December 9, 2009
    112
    13
    Home Country
    Russian Federation Russian Federation
    :D in advance!
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Okay MaxT, try this...

    1. Stop TV Server.
    2. Take a backup copy of TVLibrary.dll, which can be found in the TV Server install folder.
    3. Download and extract the TVLibrary.dll attached to this post and place it in the TV Server install folder.
    4. Start TV Server.
    5. See if tuning works first time.

    :)

    [Edit: attachment removed to save space on my account]
     

    MaxT

    MP Donator
  • Premium Supporter
  • December 9, 2009
    112
    13
    Home Country
    Russian Federation Russian Federation
    Hi mm1352000,

    Could not wait for coming from work, so connected to HTPC remotely from the office :)

    1. the wery first tune after TV service restart seems to work better
    2. tune to another sat with FTAs is not successful, but what surprised me is that tune to another sat to a scrambled channel was OK (in the attached log this are Kinopokaz HD and Первый on the position 20 which is not FTA, before postiung this log I tried it several times), but tune to the scrambled channel on another sat was not OK (in the attached log it is Первый on the position 7 but from a different provider)

    what I noticed is that previously if in logs there was dvb: LockedInOnSignal waiting 20ms for several times, it always ended with dvb: LockedInOnSignal could not lock onto channel - no signal or bad signal. Now with this Kinopokaz HD this part ends with dvb: LockedInOnSignal ok !!!

    May be timing of diseqc retry is also important? or together with diseqc retry MD*** gives some time needed for another command to succssed?

    If nesessary, I will try further later, when back at home :) Or should I do more specific testing?

    :D and regards,

    MaxT
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Interesting. There might be a timing issue like you say...

    I will post two more test versions tomorrow (sorry for the wait but it is 11:35pm - almost midnight - here in New Zealand).

    VERSION 1

    1. Send switch command (normal)
    2. Send motor commands if necessary (normal)
    3. Wait 100ms
    4. Resend switch command

    VERSION 2

    1. Send motor commands if necessary
    2. Send switch command
    3. Resend switch command

    Does that sound okay to you?

    One other comment: it would make it easier for me to understand the problem if you could avoid tuning scrambled channels for the moment. Also, please turn off your EPG grabber - it looks like it is trying to grab EPG in between your channel changes which may mess things up...

    Goodnight :)
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Alright, here are the test builds I promised.
    :D

    [Edit: attachments removed to save space on my account]
     

    MaxT

    MP Donator
  • Premium Supporter
  • December 9, 2009
    112
    13
    Home Country
    Russian Federation Russian Federation
    Unfortunately neither on them gave good result on tunes to another sat from the first time:(, and I think v1 was very stable with the very first tune after server start or at least more stable than v2. For this tests I've disabled MD***

    I have a question - is it possibe to send the second diseqc command(s):

    - either say every 3000-5000 ms until locking the signal within Tune time (General-Scan) ?

    - or send it after ([current sat position in degrees] - [new sat position in degrees])*800ms or what is better, by user controled multiplier (since apart from two speeds depending on voltage sent to LNB, motors have different turn speeds even on same voltage)? But probably reading strings from the database on sat positions and names and extracting sat positions from them is too much ...

    Anyway many :D

    MaxT
     

    Attachments

    • log[V1].zip
      12.9 KB
    • log[V2].zip
      12.6 KB

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Okay, so are you saying that you think this is what happens when you shift to a new satellite:

    1. Send switch command. Switch changes.
    2. Send motor commands. Motor starts to move.
    3. Check for signal lock. Motor still moving.
    4. Lock fails.
    5. Motor finishes moving.
    6. Tune to next channel on the same satellite.
    7. Send switch command. Switch is changes if necessary.
    8. Send motor commands. Motor is already in the right position.
    9. Check for signal lock. Motor is stationary.
    10. Lock succeeds.

    Ideally you want to wait for the motor to stop moving - a new action between step 2 and 3 - before TV Server checks for signal lock. The problem is that TV Server doesn't support receiving DiSEqC messages, which means it can't tell when the motor has finished moving. Currently TV Server simply instructs the motor to move and then checks for signal lock shortly after that, assuming that the motor is in position...

    There are a few options:
    1. Have you tried to increase the tune timeout in TV Server Configuration -> General -> Scan (tab)?
    This increases the length of time that TV Server spends in step 3 (above) checking for signal lock. If you could set that to the maximum time that it takes for the motor to move between the two most separate positions then it should solve your problem.

    2. Add a new timeout similar to the tune timeout. If the motor has to move then the new timeout could be added to the tune timeout to give the motor more time to move when it needs to move. This is better than option 1 because it doesn't affect the normal lock timeout setting.

    3. Add a field to the motor tab to indicate how fast the motor is at moving (a user defined multiplier like what you suggested). When the motor changes position, TV Server will wait x number of milliseconds per degree that the motor has to move. This could be quite tricky to implement, but certainly possible.

    Option 1 is okay, but not ideal because it means that signals that can't be locked for other reasons will make the TV Server wait for much longer than necessary.
    Option 2 is better than option 3 because you minimise how long you have to wait for the motor to get to any position. TV Server continually checks for signal while the motor moves. As soon as the motor is in position, the channel will be locked and video can be shown. With option 3, you have to guess how long it takes for the motor to move. You can never be 100% accurate, meaning that you usually wait for longer than necessary (or worse, you don't wait long enough!). Option 3 also assumes that the time it takes to move from one position to another is directly proportional to the distance between the two positions. This is not likely to be true because motors usually take time to start and stop and don't move at constant speed...

    ==> Option 2 is the best in my opinion. It is also much simpler than option 3...

    Hopefully you understood all of what I said above. I will try to build another test version with the extra setting :D

    p.s. At the moment I'm not sure whether the switch command needs to be resent or not. I will leave it out of the next test version to see what happens.
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Hi again MaxT

    Here is the test version with the new motor timeout parameter. You can find the field under TV Server Configuration -> General -> Scan (tab).

    This time you will need to take a backup of four files:
    1. TVLibrary.dll
    2. TVLibrary.Interfaces.dll
    3. SetupTv.exe
    4. TvService.exe

    You'll also need to add an entry to the settings table in your database. Hopefully you know how to do this. If not, let me know and I will try to help you with more specific instructions.

    Add to the "setting" table:
    tag="timeoutMotor"
    value="5"

    Let me know how you get on... :D

    [Edit: attachment removed to save space on my account]
     

    MaxT

    MP Donator
  • Premium Supporter
  • December 9, 2009
    112
    13
    Home Country
    Russian Federation Russian Federation
    Hi mm1352000!

    Tried this and still no go :(

    I've put Motor timeout 33 and tune timeout 26 not to make them equal and round in total.

    Seems that something blocks the signal lock while dvb: LockedInOnSignal waiting ..... Is it possible to run this after motor timeout?

    Regards,

    MaxT
     

    Users who are viewing this thread

    Top Bottom