Class UwConnector allows to specify an interface between the UwDriver object and the device.
Class that implements serial port connection.
UwSerial()
Constructor of the UwSerial class.
virtual int configurePort(const std::string &path)
Method that loads the termios struct with the serial port parameters.
virtual ~UwSerial()
Destructor of the UwSerial class.
virtual const bool isConnected()
Returns true if serial port fd differs from -1, that means the connection is up.
virtual int writeToDevice(const std::string &msg)
Method that writes a command to the port interface.
int serialfd
Integer value that stores the serial port descriptor as generated by the function UwSerial:openConnec...
virtual bool closeConnection()
Method that closes an active connection to a device.
virtual bool openConnection(const std::string &path)
Method that opens a serial connection, the input string has to be with a format like <port_name>:pari...
virtual bool refreshConnection(const std::string &path)
Method that refreshes an existing connection creating a new file descriptor.
virtual int readFromDevice(void *wpos, int maxlen)
Function that receives data from the device's port to a backup buffer.
Generic class that provides a method to interface with the devices. Will be specialized for,...