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/userspace-api/media/fdl-appendix.rst.
7..
8.. TODO: replace it to GFDL-1.1-or-later WITH no-invariant-sections
9
10.. _V4L2-SDR-FMT-PCU18BE:
11
12******************************
13V4L2_SDR_FMT_PCU18BE ('PC18')
14******************************
15
16Planar complex unsigned 18-bit big endian IQ sample
17
18Description
19===========
20
21This format contains a sequence of complex number samples. Each complex
22number consist of two parts called In-phase and Quadrature (IQ). Both I
23and Q are represented as a 18 bit unsigned big endian number stored in
2432 bit space. The remaining unused bits within the 32 bit space will be
25padded with 0. I value starts first and Q value starts at an offset
26equalling half of the buffer size (i.e.) offset = buffersize/2. Out of
27the 18 bits, bit 17:2 (16 bit) is data and bit 1:0 (2 bit) can be any
28value.
29
30**Byte Order.**
31Each cell is one byte.
32
33.. flat-table::
34    :header-rows:  1
35    :stub-columns: 0
36
37    * -  Offset:
38      -  Byte B0
39      -  Byte B1
40      -  Byte B2
41      -  Byte B3
42    * -  start + 0:
43      -  I'\ :sub:`0[17:10]`
44      -  I'\ :sub:`0[9:2]`
45      -  I'\ :sub:`0[1:0]; B2[5:0]=pad`
46      -  pad
47    * -  start + 4:
48      -  I'\ :sub:`1[17:10]`
49      -  I'\ :sub:`1[9:2]`
50      -  I'\ :sub:`1[1:0]; B2[5:0]=pad`
51      -  pad
52    * -  ...
53    * - start + offset:
54      -  Q'\ :sub:`0[17:10]`
55      -  Q'\ :sub:`0[9:2]`
56      -  Q'\ :sub:`0[1:0]; B2[5:0]=pad`
57      -  pad
58    * - start + offset + 4:
59      -  Q'\ :sub:`1[17:10]`
60      -  Q'\ :sub:`1[9:2]`
61      -  Q'\ :sub:`1[1:0]; B2[5:0]=pad`
62      -  pad
63