Hello Guest, if you are reading this it means you have not registered yet. Please take a second, Click here to register, and in a few simple steps you will be able to enjoy our community and use our OpenViX support section.
Page 18 of 19 FirstFirst ... 816171819 LastLast
Results 256 to 270 of 273

Thread: Vix 5.1.006. Time wrong

  1. #256
    twol's Avatar
    Title
    Moderator
    Join Date
    Apr 2012
    Posts
    8,383
    Thanks
    987
    Thanked 2,888 Times in 2,243 Posts
    Well, if its any encouragement (?), although OpenPli is very fast normally for most things, when I flash an image, it takes about 15 seconds (after settings are restored and reboot) at least to settle on a time (currently on Transponder and 1st channel is BBC1 HD)
    ... it sits there on the year dot ... for a long time...... never had that with ViX (before hwclock or after)
    Gigablue Quad 4K & UE 4K
    .........FBC Tuners:
    ------------------> DUR-Line DCR 5-1-8-L4 Multiswitch to 1.5M dish(28.2E)
    ------------------> Spaun SUS 5581/33 NFA Multiswitch to 80 cm dish(19.2E)
    .......................> FBC & DVB-S2X into 90cm dish (27.5W) Opticum robust Unicable LNB
    AX HD61, Edision Osmio 4K+, Zgemma H9Combo, Octagon SF8008 , gbtrio4k, h9se using Legacy ports on multiswitches
    Zgemma H9 C/S into Giga4K

  2. #257
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    The issue is less about getting the time set and more about ensuring that it if isn't set:
    1. it keeps trying to set the time using a method that can work,
    2. once the time is set that it keeps trying to check the time in the configured way, if that is possible,
    3. until the time is set it doesn't run any Recording or Power timers.

    I'm not sure that any of these is actually guaranteed in ViX.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  3. #258
    twol's Avatar
    Title
    Moderator
    Join Date
    Apr 2012
    Posts
    8,383
    Thanks
    987
    Thanked 2,888 Times in 2,243 Posts
    Well, I know it is an issue with Fat-Tony, but I don‘t have an issue and I am still flashing new images fairly frequently on NTP time.-........ so don’t get carried away with (perhaps) one particular issue.
    As mentioned I get faster time setting in ViX than Pli.
    Gigablue Quad 4K & UE 4K
    .........FBC Tuners:
    ------------------> DUR-Line DCR 5-1-8-L4 Multiswitch to 1.5M dish(28.2E)
    ------------------> Spaun SUS 5581/33 NFA Multiswitch to 80 cm dish(19.2E)
    .......................> FBC & DVB-S2X into 90cm dish (27.5W) Opticum robust Unicable LNB
    AX HD61, Edision Osmio 4K+, Zgemma H9Combo, Octagon SF8008 , gbtrio4k, h9se using Legacy ports on multiswitches
    Zgemma H9 C/S into Giga4K

  4. #259
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by twol View Post
    Well, I know it is an issue with Fat-Tony, but I don‘t have an issue and I am still flashing new images fairly frequently on NTP time.-........ so don’t get carried away with (perhaps) one particular issue.
    As mentioned I get faster time setting in ViX than Pli.
    I've started so I'd like to finish....
    If necessary I'll come up with a compromise and think about the loose ends later.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  5. The Following 2 Users Say Thank You to birdman For This Useful Post:

    Joe_90 (02-02-18),twol (02-02-18)

  6. #260
    Joe_90's Avatar
    Title
    Moderator
    Join Date
    Mar 2014
    Location
    Wicklow, Ireland
    Posts
    4,100
    Thanks
    1,265
    Thanked 1,115 Times in 879 Posts
    That's just it - I haven't had a single issue with my GB Quad+ which uses NTP (but is hardwired to the LAN). I've disabled the fake-hwclock script for now on the HD51 (but kept NTP sync) and I'll see how I get on with a standard Release build for a number of days. I'm now back on a clean build but without the hwclock script. Without a plausible time being available, maybe the fallback mechanism (to transponder time) will overcome any slowness in the wifi network. I'll monitor closely. Thanks to @birdman for all the work so far ...and I will test any further updates to the code.
    GB Quad Plus, Mut@nt HD51, AX HD61, 80cm dish and Supreme Dark motor. Sony STR-DN 1060, Sony UHP-H1 Bluray, Odroid N2+ (CoreElec), Monitor Audio Bronze 5.1 speakers

  7. #261
    twol's Avatar
    Title
    Moderator
    Join Date
    Apr 2012
    Posts
    8,383
    Thanks
    987
    Thanked 2,888 Times in 2,243 Posts
    Quote Originally Posted by birdman View Post
    I've started so I'd like to finish....
    If necessary I'll come up with a compromise and think about the loose ends later.
    Don‘t get me wrong, I really appreciate all the work you have put in. As soon as I saw the 1st changes go into the OE-A from Spacerat (19/12/2017), I thought brave guy..... there are always so many issues with timing between components when you change the timing basis.... and it‘s not easy to resolve.
    Gigablue Quad 4K & UE 4K
    .........FBC Tuners:
    ------------------> DUR-Line DCR 5-1-8-L4 Multiswitch to 1.5M dish(28.2E)
    ------------------> Spaun SUS 5581/33 NFA Multiswitch to 80 cm dish(19.2E)
    .......................> FBC & DVB-S2X into 90cm dish (27.5W) Opticum robust Unicable LNB
    AX HD61, Edision Osmio 4K+, Zgemma H9Combo, Octagon SF8008 , gbtrio4k, h9se using Legacy ports on multiswitches
    Zgemma H9 C/S into Giga4K

  8. #262
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by fat-tony View Post
    That's just it - I haven't had a single issue with my GB Quad+ which uses NTP (but is hardwired to the LAN).
    I've not had any problem on my systems either, but then I use transponder time.
    It is easy to see that some problems could easily occur, though, and it's not that difficult to avoid most of them.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  9. #263
    SpaceRat's Avatar
    Title
    Senior Member
    Join Date
    Apr 2015
    Posts
    206
    Thanks
    25
    Thanked 79 Times in 52 Posts
    Just my 2 cents, as I don't have the time to assist:

    birdman is right about the problem being that E2 will perform time related stuff without making sure the time was really synced. It's just not point 3 but the top point 1 in the list, because everything else could have happened before too.
    Letting ntpdate-sync create a flagfile indicating success and making E2 wait for it (rather than just the kick-off of ntpdate-sync) before setting m_time_ready is exactly the same solution as the one I would have come up with if I still had the time.

    All the other things (auto-fallback NTP-> DVB and so on) are just a bonus:
    The option to configure NTP and having it fail permanently always existed.

    Gesendet von meinem SM-N910F mit Tapatalk
    Receiver/TV:
    • Vu+ Duo² 4*S2+2*C / 1.8TB HDD / OpenATV 6.1@Samsung 50" Plasma
    • AX Quadbox 2400 / 2*S2/2*C / 930GB HDD / OpenATV 6.1@Samsung 32" LCD
    • Vu+ Solo² / 465GB HDD / OpenATV 6.1
    • Vu+ Solo² / 230GB HDD / OpenATV 6.1
    • DVBSky S2-Twin-Tuner PCIe@Samsung SyncMaster T240HD (PC)
    Pay TV: Redlight Mega, Brazzers TV Europe, XXL, HD-, Sky
    Internet: Unitymedia 1play 100 / Cisco EPC3212 + Linksys WRT1900ACS + Fritz!Box 7390 / IPv4 (UM) + IPv6 (HE)

  10. #264
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by SpaceRat View Post
    Letting ntpdate-sync create a flagfile indicating success and making E2 wait for it (rather than just the kick-off of ntpdate-sync) before setting m_time_ready is exactly the same solution as the one I would have come up with if I still had the time.
    I'm also trying to do the reverse - set a flag if the transponder time has been set (just so that any forever-backgrounded NTP-trier can give up). The code seems to assume that if you have a transponder then the time can be obtained from it "immediately". Does anyone know whether that is true (not that the time is correct, but that " a time" can be gotten)?
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  11. #265
    SpaceRat's Avatar
    Title
    Senior Member
    Join Date
    Apr 2015
    Posts
    206
    Thanks
    25
    Thanked 79 Times in 52 Posts
    Quote Originally Posted by birdman View Post
    I'm also trying to do the reverse - set a flag if the transponder time has been set (just so that any forever-backgrounded NTP-trier can give up).
    I was considering a slightly different approach:

    In order to solve the possible interfering of DVB and NTP time syncs, one could create an dvbdate-sync app, the source code already exists:
    https://github.com/linuxstb/dvbtools...master/dvbdate

    That way all the time syncing could be offloaded to the OS (yocto, Linux) and E2 wouldn't need to care about it at all (Except to allow the user to configure its preferences and checking for success).

    The options should be
    - NTP first, DVB fallback
    - NTP only
    - DVB first, NTP fallback
    - DVB only

    plus:
    - Fall back after n failed attempts: >=3

    ntpdate should only give up if DVB fallback is set and only temporarily.
    This is due to NTP being much more accurate than DVB and if the user decides to use NTP only, DVB sync is no option at all.

    One actually needs at least two different flagfiles:
    - If a sync succeeded within the current "session" at all
    - A counter for the failed attempts

    As long as NTP succeeded once (e.g. at boot), there shouldn't be an immedeate fall-back to DVB sync just because a later NTP sync failed once.
    If NTP succeeds only once per hour, that time is most likely still better than that from transponders (Where I can easily find transponders that are off by ~ 5min).

    Once the sync fell back, it should also revert to the preferred method as soon as it succeeds again, for the same reason as above.

    My idea so far was to write the time of the last successful sync (after sync of course) into a flag file
    /var/tmp/ntp-synced
    and the amount of failed attempts into
    /var/tmp/ntp-fails

    So if /var/tmp/ntp-synced exists, we had a successful sync at least once within the current session (As /var/tmp is volatile and its content is lost on reboot), by reading it, we can learn when it succeeded the last time.
    On successful sync, "0" gets written into /var/tmp/ntp-fails, so if /var/tmp/ntp-synced exists and /var/tmp/ntp-fails contains "0", then we know it was the latest sync that succeeded -> Everything ok.

    If /var/tmp/ntp-synced does not exist, we have to fall back to DVB until NTP succeeds.

    If /var/tmp/ntp-synced exists but /var/tmp/ntp-fails contains "n" with "n > failed attempts before fallback", we also have to fall-back to DVB until NTP succeeds again (= /var/tmp/ntp-fails contains "0" again).




    Quote Originally Posted by birdman View Post
    The code seems to assume that if you have a transponder then the time can be obtained from it "immediately". Does anyone know whether that is true (not that the time is correct, but that " a time" can be gotten)?
    For DVB sync, m_time_ready gets set to true when the time is already retrieved:
    https://github.com/OpenViX/enigma2/b...btime.cpp#L515

    It becomes true a few (milli)seconds before the system time gets actually written though.
    That's due to later return statements inside the code that would prevent m_time_ready becoming true if transponder time was retrieved but has no difference to current time.
    Ugly spaghetti code ...
    Receiver/TV:
    • Vu+ Duo² 4*S2+2*C / 1.8TB HDD / OpenATV 6.1@Samsung 50" Plasma
    • AX Quadbox 2400 / 2*S2/2*C / 930GB HDD / OpenATV 6.1@Samsung 32" LCD
    • Vu+ Solo² / 465GB HDD / OpenATV 6.1
    • Vu+ Solo² / 230GB HDD / OpenATV 6.1
    • DVBSky S2-Twin-Tuner PCIe@Samsung SyncMaster T240HD (PC)
    Pay TV: Redlight Mega, Brazzers TV Europe, XXL, HD-, Sky
    Internet: Unitymedia 1play 100 / Cisco EPC3212 + Linksys WRT1900ACS + Fritz!Box 7390 / IPv4 (UM) + IPv6 (HE)

  12. The Following User Says Thank You to SpaceRat For This Useful Post:

    Joe_90 (04-02-18)

  13. #266
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by SpaceRat View Post
    In order to solve the possible interfering of DVB and NTP time syncs, one could create an dvbdate-sync app, the source code already exists:
    https://github.com/linuxstb/dvbtools...master/dvbdate
    ...but doesn't work.
    Code:
    root@et8000:~# ./dvbdate 
    ./dvbdate: Nothing to read from fd_date - try tuning to a multiplex?
    It's querying /dev/dvb/adapter0/demux0 by default, but I've also tried it with /dev/dvb/adapter0/demux7 and /dev/dvb/adapter1/demux0 (an external USB tuner) with the same result.
    It looks like it expects you to have run dvbtune first, which isn't compatible with having enigma2 running(?).
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  14. #267
    SpaceRat's Avatar
    Title
    Senior Member
    Join Date
    Apr 2015
    Posts
    206
    Thanks
    25
    Thanked 79 Times in 52 Posts
    We would need to check with E2 first if it has already tuned a transponder (Then use that) and if not, tune one using dvbtune (e.g. while E2 is in standby).
    Receiver/TV:
    • Vu+ Duo² 4*S2+2*C / 1.8TB HDD / OpenATV 6.1@Samsung 50" Plasma
    • AX Quadbox 2400 / 2*S2/2*C / 930GB HDD / OpenATV 6.1@Samsung 32" LCD
    • Vu+ Solo² / 465GB HDD / OpenATV 6.1
    • Vu+ Solo² / 230GB HDD / OpenATV 6.1
    • DVBSky S2-Twin-Tuner PCIe@Samsung SyncMaster T240HD (PC)
    Pay TV: Redlight Mega, Brazzers TV Europe, XXL, HD-, Sky
    Internet: Unitymedia 1play 100 / Cisco EPC3212 + Linksys WRT1900ACS + Fritz!Box 7390 / IPv4 (UM) + IPv6 (HE)

  15. #268
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by SpaceRat View Post
    We would need to check with E2 first if it has already tuned a transponder.
    It had, hence an attempt to use dvbtune resulted in an error that it was in use.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  16. #269
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Well, this is where I've got to now:

    ntpdate-sync.zip

    (there are some debug statements in there...).

    This is an ntpdate-sync which:
    • Has a few different modes of running - it sets different ways according to whether it has been called by ifup, from enigma2 or from a terminal. It also has options so you can change these.
    • Uses flock rather than the (more complicated) lockfile-create/-touch/-remove method to protect the ntpdate call.
    • Can "try forever" (retries get done up to every minute). This is used by the ifup call. After the first attempt the rest are done in the background.
    • Can do "quick" (single-shot) time sets. This is used by the ifup call.
    • Can run in the background. This is used by the "enigma2" call.
    • Can slew the time (rather than set it absolutely). This used by the "enigma2" call, and the ifup call if enigma2 is already running.
    • The "try forever" code will stop if something else sets the clock. This negates the need for enigma2 to create a marker file saying that it has set the time using a transponder.
    • Creates a marker file the first time it sets the time.


    Provided this can be put into then build then the enigma2 code can also be improved by looking for the marker file.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  17. The Following User Says Thank You to birdman For This Useful Post:

    Joe_90 (06-03-18)

  18. #270
    Joe_90's Avatar
    Title
    Moderator
    Join Date
    Mar 2014
    Location
    Wicklow, Ireland
    Posts
    4,100
    Thanks
    1,265
    Thanked 1,115 Times in 879 Posts
    Hi Gordon - will try out your new version and report back!
    GB Quad Plus, Mut@nt HD51, AX HD61, 80cm dish and Supreme Dark motor. Sony STR-DN 1060, Sony UHP-H1 Bluray, Odroid N2+ (CoreElec), Monitor Audio Bronze 5.1 speakers

Page 18 of 19 FirstFirst ... 816171819 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.