migrate to libcec with cec socket
This commit is contained in:
parent
4a525bb5a6
commit
246535facd
2 changed files with 35 additions and 4 deletions
6
cec.sh
6
cec.sh
|
|
@ -1,15 +1,13 @@
|
|||
#!/bin/bash
|
||||
|
||||
tv_on() {
|
||||
cec-ctl --to 0 --image-view-on
|
||||
#xrandr --output HDMI-A-0 --mode 1920x1080
|
||||
xrandr --output HDMI-A-0 --auto; sleep 3; xrandr --output HDMI-A-0 --mode 1920x1080
|
||||
echo "on 0" > /run/cec.fifo
|
||||
echo "on">~/scripts/PJ/tv_state
|
||||
curl -X POST -d '' $REPORT_TV_ON
|
||||
}
|
||||
|
||||
tv_off() {
|
||||
cec-ctl --to 0 --standby
|
||||
echo "standby 0" > /run/cec.fifo
|
||||
echo "off">~/scripts/PJ/tv_state
|
||||
curl -X POST -d '' $REPORT_TV_OFF
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue