Linux   发布时间:2022-04-01  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了linux – 在RPI上使用cec-client关闭电视大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。

概述

我有运行Raspbian的RPi B通过HDMI连接到我的LG电视.我成功编译并安装了cec-client,我可以使用命令echo“on 0”|轻松打开电视cec-client -s,但当我尝试使用命令echo“standby 0”|关闭电视时cec-client -s我得到这个输出:opening a connection to the CEC adapt@H_801_5@

我有运行Raspbian的RPi B通过HDMI连接到我的LG电视.我成功编译并安装了cec-client,我可以使用命令echo“on 0”|轻松打开电视cec-client -s,但当我尝试使用命令echo“standby 0”|关闭电视时cec-client -s我得到这个输出

opening a connection to the CEC adapter...
DEBUG:   [             316]     unregistering all CEC clients
DEBUG:   [             318]     Broadcast (F): osd name set to 'Broadcast'
DEBUG:   [             324]     InitHostCEC - vchiq_initialise succeeded
DEBUG:   [             325]     InitHostCEC - vchi_initialise succeeded
DEBUG:   [             326]     InitHostCEC - vchi_connect succeeded
DEBUG:   [             330]     logical address changed to Broadcast (f)
DEBUG:   [             333]     RegisterLogicalAddress - registering address e
DEBUG:   [             605]     logical address changed to Recorder 1 (1)
DEBUG:   [             605]     logical address changed to Free use (E)
DEBUG:   [             605]     Open - vc_cec initialised
NOTICE:  [             605]     connection opened
DEBUG:   [             607]     processor thread started
DEBUG:   [             608]     < broadcast="" (f)="" ->="" tv="" (0):="" poll="" debug:="" [="" 611]="" initiator="" 'broadcast'="" is="" not="" supported="" by="" the="" cec="" adapter.="" using="" 'free="" use'="" instead="" traffic:="" [="" 612]="">< e0="" debug:="" [="" 647]="" >>="" poll="" sent="" debug:="" [="" 647]="" tv="" (0):="" device="" status="" changed="" into="" 'present'="" debug:="" [="" 647]="">< requesting="" vendor="" id="" of="" 'tv'="" (0)="" traffic:="" [="" 647]="">< e0:8c="" debug:="" [="" 1858]="" expected="" response="" not="" received="" (87:="" device="" vendor="" id)="" traffic:="" [="" 1859]="">< e0:8c="" debug:="" [="" 3070]="" expected="" response="" not="" received="" (87:="" device="" vendor="" id)="" notice:="" [="" 3070]="" registering="" new="" cec="" client="" -="" v2.1.4="" debug:="" [="" 3070]="" detecting="" logical="" address="" for="" type="" 'recording="" device'="" debug:="" [="" 3070]="" trying="" logical="" address="" 'recorder="" 1'="" debug:="" [="" 3070]="">< recorder="" 1="" (1)="" ->="" recorder="" 1="" (1):="" poll="" traffic:="" [="" 3071]="">< 11="" debug:="" [="" 3071]="" unregisterlogicaladdress="" -="" releasing="">IoUs logical address
DEBUG:   [            3072]     logical address changed to Broadcast (f)
DEBUG:   [            3073]     RegisterLogicalAddress - registering address 1
DEBUG:   [            3255]     logical address changed to Free use (E)
DEBUG:   [            3255]     logical address changed to Recorder 1 (1)
TRAFFIC: [            3255]     < 11="" debug:="" [="" 3255]="" >>="" poll="" not="" sent="" debug:="" [="" 3256]="" using="" logical="" address="" 'recorder="" 1'="" debug:="" [="" 3256]="" recorder="" 1="" (1):="" device="" status="" changed="" into="" 'handled="" by="" libcec'="" debug:="" [="" 3256]="" recorder="" 1="" (1):="" power="" status="" changed="" from="">Nown' to 'on'
DEBUG:   [            3256]     Recorder 1 (1): vendor = Pulse Eight (001582)
DEBUG:   [            3256]     Recorder 1 (1): CEC version 1.4
DEBUG:   [            3256]     AllocateLogicalAddresses - device '0',type 'recording device',LA '1'
DEBUG:   [            3256]     Recorder 1 (1): osd name set to 'CECTester'
DEBUG:   [            3256]     Recorder 1 (1): menu language set to 'eng'
DEBUG:   [            3258]     GetPhysicalAddress - physical address = 3000
DEBUG:   [            3258]     AutodetectPhysicalAddress - autodetected physical address '3000'
DEBUG:   [            3260]     Recorder 1 (1): physical address changed from ffff to 3000
DEBUG:   [            3262]     < recorder="" 1="" (1)="" ->="" broadcast="" (f):="" physical="" adddress="" 3000="" traffic:="" [="" 3263]="">< 1f:84:30:00:01="" notice:="" [="" 3415]="" cec="" client="" registered:="" libcec="" version="2.1.4,client" version="2.1.4,firmware" version="1,logical" address(es)="Recorder" 1="" (1),physical="" address:="" 3.0.0.0,host:="">Nown-linux-gnueabihf,features: 'P8 USB' 'P8 USB detect' 'RPi',git revision: a560d24,compiled on: Sun Sep 14 17:49:41 UTC 2014 by pi@raspBerrypi on Linux 3.12.28+ (armv6l)
DEBUG:   [            3415]     < recorder="" 1="" (1)="" ->="" tv="" (0):="" osd="" name="" 'cectester'="" traffic:="" [="" 3415]="">< 10:47:43:45:43:54:65:73:74:65:72="" debug:="" [="" 3716]="">< requesting="" power="" status="" of="" 'tv'="" (0)="" traffic:="" [="" 3716]="">< 10:8f="" traffic:="" [="" 3868]="" >>="" 01:8c="" debug:="" [="" 3868]="" >>="" tv="" (0)="" ->="" recorder="" 1="" (1):="" give="" device="" vendor="" id="" (8c)="" debug:="" [="" 3871]="">< recorder="" 1="" (1)="" ->="" tv="" (0):="" vendor="" id="" pulse="" eight="" (1582)="" traffic:="" [="" 3873]="">< 1f:87:00:15:82="" traffic:="" [="" 4087]="" >>="" 01:90:00="" debug:="" [="" 4087]="" >>="" tv="" (0)="" ->="" recorder="" 1="" (1):="" report="" power="" status="" (90)="" debug:="" [="" 4088]="" tv="" (0):="" power="" status="" changed="" from="">Nown' to 'on'
DEBUG:   [            4089]     expected response received (90: report power status)
DEBUG:   [            4091]     < requesting="" vendor="" id="" of="" 'tv'="" (0)="" traffic:="" [="" 4091]="">< 10:8c="" traffic:="" [="" 4323]="" >>="" 0f:87:00:e0:91="" debug:="" [="" 4323]="" >>="" tv="" (0)="" ->="" broadcast="" (f):="" device="" vendor="" id="" (87)="" debug:="" [="" 4323]="" tv="" (0):="" vendor="LG" (00e091)="" debug:="" [="" 4323]="">< recorder="" 1="" (1)="" ->="" broadcast="" (f):="" vendor="" id="" pulse="" eight="" (1582)="" traffic:="" [="" 4323]="">< 1f:87:00:15:82="" debug:="" [="" 4474]="" expected="" response="" received="" (87:="" device="" vendor="" id)="" debug:="" [="" 4475]="" replacing="" the="" command="" handler="" for="" device="" 'tv'="" (0)="" debug:="" [="" 4478]="" tv="" (0):="" cec="" version="" 1.3a="" debug:="" [="" 4479]="" tv="" (0):="" menu="" language="" set="" to="" 'eng'="" debug:="" [="" 4481]="" recorder="" 1="" (1):="" vendor="LG" (00e091)="" debug:="" [="" 4485]="" replacing="" the="" command="" handler="" for="" device="" 'recorder="" 1'="" (1)="" debug:="" [="" 4485]="" recorder="" 1="" (1):="" cec="" version="" 1.3a="" notice:="" [="" 4487]="">< putting="" 'tv'="" (0)="" in="" standby="" mode="" traffic:="" [="" 4488]="">< 10:36="" debug:="" [="" 4552]="" unregistering="" all="" cec="" clients="" notice:="" [="" 4555]="" unregistering="" client:="" libcec="" version="2.1.4,compiled" on:="" sun="" sep="" 14="" 17:49:41="" utc="" 2014="" by="">Berrypi on Linux 3.12.28+ (armv6l)
DEBUG:   [            4559]     Recorder 1 (1): power status changed from 'on' to 'unkNown'
DEBUG:   [            4561]     Recorder 1 (1): vendor = UnkNown (000000)
DEBUG:   [            4564]     Recorder 1 (1): CEC version unkNown
DEBUG:   [            4565]     Recorder 1 (1): osd name set to 'Recorder 1'
DEBUG:   [            4567]     Recorder 1 (1): device status changed into 'unkNown'
DEBUG:   [            4567]     unregistering all CEC clients
DEBUG:   [            4624]     UnregisterLogicalAddress - releasing prevIoUs logical address
DEBUG:   [            4630]     logical address changed to Broadcast (f)

没有任何反应.此外,我只使用CLI,并在一段时间后RPi将电视放入空白屏幕保护程序,但我无法弄清楚如何在我的命令下立即执行此操作.

最佳答案
似乎libCEC没有任何问题.然而,LG TV模型的HDMI-CEC实现可能只是忽略了备用命令.您应该使用其他符合HDMI-CEC标准的设备测试RaspBerry Pi,以检查备用命令是否正常工作.
@H_801_50@

大佬总结

以上是大佬教程为你收集整理的linux – 在RPI上使用cec-client关闭电视全部内容,希望文章能够帮你解决linux – 在RPI上使用cec-client关闭电视所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。