class::hal::FFifo

class hal::FFifo
  : public hal::Device

The FFIFO class is for access devices that are framed FIFOs from <sos/dev/ffifo.h>.

A framed FIFO is a FIFO where each read and write operation must match an integer multiple value of the frame size.

They are useful for storing audio data streams where fixed frame sizes arrive and need to be buffered before being processed.

Summary

FFifo()

int flush() const

FFifoInfo get_info() const

int get_info(

FFifoInfo & info
) const

int initialize(

const arg::SourceFilePath & path,
const FFifoAttributes & attributes,
const fs::OpenFlags & flags
)

FFifo & operator<<(

const FFifoAttributes & attributes
)

int set_attributes(

const FFifoAttributes & attributes
) const

Members

FFifo()

int flush() const

Flushes the FIFO.

Returns

Zero on success


FFifoInfo get_info() const

Returns the information for the FFIFO.


int get_info(

FFifoInfo & info
) const

Gets the FFIFO information.

Parameters

  • info A reference to the destination value

Returns

Less than zero on an error


int initialize(

const arg::SourceFilePath & path,
const FFifoAttributes & attributes,
const fs::OpenFlags & flags
)

Opens and initiliazes the device.

Parameters

  • path The path to the device (e.g., /dev/ffifo0)

  • attr The attributes to assign

  • o_flags Flags to use when opening e.g. FFifo::NONBLOCK

Returns

Zero on success or less than zero for an error


FFifo & operator<<(

const FFifoAttributes & attributes
)


int set_attributes(

const FFifoAttributes & attributes
) const

Sets the FIFO attributes.


X

Thanks for Coming!

Subscribe to news and updates