Posts by HarryH

    Hi QBJack ,

    please can you provide the current content of your config.txt

    cat /flash/config.txt

    and try if the MCU of the case is detected?

    i2cdetect -y 1

    The output should look as follows, where 0x1a is the address assigned by the MCU:

    Code
    LibreELEC:~ # i2cdetect -y 1
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00:                         -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- 1a -- -- -- -- -- 
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- -- --

    If the MCU is not detected but the I2C working without error messages, please power cycle the case (unplug the power supply for some seconds) and try again afterwards.

    A separate service shouldn't be running, The addon is running as a thread of the KODI process. You can/should enable the debug logging to get more insights what happens with the addon and please provide a link to the log:

    https://wiki.libreelec.tv/support/log-files

    If you have previously experimented with other solutions (argon1.sh /argonone.service ...) on your current LibreELEC installation, you should make sure that there are no fragments left that could conflict with the addon.

    Are there a chance that the Python bindings for libgpiod are official included into the virtual rpi-tools addon? libgpiod is already part of the system-tools addon, only the python bindings are currently missing.

    libgpiod/bindings/python at v2.2.x · brgl/libgpiod
    This is a mirror of the original repository over at kernel.org. This github page is for discussions and issue reporting only. PRs can be discussed here but the…
    github.com
    gpiod
    Python bindings for libgpiod
    pypi.org


    Why?

    Since LibreELEC 12 gpiozero is the main module intented to interact with the GPIO pins. But there are some ugly problems:

    • gpiozero takes to long to terminate (killed by KODI after 5 seconds during shutdown, may be related to the lgpio issue explained below) and doesn't frees the used GPIO ressources, so it's need to reboot instead of disable/enable the addon to get it work again
    • gpiozero is slower than libgpiod because of additional abstraction layers: https://adafruit-playground.com/u/MakerMelissa…-raspberry-pi-5
    • lgpio can be used without gpiozero to workaround the blocked ressource issue of gpiozero, but it seems to start some kind of threading as soon the Python module lgpio is imported. The thread with the imported lgpio module doesn't stop within 5 seconds (the hard limit for the CPythonInvoker of KODI) and prevents KODI to restart/shutdown in usual time. It takes 30 seconds to "systemctl restart kodi" or to shutdown LibreELEC if lgpio is directly or indirectly via gpiozero imported in a script addon. Therefore I think rpi-lgpio (RPi.GPIO replacement) will do have the same restriction.

    For a cross-check, I compiled the rpi-tools addon for testing so that it also contains these bindings. If I use gpiod instead of gpiozero / lgpio for Argon40 Device Configuration addon the "systemctl restart kodi" takes only 4 - 6 seconds (not 30 seconds), depending how much background tasks are currently running. This will enable again an ordered shutdown, if the remote control power button is used for the case shutdown instead of the KODI menu. Another story with a firmware restriction (10 seconds limit) of the Argon40 case...

    Yes, I can include the bindings in the Argon40 addon, but I would prefer a globally available gpiod Python module so that others also have the advantage of choosing the best working module for their use case.

    Theoretical it's possible, but seems depends on your existing equipment and cabeling. Within the CEC adapter settings you can configure what should happen on power on/off/standby events of KODI. The issue could be if you need to signal KODI as "active source at startup" to get the TV remote control working for CEC or to switch to the right input, this triggers some TVs to power on.

    Wasn't there some fixes in the nightly builds released after 12.0.1 regarding some issues in conjunction with DENON AVRs?

    tomstephens89
    September 8, 2024 at 6:58 PM


    JohnWayne111 , which version of LE do you have installed? Already tried with a recent nightly build for a cross check?

    Hey, yes, the last nightly works.
    Thank you for the hint.
    An no, it is a 8GB Raspberry.

    But yes, looks like the MCU code is similar what you wrote:

    You are the first to confirm my suspicion from the linked thread that equipment variants other than the 2GiB version with this new chip version are in the wild. Nice to know.

    It doesn't look that you have got the 8GiB version, looks more like the hardware revision 2712D0 (released with the 2GiB version). Please try a recent nightly build, which includes the needed Mesa driver patches.

    Already discussed here:

    wizardly_jennings
    October 10, 2024 at 9:50 PM

    I didn't want to distract. Nice to know that LE itself shouldn't be affected. It was not obvious to me whether it was mounted exclusively via LE and not via the operating system. And because I could reproduce the issue with 2 desktop linux clients in daily use too, I would only ensure that RomanHT is aware of it.

    Most of the usually LE traffic is read-only (with the exception of TVheadend recordings, etc.), but he writes from LE device to NAS so that he could have been affected ...

    Sure, the freeze problem itself is another topic.

    The board mentioned by popcornmix works for RPi4. You can teach a remote button of your choice to the board or use the shown button to turn it on and off. I know this because I corrected the required scripts for some people on this and another forum and got some positive feedback. But unfortunately, it's discontinued and may not be officially compatible with the RPi5 (integrated max current limit of the RemotePi board).

    Regardless of your current freezing problem, I would not recommend transferring (writing) data via SMB as long as the kernel version used is greater than 6.2.16 and less than 6.10.9. There exists a ugly regression and a high risk that you get corrupt data :!:

    [REGRESSION] Corruption on cifs / smb write on ARM, kernels 6.3-6.9 - James Young
    Intermittent data corruption probably in Linux 6.6.52 SMB client - Zack Weinberg

    I do not believe that it was the intention of the developers/maintainers ... of LibreELEC was to break something. And the root cause is an edge case in the concept of how lgpio works and not a problem of LibreELEC.

    I know it's hard to accept, but if you look in detail, you'll realise that all modern operating systems try to protect themselves against malicious changes. This will also be the reason why most paths are in a read-only file system. lgpio should be able to handle this, but it doesn't automatically. Therefore the needed hint with the working directory.

    A customised addon version like the one you provide for users of older scripts as a starting aid is well-intentioned and also helpful for the initial approach. However, it also needs a maintainer for further updates of the included Python modules to ensure compatibility to new kernel versions, RPi hardware versions and so on. Some approaches such as rpi-lgpio are also only a compromise and do not behave identically to the widely used RPi.RPIO in 100% of the use cases. Especially in terms of performance (regarding this gpiozero seems the worst one, because it's a additional layer). So sometimes it is better to deal with the new variants like lgpio or gpiod (libgpiod) directly. Otherwise it's just a long languish.

    But that's just my own opinion...

    As long your YAMAHA AVR doesn't pass through the EDID data without cut off the important resolutions/information, Da Flex suggestion is a workaround to use AVR (Audio only) and the TV connection simultaneous.

    Do you have already checked if you have the recent firmware version for your AVR? It seems that the AVR currently does something wrong. In most cases, such problems can be resolved by updating the firmware or sometimes by using a different HDMI input on the AVR.

    The script itself is working, but you must add a workaround for lgpio. Please try that version:

    As your RPi is supplied with power via the HAT, you may encounter another problem. You are bypassing the negotiation via the Power Delivery protocol. So I assume the RPi5 is limited to 3000mA by default. Please see my comment from here:

    HarryH
    June 23, 2024 at 12:23 PM

    I would like to provide you with some useful links. But I'm not familiar with the behaviour of tvheadend because I don't use it and don't have the equipment to simulate it on your behalf. I use set-top boxes/SAT receivers for live TV and therefore know the limitations associated with it.

    Please understand the possibility to record multiple programmes from the same transponder (MUX) with only one tuner in use as a benefit for free. I would assume that tvheadend supports that out of the box, without special settings. It depends more on your typical TV usage if you a have a benefit of it or not.

    For example:
    If you have a primary place in your home, where you and your family most times join to watch TV together I would place the device with the most available tuners there. From your mentioned list the Hauppauge Dual Tuner looks like something to me, because it's mostly directly supported by the linux kernel. You are able to watch a show with the first tuner unit and can run a record in the background at the second tuner. If you have a second overlapping/simultaneous record scheduled and fortunately the additional program to record is receivable via one of the already tuned transponders (tuner1: live tv, tuner2: current running record), then this additional record is also possible. If this program is played out on a third transponder only, this 2nd record isn't possible. Thats all.

    It looks to me like you could use the remaining devices (RPi with HAT, August on Windows) as a Tvheadend SAT>IP server. If you need a 3rd or 4th tuner in your typical use case, you could add these devices as network tuners in Tvheadend and have a total of 4 tuners available in one KODI instance. Several combinations of your 3 devices are possible, but to make it useful for everyday use, the remote devices should run 24/7 without interruption.

    I hope this attempt to explain clarify somethings to you. :)

    noggin is technically right. Many tuners can only handle 1 transponder/frequency at the same time. A transponder contains various multiplexed channels. If the channels/programmes are received via the same transponder/frequency you doesn't need an additional tuner.
    I assume, that the programmes mentioned by noggin example are played out via the same transponder. On that way, you can theoretically record/look more than 4 programmes at the same time with only one tuner if your hardware is fast enough. Some sat receivers working like that and you can record 8+ channels/programmes at the same time if CPU/HDD doesn't limit.

    There are also tuner modules available with FBC (Full Band Capture) support. Such kind of tuners can handle multiple frequencies at the same time. I don't know if these are exists for DVB-T2 too and supported by Tvheadend, but this would additional multiply the count of simultaneous records with only one tuner.