Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add cec stendby for android 11 #31

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion addon.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="screensaver.turnoff" name="Turn Off" version="0.10.3" provider-name="dagwieers">
<addon id="screensaver.turnoff" name="Turn Off" version="0.11.0" provider-name="dagwieers">
<requires>
<import addon="xbmc.python" version="2.25.0"/>
</requires>
Expand All @@ -18,6 +18,9 @@ Next to managing your display, it can also manage your device power state, log y
<source>https://github.com/dagwieers/screensaver.turnoff</source>
<forum>https://forum.kodi.tv/showthread.php?tid=331076</forum>
<news>
v0.11.0 (2024-01-11)
- add support for cec on android 11

v0.10.3 (2020-08-01)
- Workflow changes for Matrix

Expand Down
6 changes: 5 additions & 1 deletion resources/language/resource.language.en_gb/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,14 @@ msgid "CEC on Android (kernel)"
msgstr ""

msgctxt "#32118"
msgid "Backlight on Raspberry Pi (kernel)"
msgid "CEC on Android 11 (kernel)"
msgstr ""

msgctxt "#32119"
msgid "Backlight on Raspberry Pi (kernel)"
msgstr ""

msgctxt "#32120"
msgid "Backlight on Odroid C2 (kernel)"
msgstr ""

Expand Down
2 changes: 1 addition & 1 deletion resources/settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<settings>
<category id="display" label="32100">
<setting type="lsep" label="32101"/> <!-- display intro -->
<setting id="display_method" type="select" label="32102" help="32103" lvalues="32110|32111|32112|32113|32114|32115|32116|32117|32118|32119" default="1"/>
<setting id="display_method" type="select" label="32102" help="32103" lvalues="32110|32111|32112|32113|32114|32115|32116|32117|32118|32119|32120" default="1"/>
<setting type="text" label="32103" enable="false"/> <!-- display_label -->
<setting type="text" label="32104" enable="false"/> <!-- cec_label -->
<setting type="text" label="32105" enable="false"/> <!-- rpi_label -->
Expand Down
4 changes: 4 additions & 0 deletions screensaver.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@
function='run_command',
args_off=['su', '-c', 'echo 0 >/sys/devices/virtual/graphics/fb0/cec'],
args_on=['su', '-c', 'echo 1 >/sys/devices/virtual/graphics/fb0/cec']),
dict(name='cec-android11', title='CEC on Android11 (kernel)',
function='run_command',
args_off=['su', '-c', 'echo 0x40 0x36 > /sys/class/cec/cmd'],
args_on=['su', '-c', 'echo 0x40 0x04 > /sys/class/cec/cmd']),
# NOTE: Contrary to what one might think, 1 means off and 0 means on
dict(name='backlight-rpi', title='Backlight on Raspberry Pi (kernel)',
function='run_command',
Expand Down