RTXI  2.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Fifo Class Reference

#include <fifo.h>

Public Member Functions

 Fifo (size_t)
 ~Fifo (void)
size_t read (void *, size_t, bool=true)
size_t write (const void *, size_t)

Private Attributes

char * data
volatile int rptr
volatile int wptr
size_t size
pthread_mutex_t mutex
pthread_cond_t data_available

Detailed Description

Definition at line 26 of file fifo.h.

Constructor & Destructor Documentation

Fifo::Fifo(size_t s)

Definition at line 26 of file fifo.cpp.

Fifo::~Fifo(void )

Definition at line 34 of file fifo.cpp.

Member Function Documentation

size_t Fifo::read(void * buffer,
size_t n,
bool blocking = true 

Definition at line 42 of file fifo.cpp.

size_t Fifo::write(const void * buffer,
size_t n 

Definition at line 81 of file fifo.cpp.

Member Data Documentation

char* Fifo::data

Definition at line 39 of file fifo.h.

pthread_cond_t Fifo::data_available

Definition at line 44 of file fifo.h.

pthread_mutex_t Fifo::mutex

Definition at line 43 of file fifo.h.

volatile int Fifo::rptr

Definition at line 40 of file fifo.h.

size_t Fifo::size

Definition at line 42 of file fifo.h.

volatile int Fifo::wptr

Definition at line 41 of file fifo.h.

The documentation for this class was generated from the following files: