Add suspend mode

  • Hi,


    I currently trying to add support of suspend mode for hyperion.ng.
    I added two signals in hyperion, one for suspend, one for resume.
    On suspend I turn off the leds, on resume I turn it on:


    Code
    CoreELEC:~/.config/sleep.d # ./hyperion-suspend.power pre
    Going to suspend...
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: disabled
    CoreELEC:~/.config/sleep.d # ./hyperion-suspend.power post
    Resume from suspend...
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: enabled


    But the leds are remaining on!? They are not getting updated but they are still on. When I send the resume signal the leds are chaninging like before.


    This line should be called because of the signal:
    https://github.com/hyperion-pr…ddevice/LedDevice.cpp#L42


    I just call:

    Code
    _hyperion(Hyperion::getInstance();
    _hyperio->handleComponentState(hyperion::COMP_LEDDEVICE, true/false);


    Why are the leds not off (black)?

  • It looks like it is just stopping. But this line should send black to the leds, isn't it?
    https://github.com/hyperion-pr…e/LedDevice.cpp#L104-L107


    EDIT:
    I guess I found it. It looks like it get set to black for one time, but after this it get reset to the last frame:

    Code
    [hyperiond LEDDEVICE] <DEBUG> <LedDeviceAdalight.cpp:94:write()> LedDeviceAdalight writebytes 231: 416461004A1F000708000A0B000E10001013001014000F14000E15000D16000D16000D18000F19000F1B00101B000C1402040502040502030402030402030402030302030402030402030405060702030407090A020304050607040506020304002C41002C41050506020303020303020303010202010202010203010303060809050707000D10051012000B0E000B0E000C11040F14000B1200090E050F1400090F00070B000609000406000304000304000204020304090B0C01030300050800050900060900060A00070A00070A00080A00080A00080A000809000709000708000607000607
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: disabled
    [hyperiond LEDDEVICE] <DEBUG> <LedDeviceAdalight.cpp:94:write()> LedDeviceAdalight writebytes 231: 416461004A1F000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
    [hyperiond LEDDEVICE] <DEBUG> <LedDeviceAdalight.cpp:94:write()> LedDeviceAdalight writebytes 231: 416461004A1F000708000A0B000E10001013001014000F14000E15000D16000D16000D18000F19000F1B00101B000C1402040502040502030402030402030402030302030402030402030405060702030407090A020304050607040506020304002C41002C41050506020303020303020303010202010202010203010303060809050707000D10051012000B0E000B0E000C11040F14000B1200090E050F1400090F00070B000609000406000304000304000204020304090B0C01030300050800050900060900060A00070A00070A00080A00080A00080A000809000709000708000607000607


    EDIT2:
    The smoothing have to be disabled also:


    Then it should work...

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!