diff options
author | Matti Aaltonen <matti.j.aaltonen@nokia.com> | 2010-10-18 09:52:37 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-10-22 21:47:03 -0400 |
commit | eb8942e9b6150d3cc89640f1fb243ca9626a1d14 (patch) | |
tree | ebb2e53a5f7f640a7cf634e57f40bfea3934c78f /Documentation/DocBook | |
parent | a682d4cb768381039bdafdc3c04c53cf8d70dcf0 (diff) |
[media] Documentation: v4l: Add hw_seek spacing and two TUNER_RDS_CAP flags
Add a couple of words about the spacing field in the HW seek struct,
also a few words about the new RDS tuner capability flags
V4L2_TUNER_CAP_RDS_BLOCK-IO and V4L2_TUNER_CAP_RDS_CONTROLS.
Signed-off-by: Matti J. Aaltonen <matti.j.aaltonen@nokia.com>
Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'Documentation/DocBook')
-rw-r--r-- | Documentation/DocBook/v4l/dev-rds.xml | 68 | ||||
-rw-r--r-- | Documentation/DocBook/v4l/vidioc-s-hw-freq-seek.xml | 10 |
2 files changed, 59 insertions, 19 deletions
diff --git a/Documentation/DocBook/v4l/dev-rds.xml b/Documentation/DocBook/v4l/dev-rds.xml index 0869d701b1e5..360d2737e649 100644 --- a/Documentation/DocBook/v4l/dev-rds.xml +++ b/Documentation/DocBook/v4l/dev-rds.xml | |||
@@ -3,15 +3,16 @@ | |||
3 | <para>The Radio Data System transmits supplementary | 3 | <para>The Radio Data System transmits supplementary |
4 | information in binary format, for example the station name or travel | 4 | information in binary format, for example the station name or travel |
5 | information, on an inaudible audio subcarrier of a radio program. This | 5 | information, on an inaudible audio subcarrier of a radio program. This |
6 | interface is aimed at devices capable of receiving and decoding RDS | 6 | interface is aimed at devices capable of receiving and/or transmitting RDS |
7 | information.</para> | 7 | information.</para> |
8 | 8 | ||
9 | <para>For more information see the core RDS standard <xref linkend="en50067" /> | 9 | <para>For more information see the core RDS standard <xref linkend="en50067" /> |
10 | and the RBDS standard <xref linkend="nrsc4" />.</para> | 10 | and the RBDS standard <xref linkend="nrsc4" />.</para> |
11 | 11 | ||
12 | <para>Note that the RBDS standard as is used in the USA is almost identical | 12 | <para>Note that the RBDS standard as is used in the USA is almost identical |
13 | to the RDS standard. Any RDS decoder can also handle RBDS. Only some of the fields | 13 | to the RDS standard. Any RDS decoder/encoder can also handle RBDS. Only some of the |
14 | have slightly different meanings. See the RBDS standard for more information.</para> | 14 | fields have slightly different meanings. See the RBDS standard for more |
15 | information.</para> | ||
15 | 16 | ||
16 | <para>The RBDS standard also specifies support for MMBS (Modified Mobile Search). | 17 | <para>The RBDS standard also specifies support for MMBS (Modified Mobile Search). |
17 | This is a proprietary format which seems to be discontinued. The RDS interface does not | 18 | This is a proprietary format which seems to be discontinued. The RDS interface does not |
@@ -21,16 +22,25 @@ be needed, then please contact the linux-media mailing list: &v4l-ml;.</para> | |||
21 | <section> | 22 | <section> |
22 | <title>Querying Capabilities</title> | 23 | <title>Querying Capabilities</title> |
23 | 24 | ||
24 | <para>Devices supporting the RDS capturing API | 25 | <para>Devices supporting the RDS capturing API set |
25 | set the <constant>V4L2_CAP_RDS_CAPTURE</constant> flag in | 26 | the <constant>V4L2_CAP_RDS_CAPTURE</constant> flag in |
26 | the <structfield>capabilities</structfield> field of &v4l2-capability; | 27 | the <structfield>capabilities</structfield> field of &v4l2-capability; |
27 | returned by the &VIDIOC-QUERYCAP; ioctl. | 28 | returned by the &VIDIOC-QUERYCAP; ioctl. Any tuner that supports RDS |
28 | Any tuner that supports RDS will set the | 29 | will set the <constant>V4L2_TUNER_CAP_RDS</constant> flag in |
29 | <constant>V4L2_TUNER_CAP_RDS</constant> flag in the <structfield>capability</structfield> | 30 | the <structfield>capability</structfield> field of &v4l2-tuner;. If |
30 | field of &v4l2-tuner;. | 31 | the driver only passes RDS blocks without interpreting the data |
31 | Whether an RDS signal is present can be detected by looking at | 32 | the <constant>V4L2_TUNER_SUB_RDS_BLOCK_IO</constant> flag has to be |
32 | the <structfield>rxsubchans</structfield> field of &v4l2-tuner;: the | 33 | set, see <link linkend="reading-rds-data">Reading RDS data</link>. |
33 | <constant>V4L2_TUNER_SUB_RDS</constant> will be set if RDS data was detected.</para> | 34 | For future use the |
35 | flag <constant>V4L2_TUNER_SUB_RDS_CONTROLS</constant> has also been | ||
36 | defined. However, a driver for a radio tuner with this capability does | ||
37 | not yet exist, so if you are planning to write such a driver you | ||
38 | should discuss this on the linux-media mailing list: &v4l-ml;.</para> | ||
39 | |||
40 | <para> Whether an RDS signal is present can be detected by looking | ||
41 | at the <structfield>rxsubchans</structfield> field of &v4l2-tuner;: | ||
42 | the <constant>V4L2_TUNER_SUB_RDS</constant> will be set if RDS data | ||
43 | was detected.</para> | ||
34 | 44 | ||
35 | <para>Devices supporting the RDS output API | 45 | <para>Devices supporting the RDS output API |
36 | set the <constant>V4L2_CAP_RDS_OUTPUT</constant> flag in | 46 | set the <constant>V4L2_CAP_RDS_OUTPUT</constant> flag in |
@@ -40,16 +50,31 @@ Any modulator that supports RDS will set the | |||
40 | <constant>V4L2_TUNER_CAP_RDS</constant> flag in the <structfield>capability</structfield> | 50 | <constant>V4L2_TUNER_CAP_RDS</constant> flag in the <structfield>capability</structfield> |
41 | field of &v4l2-modulator;. | 51 | field of &v4l2-modulator;. |
42 | In order to enable the RDS transmission one must set the <constant>V4L2_TUNER_SUB_RDS</constant> | 52 | In order to enable the RDS transmission one must set the <constant>V4L2_TUNER_SUB_RDS</constant> |
43 | bit in the <structfield>txsubchans</structfield> field of &v4l2-modulator;.</para> | 53 | bit in the <structfield>txsubchans</structfield> field of &v4l2-modulator;. |
44 | 54 | If the driver only passes RDS blocks without interpreting the data | |
55 | the <constant>V4L2_TUNER_SUB_RDS_BLOCK_IO</constant> flag has to be set. If the | ||
56 | tuner is capable of handling RDS entities like program identification codes and radio | ||
57 | text, the flag <constant>V4L2_TUNER_SUB_RDS_CONTROLS</constant> should be set, | ||
58 | see <link linkend="writing-rds-data">Writing RDS data</link> and | ||
59 | <link linkend="fm-tx-controls">FM Transmitter Control Reference</link>.</para> | ||
45 | </section> | 60 | </section> |
46 | 61 | ||
47 | <section> | 62 | <section id="reading-rds-data"> |
48 | <title>Reading RDS data</title> | 63 | <title>Reading RDS data</title> |
49 | 64 | ||
50 | <para>RDS data can be read from the radio device | 65 | <para>RDS data can be read from the radio device |
51 | with the &func-read; function. The data is packed in groups of three bytes, | 66 | with the &func-read; function. The data is packed in groups of three bytes.</para> |
67 | </section> | ||
68 | |||
69 | <section id="writing-rds-data"> | ||
70 | <title>Writing RDS data</title> | ||
71 | |||
72 | <para>RDS data can be written to the radio device | ||
73 | with the &func-write; function. The data is packed in groups of three bytes, | ||
52 | as follows:</para> | 74 | as follows:</para> |
75 | </section> | ||
76 | |||
77 | <section> | ||
53 | <table frame="none" pgwide="1" id="v4l2-rds-data"> | 78 | <table frame="none" pgwide="1" id="v4l2-rds-data"> |
54 | <title>struct | 79 | <title>struct |
55 | <structname>v4l2_rds_data</structname></title> | 80 | <structname>v4l2_rds_data</structname></title> |
@@ -111,48 +136,57 @@ as follows:</para> | |||
111 | <tbody valign="top"> | 136 | <tbody valign="top"> |
112 | <row> | 137 | <row> |
113 | <entry>V4L2_RDS_BLOCK_MSK</entry> | 138 | <entry>V4L2_RDS_BLOCK_MSK</entry> |
139 | <entry> </entry> | ||
114 | <entry>7</entry> | 140 | <entry>7</entry> |
115 | <entry>Mask for bits 0-2 to get the block ID.</entry> | 141 | <entry>Mask for bits 0-2 to get the block ID.</entry> |
116 | </row> | 142 | </row> |
117 | <row> | 143 | <row> |
118 | <entry>V4L2_RDS_BLOCK_A</entry> | 144 | <entry>V4L2_RDS_BLOCK_A</entry> |
145 | <entry> </entry> | ||
119 | <entry>0</entry> | 146 | <entry>0</entry> |
120 | <entry>Block A.</entry> | 147 | <entry>Block A.</entry> |
121 | </row> | 148 | </row> |
122 | <row> | 149 | <row> |
123 | <entry>V4L2_RDS_BLOCK_B</entry> | 150 | <entry>V4L2_RDS_BLOCK_B</entry> |
151 | <entry> </entry> | ||
124 | <entry>1</entry> | 152 | <entry>1</entry> |
125 | <entry>Block B.</entry> | 153 | <entry>Block B.</entry> |
126 | </row> | 154 | </row> |
127 | <row> | 155 | <row> |
128 | <entry>V4L2_RDS_BLOCK_C</entry> | 156 | <entry>V4L2_RDS_BLOCK_C</entry> |
157 | <entry> </entry> | ||
129 | <entry>2</entry> | 158 | <entry>2</entry> |
130 | <entry>Block C.</entry> | 159 | <entry>Block C.</entry> |
131 | </row> | 160 | </row> |
132 | <row> | 161 | <row> |
133 | <entry>V4L2_RDS_BLOCK_D</entry> | 162 | <entry>V4L2_RDS_BLOCK_D</entry> |
163 | <entry> </entry> | ||
134 | <entry>3</entry> | 164 | <entry>3</entry> |
135 | <entry>Block D.</entry> | 165 | <entry>Block D.</entry> |
136 | </row> | 166 | </row> |
137 | <row> | 167 | <row> |
138 | <entry>V4L2_RDS_BLOCK_C_ALT</entry> | 168 | <entry>V4L2_RDS_BLOCK_C_ALT</entry> |
169 | <entry> </entry> | ||
139 | <entry>4</entry> | 170 | <entry>4</entry> |
140 | <entry>Block C'.</entry> | 171 | <entry>Block C'.</entry> |
141 | </row> | 172 | </row> |
142 | <row> | 173 | <row> |
143 | <entry>V4L2_RDS_BLOCK_INVALID</entry> | 174 | <entry>V4L2_RDS_BLOCK_INVALID</entry> |
175 | <entry>read-only</entry> | ||
144 | <entry>7</entry> | 176 | <entry>7</entry> |
145 | <entry>An invalid block.</entry> | 177 | <entry>An invalid block.</entry> |
146 | </row> | 178 | </row> |
147 | <row> | 179 | <row> |
148 | <entry>V4L2_RDS_BLOCK_CORRECTED</entry> | 180 | <entry>V4L2_RDS_BLOCK_CORRECTED</entry> |
181 | <entry>read-only</entry> | ||
149 | <entry>0x40</entry> | 182 | <entry>0x40</entry> |
150 | <entry>A bit error was detected but corrected.</entry> | 183 | <entry>A bit error was detected but corrected.</entry> |
151 | </row> | 184 | </row> |
152 | <row> | 185 | <row> |
153 | <entry>V4L2_RDS_BLOCK_ERROR</entry> | 186 | <entry>V4L2_RDS_BLOCK_ERROR</entry> |
187 | <entry>read-only</entry> | ||
154 | <entry>0x80</entry> | 188 | <entry>0x80</entry> |
155 | <entry>An incorrectable error occurred.</entry> | 189 | <entry>An uncorrectable error occurred.</entry> |
156 | </row> | 190 | </row> |
157 | </tbody> | 191 | </tbody> |
158 | </tgroup> | 192 | </tgroup> |
diff --git a/Documentation/DocBook/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/v4l/vidioc-s-hw-freq-seek.xml index 14b3ec7ed75b..c30dcc4232c0 100644 --- a/Documentation/DocBook/v4l/vidioc-s-hw-freq-seek.xml +++ b/Documentation/DocBook/v4l/vidioc-s-hw-freq-seek.xml | |||
@@ -51,7 +51,8 @@ | |||
51 | 51 | ||
52 | <para>Start a hardware frequency seek from the current frequency. | 52 | <para>Start a hardware frequency seek from the current frequency. |
53 | To do this applications initialize the <structfield>tuner</structfield>, | 53 | To do this applications initialize the <structfield>tuner</structfield>, |
54 | <structfield>type</structfield>, <structfield>seek_upward</structfield> and | 54 | <structfield>type</structfield>, <structfield>seek_upward</structfield>, |
55 | <structfield>spacing</structfield> and | ||
55 | <structfield>wrap_around</structfield> fields, and zero out the | 56 | <structfield>wrap_around</structfield> fields, and zero out the |
56 | <structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and | 57 | <structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and |
57 | call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer | 58 | call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer |
@@ -89,7 +90,12 @@ field and the &v4l2-tuner; <structfield>index</structfield> field.</entry> | |||
89 | </row> | 90 | </row> |
90 | <row> | 91 | <row> |
91 | <entry>__u32</entry> | 92 | <entry>__u32</entry> |
92 | <entry><structfield>reserved</structfield>[8]</entry> | 93 | <entry><structfield>spacing</structfield></entry> |
94 | <entry>If non-zero, defines the hardware seek resolution in Hz. The driver selects the nearest value that is supported by the device. If spacing is zero a reasonable default value is used.</entry> | ||
95 | </row> | ||
96 | <row> | ||
97 | <entry>__u32</entry> | ||
98 | <entry><structfield>reserved</structfield>[7]</entry> | ||
93 | <entry>Reserved for future extensions. Drivers and | 99 | <entry>Reserved for future extensions. Drivers and |
94 | applications must set the array to zero.</entry> | 100 | applications must set the array to zero.</entry> |
95 | </row> | 101 | </row> |