classPiiIoDriver
#include <PiiIoDriver.h>
An interface for input/output drivers.
Inherits QObject
Inherited by PiiDefaultIoDriver
Description
Public member functions
|
virtual PiiIoChannel *
|
(
Get a pointer to a PiiIoChannel object that stores the configuration of the given channel. |
|
virtual int
|
( )
= 0
Get the total number of I/O channels. |
|
virtual bool
|
( )
Close an initialized driver. |
|
virtual bool
|
( )
= 0
Initialize the driver. |
|
virtual bool
|
Select the I/O unit to use. |
Function details
-
Get a pointer to a PiiIoChannel object that stores the configuration of the given channel.
Parameters
- channel
-
the channel number, 0 to #getChannelCount() - 1.
-
virtual int channelCount
()[pure virtual]Get the total number of I/O channels.
-
virtual bool close
()[inline, virtual]Close an initialized driver.
After
close(), initialize() must be called again before the driver is functional. The default implementation returnstrue.Returns
trueon success,falseotherwise -
virtual bool initialize
()[pure virtual]Initialize the driver.
This function is must be called before the driver can be accessed
Returns
trueif the initialization was successful,falseotherwise. -
Select the I/O unit to use.
The driver may be able to handle many I/O boards. The active unit is selected by a generic unit id. Possibilities include, for example, network addresses and numeric board indices.
Returns
trueif the selection was successful,falseotherwise.
Add a note
Not a single note added yet. Be the first, add yours.