dev-radio.rst 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
  2. .. c:namespace:: V4L
  3. .. _radio:
  4. ***************
  5. Radio Interface
  6. ***************
  7. This interface is intended for AM and FM (analog) radio receivers and
  8. transmitters.
  9. Conventionally V4L2 radio devices are accessed through character device
  10. special files named ``/dev/radio`` and ``/dev/radio0`` to
  11. ``/dev/radio63`` with major number 81 and minor numbers 64 to 127.
  12. Querying Capabilities
  13. =====================
  14. Devices supporting the radio interface set the ``V4L2_CAP_RADIO`` and
  15. ``V4L2_CAP_TUNER`` or ``V4L2_CAP_MODULATOR`` flag in the
  16. ``capabilities`` field of struct
  17. :c:type:`v4l2_capability` returned by the
  18. :ref:`VIDIOC_QUERYCAP` ioctl. Other combinations of
  19. capability flags are reserved for future extensions.
  20. Supplemental Functions
  21. ======================
  22. Radio devices can support :ref:`controls <control>`, and must support
  23. the :ref:`tuner or modulator <tuner>` ioctls.
  24. They do not support the video input or output, audio input or output,
  25. video standard, cropping and scaling, compression and streaming
  26. parameter, or overlay ioctls. All other ioctls and I/O methods are
  27. reserved for future extensions.
  28. Programming
  29. ===========
  30. Radio devices may have a couple audio controls (as discussed in
  31. :ref:`control`) such as a volume control, possibly custom controls.
  32. Further all radio devices have one tuner or modulator (these are
  33. discussed in :ref:`tuner`) with index number zero to select the radio
  34. frequency and to determine if a monaural or FM stereo program is
  35. received/emitted. Drivers switch automatically between AM and FM
  36. depending on the selected frequency. The
  37. :ref:`VIDIOC_G_TUNER <VIDIOC_G_TUNER>` or
  38. :ref:`VIDIOC_G_MODULATOR <VIDIOC_G_MODULATOR>` ioctl reports the
  39. supported frequency range.