02.12.2012 Views

LINUX DVB API Version 3 - Linux TV.org

LINUX DVB API Version 3 - Linux TV.org

LINUX DVB API Version 3 - Linux TV.org

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

40 <strong>DVB</strong> VIDEO DEVICE<br />

4.2.10 VIDEO GET STATUS<br />

DESCRIPTION<br />

This ioctl call asks the Video Device to return the current status of the device.<br />

SYNOPSIS<br />

int ioctl(fd, int request = VIDEO GET STATUS, struct<br />

video status *status);<br />

PARAMETERS<br />

int fd File descriptor returned by a previous call to open().<br />

int request Equals VIDEO GET STATUS for this command.<br />

struct<br />

*status<br />

video status Returns the current status of the Video Device.<br />

ERRORS<br />

EBADF fd is not a valid open file descriptor<br />

EINTERNAL Internal error, possibly in the communication with the<br />

<strong>DVB</strong> subsystem.<br />

EFAULT status points to invalid address<br />

4.2.11 VIDEO GET EVENT<br />

DESCRIPTION<br />

This ioctl call returns an event of type video event if available. If an event is not<br />

available, the behavior depends on whether the device is in blocking or nonblocking<br />

mode. In the latter case, the call fails immediately with errno set to<br />

EWOULDBLOCK. In the former case, the call blocks until an event becomes<br />

available. The standard <strong>Linux</strong> poll() and/or select() system calls can be used<br />

with the device file descriptor to watch for new events. For select(), the file<br />

descriptor should be included in the exceptfds argument, and for poll(), POLL-<br />

PRI should be specified as the wake-up condition. Read-only permissions are<br />

sufficient for this ioctl call.<br />

SYNOPSIS<br />

int ioctl(fd, int request = VIDEO GET EVENT, struct<br />

video event *ev);<br />

PARAMETERS<br />

int fd File descriptor returned by a previous call to open().<br />

int request Equals VIDEO GET EVENT for this command.<br />

struct video event<br />

*ev<br />

Points to the location where the event, if any, is to be<br />

stored.<br />

ERRORS<br />

EBADF fd is not a valid open file descriptor<br />

EFAULT ev points to invalid address<br />

EWOULDBLOCK There is no event pending, and the device is in nonblocking<br />

mode.<br />

EOVERFLOW<br />

Overflow in event queue - one or more events were lost.<br />

40

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!