1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later 2.. c:namespace:: DTV.audio 3 4.. _audio_fwrite: 5 6========================= 7Digital TV audio write() 8========================= 9 10Name 11---- 12 13Digital TV audio write() 14 15.. attention:: This ioctl is deprecated 16 17Synopsis 18-------- 19 20.. c:function:: size_t write(int fd, const void *buf, size_t count) 21 22Arguments 23--------- 24 25.. flat-table:: 26 :header-rows: 0 27 :stub-columns: 0 28 29 - .. row 1 30 31 - int fd 32 33 - File descriptor returned by a previous call to open(). 34 35 - .. row 2 36 37 - void \*buf 38 39 - Pointer to the buffer containing the PES data. 40 41 - .. row 3 42 43 - size_t count 44 45 - Size of buf. 46 47Description 48----------- 49 50This system call can only be used if AUDIO_SOURCE_MEMORY is selected 51in the ioctl call AUDIO_SELECT_SOURCE. The data provided shall be in 52PES format. If O_NONBLOCK is not specified the function will block 53until buffer space is available. The amount of data to be transferred is 54implied by count. 55 56Return Value 57------------ 58 59.. flat-table:: 60 :header-rows: 0 61 :stub-columns: 0 62 63 - .. row 1 64 65 - ``EPERM`` 66 67 - Mode AUDIO_SOURCE_MEMORY not selected. 68 69 - .. row 2 70 71 - ``ENOMEM`` 72 73 - Attempted to write more data than the internal buffer can hold. 74 75 - .. row 3 76 77 - ``EBADF`` 78 79 - fd is not a valid open file descriptor. 80