香橙派PC Plus电脑开发板红外接收测试

时间:2024-05-21 16:06:14

香橙派PC Plus是一款开源的单板电脑,新一代的arm开发板,使用全志四核高性能处理器Allwinner H3系统级芯片,同时拥有1GB DDR3 内存,板载8GB EMMC Flash 存储,可以运行Android4.4、Ubuntu、Debian等操作系统。
Orange Pi PC Plus体积很小,尺寸仅56mm*85mm,设计却紧凑美观,引用了相当丰富的功能接口,包括HDMI、3.5mm音频、百兆以太网、wifi、3*USB2.0 Host、1*USB-OTG、CSI接口摄像头等,并且兼容树莓派GPIO口,拥有独特的调试串口等。

香橙派PC Plus电脑开发板红外接收测试


Orange Pi Pc Plus 板载有一个红外接收头,今天我们就来看看怎么在armbian的镜像上测试它:

1)下载armbian的ubuntu的镜像,随便哪个版本,然后烧录启动Orange Pi Pc Plus 开发板

2)然后安装ir-keytable 红外测试软件
[email protected]:~# apt update
[email protected]:~# apt-get install ir-keytable 

3)然后执行ir-keytable可以查看红外设备的信息
[email protected]:~# ir-keytable 
Found /sys/class/rc/rc0/ (/dev/input/event5) with:
    Name: sunxi-ir
    Driver: sunxi-ir, table: rc-empty
    lirc device: /dev/lirc0
    Supported protocols: other lirc rc-5 rc-5-sz jvc sony nec sanyo mce_kbd rc-6 sharp xmp 
    Enabled protocols: lirc 
    bus: 25, vendor/product: 0001:0001, version: 0x0100
    Repeat delay = 500 ms, repeat period = 125 ms

4)在终端中输入ir-keytable -c -p NEC -t命令,然后使用红外遥控器对着Orange Pi开发板的红外接收头按下按键就能在终端中看到接收到的按键编码了
[email protected]:/# ir-keytable -c -p NEC -t
Old keytable cleared
Protocols changed to nec 
Testing events. Please, press CTRL-C to abort.
5514.329534: lirc protocol(nec): scancode = 0x45c
5514.329619: event type EV_MSC(0x04): scancode = 0x45c
5514.329619: event type EV_SYN(0x00).
5514.832257: lirc protocol(nec): scancode = 0x45c
5514.832323: event type EV_MSC(0x04): scancode = 0x45c