^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) .. c:namespace:: DTV.fe
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) .. _FE_READ_STATUS:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) ********************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) ioctl FE_READ_STATUS
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) ********************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) Name
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) ====
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) FE_READ_STATUS - Returns status information about the front-end. This call only requires - read-only access to the device
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) Synopsis
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) ========
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) .. c:macro:: FE_READ_STATUS
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) ``int ioctl(int fd, FE_READ_STATUS, unsigned int *status)``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) Arguments
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) =========
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) ``fd``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) File descriptor returned by :c:func:`open()`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) ``status``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) pointer to a bitmask integer filled with the values defined by enum
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) :c:type:`fe_status`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) Description
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) ===========
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) All Digital TV frontend devices support the ``FE_READ_STATUS`` ioctl. It is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) used to check about the locking status of the frontend after being
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) tuned. The ioctl takes a pointer to an integer where the status will be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) written.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) .. note::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) The size of status is actually sizeof(enum fe_status), with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) varies according with the architecture. This needs to be fixed in the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) future.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) int fe_status
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) =============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) The fe_status parameter is used to indicate the current state and/or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) state changes of the frontend hardware. It is produced using the enum
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) :c:type:`fe_status` values on a bitmask
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) Return Value
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) ============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) On success 0 is returned.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) On error -1 is returned, and the ``errno`` variable is set
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) appropriately.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) Generic error codes are described at the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) :ref:`Generic Error Codes <gen-errors>` chapter.