blob: 9c8ff79108583f90ebedf3d493fd22b8807142e9 [file] [log] [blame]
Andrew Scullb4b6d4a2019-01-02 15:54:55 +00001What: /sys/class/rc/
2Date: Apr 2010
3KernelVersion: 2.6.35
4Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
5Description:
6 The rc/ class sub-directory belongs to the Remote Controller
7 core and provides a sysfs interface for configuring infrared
8 remote controller receivers.
9
10What: /sys/class/rc/rcN/
11Date: Apr 2010
12KernelVersion: 2.6.35
13Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
14Description:
15 A /sys/class/rc/rcN directory is created for each remote
16 control receiver device where N is the number of the receiver.
17
18What: /sys/class/rc/rcN/protocols
19Date: Jun 2010
20KernelVersion: 2.6.36
21Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
22Description:
23 Reading this file returns a list of available protocols,
Olivier Deprez157378f2022-04-04 15:47:50 +020024 something like::
25
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000026 "rc5 [rc6] nec jvc [sony]"
Olivier Deprez157378f2022-04-04 15:47:50 +020027
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000028 Enabled protocols are shown in [] brackets.
Olivier Deprez157378f2022-04-04 15:47:50 +020029
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000030 Writing "+proto" will add a protocol to the list of enabled
31 protocols.
Olivier Deprez157378f2022-04-04 15:47:50 +020032
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000033 Writing "-proto" will remove a protocol from the list of enabled
34 protocols.
Olivier Deprez157378f2022-04-04 15:47:50 +020035
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000036 Writing "proto" will enable only "proto".
Olivier Deprez157378f2022-04-04 15:47:50 +020037
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000038 Writing "none" will disable all protocols.
Olivier Deprez157378f2022-04-04 15:47:50 +020039
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000040 Write fails with EINVAL if an invalid protocol combination or
41 unknown protocol name is used.
42
43What: /sys/class/rc/rcN/filter
44Date: Jan 2014
45KernelVersion: 3.15
46Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
47Description:
48 Sets the scancode filter expected value.
Olivier Deprez157378f2022-04-04 15:47:50 +020049
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000050 Use in combination with /sys/class/rc/rcN/filter_mask to set the
51 expected value of the bits set in the filter mask.
52 If the hardware supports it then scancodes which do not match
53 the filter will be ignored. Otherwise the write will fail with
54 an error.
Olivier Deprez157378f2022-04-04 15:47:50 +020055
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000056 This value may be reset to 0 if the current protocol is altered.
57
58What: /sys/class/rc/rcN/filter_mask
59Date: Jan 2014
60KernelVersion: 3.15
61Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
62Description:
63 Sets the scancode filter mask of bits to compare.
64 Use in combination with /sys/class/rc/rcN/filter to set the bits
65 of the scancode which should be compared against the expected
66 value. A value of 0 disables the filter to allow all valid
67 scancodes to be processed.
Olivier Deprez157378f2022-04-04 15:47:50 +020068
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000069 If the hardware supports it then scancodes which do not match
70 the filter will be ignored. Otherwise the write will fail with
71 an error.
Olivier Deprez157378f2022-04-04 15:47:50 +020072
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000073 This value may be reset to 0 if the current protocol is altered.
74
75What: /sys/class/rc/rcN/wakeup_protocols
76Date: Feb 2017
77KernelVersion: 4.11
78Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
79Description:
80 Reading this file returns a list of available protocols to use
Olivier Deprez157378f2022-04-04 15:47:50 +020081 for the wakeup filter, something like::
82
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000083 "rc-5 nec nec-x rc-6-0 rc-6-6a-24 [rc-6-6a-32] rc-6-mce"
Olivier Deprez157378f2022-04-04 15:47:50 +020084
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000085 Note that protocol variants are listed, so "nec", "sony",
86 "rc-5", "rc-6" have their different bit length encodings
87 listed if available.
Olivier Deprez157378f2022-04-04 15:47:50 +020088
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000089 The enabled wakeup protocol is shown in [] brackets.
Olivier Deprez157378f2022-04-04 15:47:50 +020090
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000091 Only one protocol can be selected at a time.
Olivier Deprez157378f2022-04-04 15:47:50 +020092
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000093 Writing "proto" will use "proto" for wakeup events.
Olivier Deprez157378f2022-04-04 15:47:50 +020094
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000095 Writing "none" will disable wakeup.
Olivier Deprez157378f2022-04-04 15:47:50 +020096
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000097 Write fails with EINVAL if an invalid protocol combination or
98 unknown protocol name is used, or if wakeup is not supported by
99 the hardware.
100
101What: /sys/class/rc/rcN/wakeup_filter
102Date: Jan 2014
103KernelVersion: 3.15
104Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
105Description:
106 Sets the scancode wakeup filter expected value.
Olivier Deprez157378f2022-04-04 15:47:50 +0200107
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000108 Use in combination with /sys/class/rc/rcN/wakeup_filter_mask to
109 set the expected value of the bits set in the wakeup filter mask
110 to trigger a system wake event.
Olivier Deprez157378f2022-04-04 15:47:50 +0200111
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000112 If the hardware supports it and wakeup_filter_mask is not 0 then
113 scancodes which match the filter will wake the system from e.g.
114 suspend to RAM or power off.
Olivier Deprez157378f2022-04-04 15:47:50 +0200115
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000116 Otherwise the write will fail with an error.
Olivier Deprez157378f2022-04-04 15:47:50 +0200117
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000118 This value may be reset to 0 if the wakeup protocol is altered.
119
120What: /sys/class/rc/rcN/wakeup_filter_mask
121Date: Jan 2014
122KernelVersion: 3.15
123Contact: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
124Description:
125 Sets the scancode wakeup filter mask of bits to compare.
Olivier Deprez157378f2022-04-04 15:47:50 +0200126
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000127 Use in combination with /sys/class/rc/rcN/wakeup_filter to set
128 the bits of the scancode which should be compared against the
129 expected value to trigger a system wake event.
Olivier Deprez157378f2022-04-04 15:47:50 +0200130
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000131 If the hardware supports it and wakeup_filter_mask is not 0 then
132 scancodes which match the filter will wake the system from e.g.
133 suspend to RAM or power off.
Olivier Deprez157378f2022-04-04 15:47:50 +0200134
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000135 Otherwise the write will fail with an error.
Olivier Deprez157378f2022-04-04 15:47:50 +0200136
Andrew Scullb4b6d4a2019-01-02 15:54:55 +0000137 This value may be reset to 0 if the wakeup protocol is altered.