54 virtual void init(
const char * filename,
int baudrate = 9600,
int parity = 0,
int stopBits = 1) = 0;
75 virtual size_t send(
const uint8_t * buffer,
size_t len) = 0;
77 virtual size_t receive(uint8_t * buffer,
size_t len) = 0;
81 #define CharDevice_iid "cz.cvut.fit.Sicak.CharDeviceInterface/1.0" 83 Q_DECLARE_INTERFACE(
CharDevice, CharDevice_iid)
Character device QT plugin interface.
Definition: chardevice.h:42
virtual void setTimeout(int ms=5000)=0
Set communication timeout of the character device, in milliseconds, default 5s.
virtual void init(const char *filename, int baudrate=9600, int parity=0, int stopBits=1)=0
Initialize the plugin with device given by filename, parity: 0=none,1=odd,2=even.
virtual QString getPluginName()=0
Plugin name.
This header file contains class templates of basic data containers.
virtual void deInit()=0
Deinitialize the plugin.
virtual size_t send(const VectorType< uint8_t > &data)=0
Sends out the VectorType.
virtual size_t receive(VectorType< uint8_t > &data)=0
Fills the given VectorType.
virtual QString queryDevices()=0
Query available devices/filenames.
virtual QString getPluginInfo()=0
Plugin info.