#include <KontrolDj.h>
Inheritance diagram for KDjKernel:

Public Member Functions | |
| KDjKernel () | |
| Default constructor. | |
| ~KDjKernel () | |
| The destructor closes any open device connections. | |
| void | openDevice (unsigned int deviceNumber=0) |
| Open a device connection. | |
| void | closeDevice (void) |
| Close an open device connection (if one exists). | |
| unsigned int | getDeviceCount (void) |
| Return the number of available devices. | |
| std::string | getDeviceName (unsigned int deviceNumber) |
| Return a string identifier for the specified device number. | |
| void | sendMessage (std::vector< unsigned char > *message) |
| Send a message to the device. | |
| void | getMessage (std::vector< unsigned char > *message) |
| Fill the user-provided vector with the data bytes received from the device. | |
Protected Member Functions | |
| void | error (KDjError::Type type) |
Protected Attributes | |
| void * | apiData_ |
| bool | connected_ |
| std::string | errorString_ |
This class implements some common functionality for the realtime extended i/o subclass KDjExtended.
This class provides a common, platform-independent API for realtime low level i/o communication with KDJ devices. It allows one to probe available KDJ devices, to connect to one such device, and to send and receive messages over the connection.
Definition at line 121 of file KontrolDj.h.
|
|
Default constructor. An exception will be thrown if a system initialization error occurs. |
|
|
The destructor closes any open device connections.
|
|
|
Open a device connection. An optional device number greater than 0 can be specified. Otherwise, the default or first device found is opened. An exception is thrown if an error occurs while attempting to make the device connection or an device connection was previously established. |
|
|
Close an open device connection (if one exists).
|
|
|
Return the number of available devices. An exception is thrown if an error occurs while attempting to get the number of avaliable devices. |
|
|
Return a string identifier for the specified device number. An exception is thrown if an error occurs while attempting to get the device name or an invalid device specifier is provided. |
|
|
Send a message to the device. This function does not return until a message has been send or when the write timeout timer expires. The size of the message must be 8 bytes. An exception is thrown if an error occurs during output or an device connection was not previously established. |
|
|
Fill the user-provided vector with the data bytes received from the device.
This function does not return until a message has been read or when the read timeout timer expires. If a message is available it is copied to the user-provided |
|
|
|
|
|
Definition at line 188 of file KontrolDj.h. |
|
|
Definition at line 189 of file KontrolDj.h. |
|
|
Definition at line 190 of file KontrolDj.h. |
![]() |
Copyright © 2005 by LSD Software. All Rights Reserved. Maintained by LSD, info at kontrol-dj.com |