libvpb  4.2.61
V4PCIDspFifo Class Reference
Inheritance diagram for V4PCIDspFifo:
Inheritance graph
Collaboration diagram for V4PCIDspFifo:
Collaboration graph

Public Member Functions

 V4PCIDspFifo (Hip *hip, unsigned short board, unsigned short fifo_addr)
 Open a link to a DSP FIFO. Assumes the DSP has been booted.
 
Status Write (uint16_t *buf, size_t len)
 Write a block of words from the PC to a DSP FIFO. More...
 
Status Read (uint16_t *buf, size_t len)
 Read a block of words from a DSP FIFO to the PC. More...
 
size_t HowFull ()
 Return the number of words used in the DSP FIFO.
 
size_t HowEmpty ()
 Returns the number of words free in the DSP FIFO.
 
void Flush ()
 

Additional Inherited Members

- Public Types inherited from Fifo
enum  Status { OK , FULL , EMPTY }
 

Member Function Documentation

◆ Read()

Fifo::Status V4PCIDspFifo::Read ( uint16_t *  buf,
size_t  len 
)
virtual

Read a block of words from a DSP FIFO to the PC.

Returns
Fifo::OK if successful, or Fifo::EMPTY if size words could not be read from it atomically.

Implements Fifo.

◆ Write()

Fifo::Status V4PCIDspFifo::Write ( uint16_t *  buf,
size_t  len 
)
virtual

Write a block of words from the PC to a DSP FIFO.

Returns
Fifo::OK if successful, or Fifo::FULL if size words could not be written to it atomically.

Implements Fifo.