blob: 84e4da3fd4c97f417e10062398d4aedae97267c9 [file] [log] [blame]
Markus Heiser5377d912016-06-30 15:18:56 +02001.. -*- coding: utf-8; mode: rst -*-
2
3.. _FE_SET_TONE:
4
5*****************
6ioctl FE_SET_TONE
7*****************
8
Mauro Carvalho Chehab15e7d612016-07-05 15:14:35 -03009Name
Mauro Carvalho Chehab586027c2016-07-05 07:58:48 -030010====
Markus Heiser5377d912016-06-30 15:18:56 +020011
Mauro Carvalho Chehab586027c2016-07-05 07:58:48 -030012FE_SET_TONE - Sets/resets the generation of the continuous 22kHz tone.
Markus Heiser5377d912016-06-30 15:18:56 +020013
Mauro Carvalho Chehab15e7d612016-07-05 15:14:35 -030014
15Synopsis
Markus Heiser5377d912016-06-30 15:18:56 +020016========
17
Mauro Carvalho Chehabaffd2502017-06-21 06:51:51 -030018.. c:function:: int ioctl( int fd, FE_SET_TONE, enum fe_sec_tone_mode tone )
Mauro Carvalho Chehabcf8076c2016-08-19 16:56:15 -030019 :name: FE_SET_TONE
Markus Heiser5377d912016-06-30 15:18:56 +020020
Mauro Carvalho Chehab586027c2016-07-05 07:58:48 -030021
Mauro Carvalho Chehab15e7d612016-07-05 15:14:35 -030022Arguments
Markus Heiser5377d912016-06-30 15:18:56 +020023=========
24
25``fd``
26 File descriptor returned by :ref:`open() <frontend_f_open>`.
27
Markus Heiser5377d912016-06-30 15:18:56 +020028``tone``
Mauro Carvalho Chehabaffd2502017-06-21 06:51:51 -030029 an integer enumered value described at :c:type:`fe_sec_tone_mode`
Markus Heiser5377d912016-06-30 15:18:56 +020030
31
Mauro Carvalho Chehab15e7d612016-07-05 15:14:35 -030032Description
Markus Heiser5377d912016-06-30 15:18:56 +020033===========
34
35This ioctl is used to set the generation of the continuous 22kHz tone.
36This call requires read/write permissions.
37
38Usually, satellite antenna subsystems require that the digital TV device
39to send a 22kHz tone in order to select between high/low band on some
40dual-band LNBf. It is also used to send signals to DiSEqC equipment, but
41this is done using the DiSEqC ioctls.
42
Mauro Carvalho Chehab706f8a92016-07-10 11:57:43 -030043.. attention:: If more than one device is connected to the same antenna,
44 setting a tone may interfere on other devices, as they may lose the
45 capability of selecting the band. So, it is recommended that applications
46 would change to SEC_TONE_OFF when the device is not used.
Markus Heiser5377d912016-06-30 15:18:56 +020047
Mauro Carvalho Chehab836cf1d2016-08-30 10:21:03 -030048.. c:type:: fe_sec_tone_mode
Markus Heiser5377d912016-06-30 15:18:56 +020049
50.. flat-table:: enum fe_sec_tone_mode
51 :header-rows: 1
52 :stub-columns: 0
53
54
55 - .. row 1
56
57 - ID
58
59 - Description
60
61 - .. row 2
62
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030063 - .. _SEC-TONE-ON:
Markus Heiser5377d912016-06-30 15:18:56 +020064
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030065 ``SEC_TONE_ON``
Markus Heiser5377d912016-06-30 15:18:56 +020066
67 - Sends a 22kHz tone burst to the antenna
68
69 - .. row 3
70
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030071 - .. _SEC-TONE-OFF:
Markus Heiser5377d912016-06-30 15:18:56 +020072
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030073 ``SEC_TONE_OFF``
Markus Heiser5377d912016-06-30 15:18:56 +020074
75 - Don't send a 22kHz tone to the antenna (except if the
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030076 FE_DISEQC_* ioctls are called)
Mauro Carvalho Chehabfc833982016-07-05 11:36:55 -030077
Mauro Carvalho Chehab15e7d612016-07-05 15:14:35 -030078
79Return Value
Mauro Carvalho Chehabfc833982016-07-05 11:36:55 -030080============
81
82On success 0 is returned, on error -1 and the ``errno`` variable is set
83appropriately. The generic error codes are described at the
84:ref:`Generic Error Codes <gen-errors>` chapter.