1 .. Permission is granted to copy, distribute and/or modify this
2 .. document under the terms of the GNU Free Documentation License,
3 .. Version 1.1 or any later version published by the Free Software
4 .. Foundation, with no Invariant Sections, no Front-Cover Texts
5 .. and no Back-Cover Texts. A copy of the license is included at
6 .. Documentation/media/uapi/fdl-appendix.rst.
8 .. TODO: replace it to GFDL-1.1-or-later WITH no-invariant-sections
10 .. _remote_controllers_sysfs_nodes:
12 *******************************
13 Remote Controller's sysfs nodes
14 *******************************
16 As defined at ``Documentation/ABI/testing/sysfs-class-rc``, those are
17 the sysfs nodes that control the Remote Controllers:
25 The ``/sys/class/rc/`` class sub-directory belongs to the Remote
26 Controller core and provides a sysfs interface for configuring infrared
27 remote controller receivers.
35 A ``/sys/class/rc/rcN`` directory is created for each remote control
36 receiver device where N is the number of the receiver.
39 .. _sys_class_rc_rcN_protocols:
41 /sys/class/rc/rcN/protocols
42 ===========================
44 Reading this file returns a list of available protocols, something like::
46 rc5 [rc6] nec jvc [sony]
48 Enabled protocols are shown in [] brackets.
50 Writing "+proto" will add a protocol to the list of enabled protocols.
52 Writing "-proto" will remove a protocol from the list of enabled
55 Writing "proto" will enable only "proto".
57 Writing "none" will disable all protocols.
59 Write fails with ``EINVAL`` if an invalid protocol combination or unknown
60 protocol name is used.
63 .. _sys_class_rc_rcN_filter:
65 /sys/class/rc/rcN/filter
66 ========================
68 Sets the scancode filter expected value.
70 Use in combination with ``/sys/class/rc/rcN/filter_mask`` to set the
71 expected value of the bits set in the filter mask. If the hardware
72 supports it then scancodes which do not match the filter will be
73 ignored. Otherwise the write will fail with an error.
75 This value may be reset to 0 if the current protocol is altered.
78 .. _sys_class_rc_rcN_filter_mask:
80 /sys/class/rc/rcN/filter_mask
81 =============================
83 Sets the scancode filter mask of bits to compare. Use in combination
84 with ``/sys/class/rc/rcN/filter`` to set the bits of the scancode which
85 should be compared against the expected value. A value of 0 disables the
86 filter to allow all valid scancodes to be processed.
88 If the hardware supports it then scancodes which do not match the filter
89 will be ignored. Otherwise the write will fail with an error.
91 This value may be reset to 0 if the current protocol is altered.
94 .. _sys_class_rc_rcN_wakeup_protocols:
96 /sys/class/rc/rcN/wakeup_protocols
97 ==================================
99 Reading this file returns a list of available protocols to use for the
100 wakeup filter, something like::
102 rc-5 nec nec-x rc-6-0 rc-6-6a-24 [rc-6-6a-32] rc-6-mce
104 Note that protocol variants are listed, so ``nec``, ``sony``, ``rc-5``, ``rc-6``
105 have their different bit length encodings listed if available.
107 Note that all protocol variants are listed.
109 The enabled wakeup protocol is shown in [] brackets.
111 Only one protocol can be selected at a time.
113 Writing "proto" will use "proto" for wakeup events.
115 Writing "none" will disable wakeup.
117 Write fails with ``EINVAL`` if an invalid protocol combination or unknown
118 protocol name is used, or if wakeup is not supported by the hardware.
121 .. _sys_class_rc_rcN_wakeup_filter:
123 /sys/class/rc/rcN/wakeup_filter
124 ===============================
126 Sets the scancode wakeup filter expected value. Use in combination with
127 ``/sys/class/rc/rcN/wakeup_filter_mask`` to set the expected value of
128 the bits set in the wakeup filter mask to trigger a system wake event.
130 If the hardware supports it and wakeup_filter_mask is not 0 then
131 scancodes which match the filter will wake the system from e.g. suspend
132 to RAM or power off. Otherwise the write will fail with an error.
134 This value may be reset to 0 if the wakeup protocol is altered.
137 .. _sys_class_rc_rcN_wakeup_filter_mask:
139 /sys/class/rc/rcN/wakeup_filter_mask
140 ====================================
142 Sets the scancode wakeup filter mask of bits to compare. Use in
143 combination with ``/sys/class/rc/rcN/wakeup_filter`` to set the bits of
144 the scancode which should be compared against the expected value to
145 trigger a system wake event.
147 If the hardware supports it and wakeup_filter_mask is not 0 then
148 scancodes which match the filter will wake the system from e.g. suspend
149 to RAM or power off. Otherwise the write will fail with an error.
151 This value may be reset to 0 if the wakeup protocol is altered.