Open main menu

Wiki-Orange Pi β

Changes

Orange Pi Zero 3

320 bytes added, 13:42, 11 July 2023
Infrared receiving test
</div></li>
<li><p>Install ir-keytable infrared testing software</p></li></ol>
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''sudo''' '''apt update'''
orangepi@orangepi:~$ '''sudo''' '''apt-get install -y ir-keytable'''
|}</ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>Then execute ir-keytable to view the information of the infrared device</p>
<ol style="list-style-type: lower-alpha;">
<li>linux5.4 system output is as follows</li></ol></li></ol>
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''ir-keytable'''
Found /sys/class/rc/rc0/ (/dev/input/event1) with:
::Driver: sunxi-rc-recv, table: rc_map_sunxi lirc device: /dev/lirc0
Supported protocols:: lirc necdevice: /dev/lirc0
Enabled ::Supported protocols: lirc nec
Name: sunxi_ir_recv:Enabled protocols: lirc nec
bus: 25, vendor/product: 0001Name:0001, version: 0x0100sunxi_ir_recv
Repeat delay = 500 ms::bus: 25, repeat period = 125 msvendor/product: 0001:0001, version: 0x0100
::Repeat delay = 500 ms, repeat period = 125 ms
|}
</ol>
<ol start="2" style="list-style-type: lower-alpha;">
<li><p>The output of the linux6.1 system is as follows</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>orangepi@orangepi:~$ '''ir-keytable'''</p>
<p>Found /sys/class/rc/rc0/ with:</p>
:<p>Name: sunxi-ir</p>:<p>Driver: sunxi-ir</p>:<p>Default keymap: rc-empty</p>:<p>Input device: /dev/input/event5</p>:<p>LIRC device: /dev/lirc0</p>:<p>Attached BPF protocols: Operation not permitted</p>:<p>Supported kernel protocols: lirc rc-5 rc-5-sz jvc sony nec sanyo mce_kbd rc-6 sharp xmp imon rc-mm</p>:<p>Enabled kernel protocols: lirc</p>:<p>bus: 25, vendor/product: 0001:0001, version: 0x0100</p>:<p>Repeat delay = 500 ms, repeat period = 125 ms</p>|}</li></ol></li></ol>
<!-- -->
<ol start="4" style="list-style-type: decimal;">
<li><p>Before testing the infrared receiving function, you need to prepare an infrared remote controller dedicated to Orange Pi, '''<span style="color:#FF0000">other remote controllers do not support it</span>'''</p>
<div class="figure">
<li><p>Then enter the '''ir-keytable -t''' command in the terminal, and then use the infrared remote control to press the button against the infrared receiver of the Orange Pi development board to see the received key code in the terminal</p>
<ol style="list-style-type: lower-alpha;">
<li>linux5.4 system output is as follows</li></ol></li></ol>
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''sudo ir-keytable -t'''
1598339152.914715: event type EV_MSC(0x04): scancode = 0xfb0410
|}</ol>
<ol start="2" style="list-style-type: lower-alpha;">
<li><p>linux6.1 system output is as follows</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>orangepi@orangepi:~$ '''sudo ir-keytable -c -p NEC -t'''</p>
<p>Old keytable cleared</p>
<p>202.063219: lirc protocol(nec): scancode = 0x45c</p>
<p>202.063249: event type EV_MSC(0x04): scancode = 0x45c</p>
<p>202.063249: event type EV_SYN(0x00).</p>|}</li></ol></li></ol><span id="temperature-sensor"></span>
<span id="temperature-sensor"></span>
== Temperature sensor ==