^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) .. c:type:: dvb_frontend_parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5) *******************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) frontend parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) *******************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) The kind of parameters passed to the frontend device for tuning depend
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) on the kind of hardware you are using.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) The struct ``dvb_frontend_parameters`` uses a union with specific
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) per-system parameters. However, as newer delivery systems required more
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) data, the structure size weren't enough to fit, and just extending its
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) size would break the existing applications. So, those parameters were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) replaced by the usage of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) :ref:`FE_GET_PROPERTY/FE_SET_PROPERTY <FE_GET_PROPERTY>`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) ioctl's. The new API is flexible enough to add new parameters to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) existing delivery systems, and to add newer delivery systems.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) So, newer applications should use
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) :ref:`FE_GET_PROPERTY/FE_SET_PROPERTY <FE_GET_PROPERTY>`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) instead, in order to be able to support the newer System Delivery like
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) DVB-S2, DVB-T2, DVB-C2, ISDB, etc.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) All kinds of parameters are combined as a union in the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) ``dvb_frontend_parameters`` structure:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) struct dvb_frontend_parameters {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) uint32_t frequency; /* (absolute) frequency in Hz for QAM/OFDM */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) /* intermediate frequency in kHz for QPSK */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) fe_spectral_inversion_t inversion;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) union {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) struct dvb_qpsk_parameters qpsk;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) struct dvb_qam_parameters qam;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) struct dvb_ofdm_parameters ofdm;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) struct dvb_vsb_parameters vsb;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) } u;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) In the case of QPSK frontends the ``frequency`` field specifies the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) intermediate frequency, i.e. the offset which is effectively added to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) the local oscillator frequency (LOF) of the LNB. The intermediate
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) frequency has to be specified in units of kHz. For QAM and OFDM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) frontends the ``frequency`` specifies the absolute frequency and is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) given in Hz.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) .. c:type:: dvb_qpsk_parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) QPSK parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) ===============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) For satellite QPSK frontends you have to use the ``dvb_qpsk_parameters``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) structure:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) struct dvb_qpsk_parameters {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) uint32_t symbol_rate; /* symbol rate in Symbols per second */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) fe_code_rate_t fec_inner; /* forward error correction (see above) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) .. c:type:: dvb_qam_parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) QAM parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) ==============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) for cable QAM frontend you use the ``dvb_qam_parameters`` structure:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) struct dvb_qam_parameters {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) uint32_t symbol_rate; /* symbol rate in Symbols per second */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81) fe_code_rate_t fec_inner; /* forward error correction (see above) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 82) fe_modulation_t modulation; /* modulation type (see above) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 83) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 84)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 85)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 86) .. c:type:: dvb_vsb_parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 87)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 88) VSB parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 89) ==============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 90)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 91) ATSC frontends are supported by the ``dvb_vsb_parameters`` structure:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 92)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 93)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 94) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 95)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 96) struct dvb_vsb_parameters {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 97) fe_modulation_t modulation; /* modulation type (see above) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 98) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 99)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101) .. c:type:: dvb_ofdm_parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103) OFDM parameters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104) ===============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106) DVB-T frontends are supported by the ``dvb_ofdm_parameters`` structure:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111) struct dvb_ofdm_parameters {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112) fe_bandwidth_t bandwidth;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113) fe_code_rate_t code_rate_HP; /* high priority stream code rate */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114) fe_code_rate_t code_rate_LP; /* low priority stream code rate */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115) fe_modulation_t constellation; /* modulation type (see above) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116) fe_transmit_mode_t transmission_mode;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117) fe_guard_interval_t guard_interval;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118) fe_hierarchy_t hierarchy_information;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119) };