ArmSys Support
ArmsysApi  0.12.18

#include <BUsbSerialLock.h>

Inheritance diagram for BUsbSerialLock:
BUsbSerial BComms

Public Member Functions

 BUsbSerialLock (BUInt rxFifoSize=512, BUInt txFifoSize=512)
 
int printfv (const char *fmt, va_list args)
 
BUInt writeAvailable ()
 How much write space is available. More...
 
BError write (const void *data, BUInt32 nBytes, BUInt32 &nWritten)
 Write a set of data. More...
 
BUInt readAvailable ()
 How manu bytes of read data is available. More...
 
BError read (void *data, BUInt32 nBytes, BUInt32 &nRead)
 Read the data. More...
 
- Public Member Functions inherited from BUsbSerial
 BUsbSerial (BUInt rxFifoSize=512, BUInt txFifoSize=512)
 
BError init (BUsbType type=BUsbTypeFullSpeed, BUsbConfig *usbConfig=0)
 Initialise with optional config params. More...
 
void setMaximumUsbChunk (BUInt usbChunkSize)
 Sets the maximum USB tranmitted chunk size. More...
 
void close ()
 Close down the USB interface. More...
 
void setBlocking (Bool on)
 Enable blocking mode. More...
 
void setSync (Bool on)
 Set synchronous mode for writes. More...
 
void start ()
 Start processing. More...
 
int printf (const char *fmt,...)
 
int printfv (const char *fmt, va_list args)
 
BError wait (BUInt32 eventSet, BTimeout timeoutUs=BTimeoutForever, BUInt32 num=1)
 
BError usbdInitHardware ()
 
BError usbdInitUsbDev (USBD_HandleTypeDef *pdev)
 
BUInt8 usbdInit (USBD_HandleTypeDef *pdev, BUInt8 cfgidx)
 
void usbdStarted ()
 The USB device is connected and running. More...
 
BUInt8 usbdDeInit (USBD_HandleTypeDef *pdev, BUInt8 cfgidx)
 
BUInt8 usbdSetup (USBD_HandleTypeDef *pdev, USBD_SetupReqTypedef *req)
 
void usbdTx ()
 Data to USB stack. More...
 
BUInt8 usbdTxComplete ()
 Data has been sent. More...
 
int usbdRx (USBD_HandleTypeDef *pdev, BUInt len)
 Data from USB stack. More...
 
void usbdInterrupt ()
 
- Public Member Functions inherited from BComms
 BComms ()
 
virtual ~BComms ()
 
virtual BError init ()
 
virtual const char * name ()
 The name of this interface. More...
 
virtual BUInt32 byteRate ()
 The byte rate of this interface. More...
 
virtual BError setPacketMode (Bool packetMode)
 Set packet mode. More...
 
virtual Bool packetMode ()
 Device is in packet mode. More...
 
virtual BError setTimeout (BTimeout timeoutUs)
 Set communication timeout. More...
 
virtual BError connect (const char *resource)
 Create a connection. More...
 
virtual Bool isConnected ()
 
virtual BError disconnect ()
 Disconnect. More...
 
virtual void flush (Flush flush)
 
virtual BError writeChunks (const BDataChunk *chunks, BUInt nChunks, BUInt32 &nTrans)
 
virtual void eventQueue (BEventQueue *eventQueue, BUInt32 event, BUInt32 eventSet, BUInt num=1)
 
virtual void eventEnable (Bool on)
 Enable events to be sent. More...
 

Private Attributes

BMutex olock
 

Additional Inherited Members

- Public Types inherited from BComms
enum  Flush { FlushRead, FlushWrite, FlushReadWrite }
 
- Protected Attributes inherited from BComms
Bool oconnected
 
Bool opacketMode
 
BTimeout otimeout
 
BEventQueueoeventQueue
 
Bool oeventEnabled
 
BUInt32 oevent
 
BUInt32 oeventSet
 
BUInt oeventNum
 

Constructor & Destructor Documentation

◆ BUsbSerialLock()

BUsbSerialLock::BUsbSerialLock ( BUInt  rxFifoSize = 512,
BUInt  txFifoSize = 512 
)

Member Function Documentation

◆ printfv()

int BUsbSerialLock::printfv ( const char *  fmt,
va_list  args 
)

◆ read()

BError BUsbSerialLock::read ( void *  data,
BUInt32  nBytes,
BUInt32 nRead 
)
virtual

Read the data.

Reimplemented from BUsbSerial.

◆ readAvailable()

BUInt BUsbSerialLock::readAvailable ( )
virtual

How manu bytes of read data is available.

Reimplemented from BUsbSerial.

◆ write()

BError BUsbSerialLock::write ( const void *  data,
BUInt32  nBytes,
BUInt32 nWritten 
)
virtual

Write a set of data.

Reimplemented from BUsbSerial.

◆ writeAvailable()

BUInt BUsbSerialLock::writeAvailable ( )
virtual

How much write space is available.

Reimplemented from BUsbSerial.

Member Data Documentation

◆ olock

BMutex BUsbSerialLock::olock
private

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