#include <phidget.h>

Public Member Functions | |
| int | close () |
| Close the connection to the phidget. | |
| std::string | getDeviceLabel () |
| Get the device label string. | |
| std::string | getDeviceName () |
| Get the device name string. | |
| int | getDeviceSerialNumber () |
| Get the Phidget's serial number. | |
| std::string | getDeviceType () |
| Get the device type string. | |
| int | getDeviceVersion () |
| Get the Phidget's version. | |
| std::string | getLibraryVersion () |
| Get the library version string. | |
| int | open (int serial_number) |
| Open a connection to a Phidget. | |
| Phidget () | |
| int | waitForAttachment (int timeout) |
| Block until the unit is attached or timeout occurs. | |
| ~Phidget () | |
Static Public Member Functions | |
| static std::string | getErrorDescription (int errorCode) |
| Lookup the string for a CPhidget Error Code. | |
Protected Member Functions | |
| virtual void | attachHandler () |
| virtual void | detachHandler () |
| virtual void | errorHandler (int error) |
| void | init (CPhidgetHandle handle) |
| virtual void | registerHandlers () |
Protected Attributes | |
| CPhidgetHandle | handle_ |
Static Private Member Functions | |
| static int | AttachHandler (CPhidgetHandle handle, void *userptr) |
| static int | DetachHandler (CPhidgetHandle handle, void *userptr) |
| static int | ErrorHandler (CPhidgetHandle handle, void *userptr, int ErrorCode, const char *unknown) |
Definition at line 5 of file phidget.cpp.
Definition at line 10 of file phidget.cpp.
| void phidgets::Phidget::attachHandler | ( | ) | [protected, virtual] |
Definition at line 96 of file phidget.cpp.
| int phidgets::Phidget::AttachHandler | ( | CPhidgetHandle | handle, |
| void * | userptr | ||
| ) | [static, private] |
Definition at line 111 of file phidget.cpp.
| int phidgets::Phidget::close | ( | ) |
Close the connection to the phidget.
Definition at line 33 of file phidget.cpp.
| void phidgets::Phidget::detachHandler | ( | ) | [protected, virtual] |
Definition at line 101 of file phidget.cpp.
| int phidgets::Phidget::DetachHandler | ( | CPhidgetHandle | handle, |
| void * | userptr | ||
| ) | [static, private] |
Definition at line 117 of file phidget.cpp.
| void phidgets::Phidget::errorHandler | ( | int | error | ) | [protected, virtual] |
Definition at line 106 of file phidget.cpp.
| int phidgets::Phidget::ErrorHandler | ( | CPhidgetHandle | handle, |
| void * | userptr, | ||
| int | ErrorCode, | ||
| const char * | unknown | ||
| ) | [static, private] |
Definition at line 123 of file phidget.cpp.
| std::string phidgets::Phidget::getDeviceLabel | ( | ) |
Get the device label string.
Definition at line 59 of file phidget.cpp.
| std::string phidgets::Phidget::getDeviceName | ( | ) |
Get the device name string.
Definition at line 51 of file phidget.cpp.
Get the Phidget's serial number.
Definition at line 74 of file phidget.cpp.
| std::string phidgets::Phidget::getDeviceType | ( | ) |
Get the device type string.
Definition at line 43 of file phidget.cpp.
Get the Phidget's version.
Definition at line 81 of file phidget.cpp.
| std::string phidgets::Phidget::getErrorDescription | ( | int | errorCode | ) | [static] |
Lookup the string for a CPhidget Error Code.
| errorCode | The error code returned from the CPhidget API |
Definition at line 88 of file phidget.cpp.
| std::string phidgets::Phidget::getLibraryVersion | ( | ) |
Get the library version string.
Definition at line 67 of file phidget.cpp.
| void phidgets::Phidget::init | ( | CPhidgetHandle | handle | ) | [protected] |
Definition at line 23 of file phidget.cpp.
| int phidgets::Phidget::open | ( | int | serial_number | ) |
Open a connection to a Phidget.
| serial_number | The serial number of the phidget to which to attach (-1 will connect to any) |
Definition at line 28 of file phidget.cpp.
| void phidgets::Phidget::registerHandlers | ( | ) | [protected, virtual] |
Definition at line 16 of file phidget.cpp.
| int phidgets::Phidget::waitForAttachment | ( | int | timeout | ) |
Block until the unit is attached or timeout occurs.
| timeout | Milliseconds to wait before timing out |
Definition at line 38 of file phidget.cpp.
CPhidgetHandle phidgets::Phidget::handle_ [protected] |