Functions | Variables
cphidget.c File Reference
#include "stdafx.h"
#include "cphidget.h"
#include "cusb.h"
#include "csocket.h"
#include "cthread.h"
#include "cphidgetlist.h"
#include "utils.h"
Include dependency graph for cphidget.c:

Go to the source code of this file.

Functions

int attachActiveDevice (CPhidgetHandle activeDevice, CPhidgetHandle attachedDevice)
int CCONV CPhidget_areEqual (void *arg1, void *arg2)
int CCONV CPhidget_areExtraEqual (void *arg1, void *arg2)
int CCONV CPhidget_calibrate (CPhidgetHandle phid, unsigned char Offset, unsigned char *data)
int CCONV CPhidget_calibrate_gain2offset (CPhidgetHandle phid, int Index, unsigned short offset, unsigned long gain1, unsigned long gain2)
int CCONV CPhidget_calibrate_gainoffset (CPhidgetHandle phid, int Index, unsigned short offset, unsigned long gain)
int CPhidget_clearStatusFlag (int *status, int flag, CThread_mutex_t *lock)
int CCONV CPhidget_close (CPhidgetHandle phid)
int CCONV CPhidget_create (CPhidgetHandle *phid)
int CCONV CPhidget_delete (CPhidgetHandle phid)
void CCONV CPhidget_free (void *arg)
int CCONV CPhidget_getDeviceClass (CPhidgetHandle phid, CPhidget_DeviceClass *deviceClass)
int CCONV CPhidget_getDeviceID (CPhidgetHandle phid, CPhidget_DeviceID *deviceID)
int CCONV CPhidget_getDeviceLabel (CPhidgetHandle phid, const char **buffer)
int CCONV CPhidget_getDeviceName (CPhidgetHandle phid, const char **buffer)
int CCONV CPhidget_getDeviceStatus (CPhidgetHandle phid, int *status)
int CCONV CPhidget_getDeviceType (CPhidgetHandle phid, const char **buffer)
int CCONV CPhidget_getDeviceVersion (CPhidgetHandle phid, int *devVer)
int CCONV CPhidget_getErrorDescription (int ErrorCode, const char **buf)
int CCONV CPhidget_getLibraryVersion (const char **buffer)
int CCONV CPhidget_getSerialNumber (CPhidgetHandle phid, int *serialNumber)
int CCONV CPhidget_getServerAddress (CPhidgetHandle phid, const char **ipAddr, int *port)
int CCONV CPhidget_getServerID (CPhidgetHandle phid, const char **buffer)
int CCONV CPhidget_getServerStatus (CPhidgetHandle phid, int *status)
CPhidget_DeviceUID CPhidget_getUID (CPhidget_DeviceID id, int version)
int CCONV CPhidget_getUSBProductString (CPhidgetHandle phid, const char **buffer)
int CCONV CPhidget_open (CPhidgetHandle phid, int serialNumber)
int CCONV CPhidget_openLabel (CPhidgetHandle phid, const char *label)
int CPhidget_read (CPhidgetHandle phid)
int CCONV CPhidget_set_OnAttach_Handler (CPhidgetHandle phid, int(CCONV *fptr)(CPhidgetHandle, void *), void *userPtr)
int CCONV CPhidget_set_OnDetach_Handler (CPhidgetHandle phid, int(CCONV *fptr)(CPhidgetHandle, void *), void *userPtr)
int CCONV CPhidget_set_OnError_Handler (CPhidgetHandle phid, int(CCONV *fptr)(CPhidgetHandle, void *, int, const char *), void *userPtr)
int CCONV CPhidget_set_OnServerConnect_Handler (CPhidgetHandle phid, int(CCONV *fptr)(CPhidgetHandle phid, void *userPtr), void *userPtr)
int CCONV CPhidget_set_OnServerDisconnect_Handler (CPhidgetHandle phid, int(CCONV *fptr)(CPhidgetHandle phid, void *userPtr), void *userPtr)
int CCONV CPhidget_setDeviceLabel (CPhidgetHandle phid, const char *buffer)
int CPhidget_setStatusFlag (int *status, int flag, CThread_mutex_t *lock)
int CPhidget_statusFlagIsSet (int status, int flag)
const char * CPhidget_strerror (int error)
int CCONV CPhidget_waitForAttachment (CPhidgetHandle phid, int milliseconds)
int CPhidget_write (CPhidgetHandle phid)
void CPhidgetErrorEvent_free (void *arg)
void CPhidgetFHandle_free (void *arg)
static int CPhidgetGPP_dataInput (CPhidgetHandle phid, unsigned char *buffer, int length)
int CCONV CPhidgetGPP_eraseConfig (CPhidgetHandle phid)
int CCONV CPhidgetGPP_eraseFirmware (CPhidgetHandle phid)
int CCONV CPhidgetGPP_reboot_firmwareUpgrade (CPhidgetHandle phid)
int CCONV CPhidgetGPP_reboot_ISP (CPhidgetHandle phid)
static int CPhidgetGPP_setConfigTable (CPhidgetHandle phid, unsigned char *data, int length, int index, int packetType)
int CCONV CPhidgetGPP_setDeviceSpecificConfigTable (CPhidgetHandle phid, unsigned char *data, int length, int index)
int CCONV CPhidgetGPP_setDeviceWideConfigTable (CPhidgetHandle phid, unsigned char *data, int length, int index)
int CCONV CPhidgetGPP_setLabel (CPhidgetHandle phid, const char *label)
int CCONV CPhidgetGPP_upgradeFirmware (CPhidgetHandle phid, unsigned char *data, int length)
int CCONV CPhidgetGPP_writeFlash (CPhidgetHandle phid)
int CCONV CPhidgetGPP_zeroConfig (CPhidgetHandle phid)
int CCONV CPhidgetHandle_areEqual (void *arg1, void *arg2)
int decodeLabelString (char *labelBuf, char *out, int serialNumber)
int deviceSupportsGeneralUSBProtocol (CPhidgetHandle phid)
int encodeLabelString (const char *buffer, char *out, int *outLen)
int findActiveDevice (CPhidgetHandle attachedDevice)
int findActiveDevices ()
int GPP_getResponse (CPhidgetHandle phid, int packetType, int timeout)
int labelHasWrapError (int serialNumber, char *labelBuf)
int CCONV phidget_type_to_id (const char *name)
double round_double (double x, int decimals)
void setTimeNow (TIME *now)
void throw_error_event (CPhidgetHandle phid, const char *error, int errcode)
double timeSince (TIME *start)
double timestampdiff (CPhidget_Timestamp time1, CPhidget_Timestamp time2)
char translate_bool_to_ascii (char value)
int UTF16toUTF8 (char *in, int inLen, char *out)
 void (CCONV *fptrJavaDetachCurrentThread)(void)

Variables

CPhidgetListHandle ActiveDevices = 0
CThread_mutex_t activeDevicesLock
CPhidgetListHandle AttachedDevices = 0
CThread_mutex_t attachedDevicesLock
int phidgetLocksInitialized = PFALSE
int print_debug_messages = FALSE

Function Documentation

int CCONV CPhidget_calibrate ( CPhidgetHandle  phid,
unsigned char  Offset,
unsigned char *  data 
)

Definition at line 970 of file cphidget.c.

int CCONV CPhidget_calibrate_gain2offset ( CPhidgetHandle  phid,
int  Index,
unsigned short  offset,
unsigned long  gain1,
unsigned long  gain2 
)

Definition at line 995 of file cphidget.c.

int CCONV CPhidget_getUSBProductString ( CPhidgetHandle  phid,
const char **  buffer 
)

Definition at line 693 of file cphidget.c.

int CCONV CPhidget_set_OnAttach_Handler ( CPhidgetHandle  phid,
int(CCONV *fptr)(CPhidgetHandle, void *)  ,
void userPtr 
)

Definition at line 542 of file cphidget.c.

int CCONV CPhidget_set_OnDetach_Handler ( CPhidgetHandle  phid,
int(CCONV *fptr)(CPhidgetHandle, void *)  ,
void userPtr 
)

Definition at line 532 of file cphidget.c.

int CCONV CPhidget_set_OnError_Handler ( CPhidgetHandle  phid,
int(CCONV *fptr)(CPhidgetHandle, void *, int, const char *)  ,
void userPtr 
)

Definition at line 552 of file cphidget.c.

static int CPhidgetGPP_dataInput ( CPhidgetHandle  phid,
unsigned char *  buffer,
int  length 
) [static]

Definition at line 1714 of file cphidget.c.

static int CPhidgetGPP_setConfigTable ( CPhidgetHandle  phid,
unsigned char *  data,
int  length,
int  index,
int  packetType 
) [static]

Definition at line 1987 of file cphidget.c.

Definition at line 1939 of file cphidget.c.

int GPP_getResponse ( CPhidgetHandle  phid,
int  packetType,
int  timeout 
)

Definition at line 1725 of file cphidget.c.

double round_double ( double  x,
int  decimals 
)

Definition at line 1395 of file cphidget.c.

void ( CCONV fptrJavaDetachCurrentThread)

Variable Documentation

int print_debug_messages = FALSE

Definition at line 11 of file cphidget.c.



pedal_monitor
Author(s): Pedro Mendes
autogenerated on Fri Jun 6 2014 18:37:21