xref: /linux/Documentation/userspace-api/media/rc/lirc-set-send-duty-cycle.rst (revision 3d0fe49454652117522f60bfbefb978ba0e5300b)
1.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
2.. c:namespace:: RC
3
4.. _lirc_set_send_duty_cycle:
5
6******************************
7ioctl LIRC_SET_SEND_DUTY_CYCLE
8******************************
9
10Name
11====
12
13LIRC_SET_SEND_DUTY_CYCLE - Set the duty cycle of the carrier signal for
14IR transmit.
15
16Synopsis
17========
18
19.. c:macro:: LIRC_SET_SEND_DUTY_CYCLE
20
21``int ioctl(int fd, LIRC_SET_SEND_DUTY_CYCLE, __u32 *duty_cycle)``
22
23Arguments
24=========
25
26``fd``
27    File descriptor returned by open().
28
29``duty_cycle``
30    Duty cicle, describing the pulse width in percent (from 1 to 99) of
31    the total cycle. Values 0 and 100 are reserved.
32
33Description
34===========
35
36Get/set the duty cycle of the carrier signal for IR transmit.
37
38Currently, no special meaning is defined for 0 or 100, but this
39could be used to switch off carrier generation in the future, so
40these values should be reserved.
41
42Return Value
43============
44
45On success 0 is returned, on error -1 and the ``errno`` variable is set
46appropriately. The generic error codes are described at the
47:ref:`Generic Error Codes <gen-errors>` chapter.
48