|
SpaceControl DLL
Version 2.8.3
API documentation for the SpaceControl 3D input devices
|
The SpaceControl DLL's implementing file. More...
#include "spc_ctrlr.h"#include "trncv_com.h"#include "trncv_prot.h"#include "settings.h"#include "util.h"
Functions | |
| char * | scStatusToStr (ScStatus ss) |
| Returns a DLL function's status code as a string. More... | |
| ScStatus | scIsProcessRunning (char *processName, bool *isRunningP) |
| Checks if the process with the given name is running or not. More... | |
| ScStatus | scSetCurrentUserRegValue (char *keyP, char *nameP, char *valueP) |
| Sets a new string value into the Windows registry under the base key HKEY_CURRENT_USER. More... | |
| ScStatus | scQueryCurrentUserRegValue (char *keyP, char *nameP, int len, char *valueP) |
| Queries a string value from the Windows registry under the base key HKEY_CURRENT_USER. More... | |
| ScStatus | scDelCurrentUserRegValue (char *keyP, char *nameP) |
| Deletes a string value in the Windows registry under the base key HKEY_CURRENT_USER. More... | |
| ScStatus | scConnect2 (bool isAlwaysReceivingData, char *applName) |
| Establishes the connection to the SpaceControl daemon. More... | |
| ScStatus | scConnect () |
| int | stopWritingThread (DeviceProxy *proxyP) |
| int | stopReadingThread (DeviceProxy *proxyP) |
| int | deleteDeviceProxy (DeviceProxy *proxyP) |
| int | deleteProxies () |
| ScStatus | scDisconnect () |
| Closes the connection to the SpaceControl daemon. More... | |
| ScStatus | scStop () |
| Sends the SpaceControl Daemon a stop message, the process finishes itself after sending an OK message. More... | |
| ScStatus | scGetDmnVrsn (char *versionP, char *pathP) |
| Retrieves the SpaceControl daemon's software version and its binary name and path. More... | |
| ScStatus | scGetDevNum (int *devNumP, int *usedDevNumP, int *maxDevIdxP) |
| Retrieves the number devNum of SpaceControl devices actually connected to the computer, the number usedDevNum of SpaceControl devices actually used by the driver and the maximal device index maxDevIdx a device may be addressed with at the moment. More... | |
| ScStatus | scGetFgAppl (char *fgApplNameP, char *fgApplStateP) |
| Retrieves the name and potentially the state of the foreground application. More... | |
| ScStatus | scGetDllLogPars (char logFile[gMaxFileNameLen], int *maxSizeP, bool *isLogToFileP, bool *isLogToCnslP, bool *isWrnP, bool *isCrtP, bool *isTrcP, bool *isDcmP, bool *isIcmP, bool *isInfP, bool *isDbgP, bool *isTmpP, char exclFileToLog[gMaxFileNameLen]) |
| Retrieves the logging parameters and filenames actually used by the internal DLL functions. More... | |
| ScStatus | scSetDllLogPars (char logFile[gMaxFileNameLen], int maxSize, bool isLogToFile, bool isLogToCnsl, bool isWrn, bool isCrt, bool isTrc, bool isDcm, bool isIcm, bool isInf, bool isDbg, bool isTmp, char exclFileToLog[gMaxFileNameLen]) |
| Sets the logging parameters actually used by the internal DLL functions. More... | |
| ScStatus | scSetState2 (char *state) |
| Informs the daemon about the internal state (mode) of a supported application. More... | |
| ScStatus | scSetState (char *str1, char *str2) |
| ScStatus | scSetMode (ScDaemonMode mode) |
| This function is for internal use only - do not call it. More... | |
| ScStatus | scGetDaemonPar (int par, int *val) |
| Retrieves one of the parameters available in the Daemon's configuration file "daemon.ini". More... | |
| ScStatus | scSetDaemonPar (int par, int *val) |
| Sets one of the parameters available in the Daemon's configuration file "daemon.ini". More... | |
| ScStatus | scGetDevInfo (int devIdx, ScDevInfo *diP) |
| Retrieves some information data about the device with the given index. More... | |
| ScStatus | scGetDefDevPars (int devIdx, ScDevPars *dpP) |
| Retrieves the default values of the device parameters. More... | |
| ScStatus | scGetDevPars (int devIdx, ScDevPars *dpP) |
| Retrieves the actual device parameters as listed in the *.cfg files. More... | |
| ScStatus | scSetDevPars (int devIdx, ScDevPars *dpP) |
| Sets and retrieves the actual device parameters as listed in the device's configuration file. More... | |
| ScStatus | scSetDevParsToDefaults (int devIdx, ScDevPars *dpP) |
| Sets the actual device parameters to the defaults and retrieves the new parameters. More... | |
| ScStatus | scGetBasicSettings (int devIdx, ScBasicSettings *bsP) |
| Retrieves the actual basic settings parameters. More... | |
| ScStatus | scSetBasicSettings (int devIdx, ScBasicSettings *bsP) |
| Sets and retrieves the actual basic settings parameters. More... | |
| ScStatus | scGetAdvancedSettings (int devIdx, ScAdvancedSettings *asP) |
| Retrieves the actual advanced settings parameters. More... | |
| ScStatus | scSetAdvancedSettings (int devIdx, ScAdvancedSettings *asP) |
| Sets and retrieves the actual advanced settings parameters. More... | |
| ScStatus | scGetAdvSens (int devIdx, ScAdvSens *asP) |
| Retrieves the actual six sensitivity parameters of the advanced settings. More... | |
| ScStatus | scSetAdvSens (int devIdx, ScAdvSens *asP) |
| Sets and retrieves the six actual sensitivity parameters of the advanced settings. More... | |
| ScStatus | scGetStdMode (int devIdx, unsigned char *bitmaskP) |
| ScStatus | scSetStdMode (int devIdx, unsigned char *bitmaskP) |
| ScStatus | scGetSens (int devIdx, int *transSensP, int *rotSensP) |
| Retrieves the device's sensitivity. More... | |
| ScStatus | scSetSens (int devIdx, int *transSensP, int *rotSensP) |
| Sets and retrieves the device's sensitivity. More... | |
| ScStatus | scGetXTraSens (int devIdx, int *sensP) |
| Retrieves the device's sensitivity for the x-translation. More... | |
| ScStatus | scSetXTraSens (int devIdx, int *sensP) |
| Sets and retrieves the device's sensitivity for the x-axis' translation. More... | |
| ScStatus | scGetYTraSens (int devIdx, int *sensP) |
| Retrieves the device's sensitivity for the y-translation. More... | |
| ScStatus | scSetYTraSens (int devIdx, int *sensP) |
| Sets and retrieves the device's sensitivity for the y-axis' translation. More... | |
| ScStatus | scGetZTraSens (int devIdx, int *sensP) |
| Retrieves the device's sensitivity for the z-translation. More... | |
| ScStatus | scSetZTraSens (int devIdx, int *sensP) |
| Sets and retrieves the device's sensitivity for the z-axis' translation. More... | |
| ScStatus | scGetXRotSens (int devIdx, int *sensP) |
| Retrieves the device's sensitivity for the x-rotation. More... | |
| ScStatus | scSetXRotSens (int devIdx, int *sensP) |
| Sets and retrieves the device's sensitivity for the x-axis' rotation. More... | |
| ScStatus | scGetYRotSens (int devIdx, int *sensP) |
| Retrieves the SC device's sensitivity for the y-rotation. More... | |
| ScStatus | scSetYRotSens (int devIdx, int *sensP) |
| Sets and retrieves the SpaceControl device's sensitivity for the y-axis' rotation. More... | |
| ScStatus | scGetZRotSens (int devIdx, int *sensP) |
| Retrieves the device's sensitivity for the z-rotation. More... | |
| ScStatus | scSetZRotSens (int devIdx, int *sensP) |
| Sets and retrieves the device's sensitivity for the z-axis' rotation. More... | |
| ScStatus | scGetSendDelay (int devIdx, int *maxPeriodP, int *minPeriodP) |
| Retrieves the devic's data rate parameters. More... | |
| ScStatus | scSetSendDelay (int devIdx, int *maxPeriodP, int *minPeriodP) |
| Sets and retrieves the devices's data rate parameters. More... | |
| ScStatus | scGetNullRad (int devIdx, int *nullRadP) |
| Retrieves the device's null radius (threshold). More... | |
| ScStatus | scSetNullRad (int devIdx, int *nullRadP) |
| Sets and retrieves the device's null radius (threshold). More... | |
| ScStatus | scSetStdZero (int devIdx) |
| Sets the actual displacement of the cap as the standard 0 value. More... | |
| ScStatus | scFetchStdData (int devIdx, short *xP, short *yP, short *zP, short *aP, short *bP, short *cP, int *traLmhP, int *rotLmhP, int *eventP, long *tvSecP, long *tvUsecP) |
| Fetches the standard data set. More... | |
| void * | writeDataToCbFunction (void *proxyP) |
| void * | readDataFromDevice (void *proxyP) |
| int | createDeviceProxyThreads (int devIdx, stdDataCallbackP cbP) |
| bool | checkDevIndex (int devIdx) |
| ScStatus | scTransferCallbackFunction (int devIdx, stdDataCallbackP cbP) |
| This function hands over a callback function pointer to the API. More... | |
| ScStatus | scGetRawData (int devIdx, unsigned char buf[RAW_DATA_LEN]) |
| The opto-electronical sensor integrated into the cap consists of six LEDs illuminating six position sensitive devices (PSD) producing data between 0 and 1023. More... | |
| ScStatus | scGetTra (int devIdx, bool *isTraP) |
| Answers with true if the translational mode is set. More... | |
| ScStatus | scSetTra (int devIdx, bool *isTraP) |
| Sets and retrieves the translational mode. More... | |
| ScStatus | scGetXTra (int devIdx, bool *isTraP) |
| Answers with true if the x-axis' translational data will be transmitted. More... | |
| ScStatus | scSetXTra (int devIdx, bool *isTraP) |
| Sets and retrieves the translational mode for the x-axis. More... | |
| ScStatus | scGetYTra (int devIdx, bool *isTraP) |
| Answers with true if the y-axis' translational data will be transmitted. More... | |
| ScStatus | scSetYTra (int devIdx, bool *isTraP) |
| Sets and retrieves the translational mode for the y-axis. More... | |
| ScStatus | scGetZTra (int devIdx, bool *isTraP) |
| Answers with true if the z-axis' translational data will be transmitted. More... | |
| ScStatus | scSetZTra (int devIdx, bool *isTraP) |
| Sets and retrieves the translational mode for the z-axis. More... | |
| ScStatus | scGetXTraRev (int devIdx, bool *isRevP) |
| Answers with true if the x-axis' translational mode is set to reverse. More... | |
| ScStatus | scSetXTraRev (int devIdx, bool *isRevP) |
| Sets and retrieves the x-axis' reverse translational mode. More... | |
| ScStatus | scGetYTraRev (int devIdx, bool *isRevP) |
| Answers with true if the y-axis' translational mode is set to reverse. More... | |
| ScStatus | scSetYTraRev (int devIdx, bool *isRevP) |
| Sets and retrieves the y-axis' reverse translational mode. More... | |
| ScStatus | scGetZTraRev (int devIdx, bool *isRevP) |
| Answers with true if the z-axis' translational mode is set to reverse. More... | |
| ScStatus | scSetZTraRev (int devIdx, bool *isRevP) |
| Sets and retrieves the z-axis' reverse translational mode. More... | |
| ScStatus | scGetRot (int devIdx, bool *isRotP) |
| Answers with true if the rotational mode is set. More... | |
| ScStatus | scSetRot (int devIdx, bool *isRotP) |
| Sets and retrieves the rotational mode. More... | |
| ScStatus | scGetXRot (int devIdx, bool *isRotP) |
| Answers with true if the x-axis' rotational data will be transmitted. More... | |
| ScStatus | scSetXRot (int devIdx, bool *isRotP) |
| Sets and retrieves the rotational mode for the x-axis. More... | |
| ScStatus | scGetYRot (int devIdx, bool *isRotP) |
| Answers with true if the y-axis' rotational data will be transmitted. More... | |
| ScStatus | scSetYRot (int devIdx, bool *isRotP) |
| Sets and retrieves the rotational mode for the y-axis. More... | |
| ScStatus | scGetZRot (int devIdx, bool *isRotP) |
| Answers with true if the z-axis' rotational data will be transmitted. More... | |
| ScStatus | scSetZRot (int devIdx, bool *isRotP) |
| Sets and retrieves the rotational mode for the z-axis. More... | |
| ScStatus | scGetXRotRev (int devIdx, bool *isRevP) |
| Answers with true if the x-axis' rotational mode is set to reverse. More... | |
| ScStatus | scSetXRotRev (int devIdx, bool *isRevP) |
| Sets and retrieves the x-axis' reverse rotational mode. More... | |
| ScStatus | scGetYRotRev (int devIdx, bool *isRevP) |
| Answers with true if the y-axis' rotational mode is set to reverse. More... | |
| ScStatus | scSetYRotRev (int devIdx, bool *isRevP) |
| Sets and retrieves the y-axis' reverse rotational mode. More... | |
| ScStatus | scGetZRotRev (int devIdx, bool *isRevP) |
| Answers with true if the z-axis' rotational mode is set to reverse. More... | |
| ScStatus | scSetZRotRev (int devIdx, bool *isRevP) |
| Sets and retrieves the z-axis' reverse rotational mode. More... | |
| ScStatus | scGetDom (int devIdx, bool *isDomP) |
| Answers with true if the dominant mode is set. More... | |
| ScStatus | scSetDom (int devIdx, bool *isDomP) |
| Sets and retrieves the dominant mode. More... | |
| ScStatus | scReadMsg (int devIdx, char *msgP) |
| ScStatus | scGetCfgFilename (int devIdx, char *filename) |
| Retrieves the name and path of the device's actual configuration file. More... | |
| ScStatus | scSaveDevPars (int devIdx, char *filePath) |
| Saves the actual parameters of the device with index devIdx to the configuration file given in filePath. More... | |
| ScStatus | scLoadDevPars (int devIdx, char *filePath, ScDevPars *dpP) |
| Loads the parameters in the configuration file given in filePath into the device with index devIdx. More... | |
| ScStatus | scPressKey (int devIdx, int key) |
| Triggers the same action as is done when a key of the device is pressed, i. More... | |
| ScStatus | scRelKey (int devIdx, int key) |
| Triggers the same action as is done when a key of the device is released. More... | |
| ScStatus | scTriggerFunction (int devIdx, int funcIdx) |
| Triggers the function with index funcIdx. More... | |
| ScStatus | scSetLeds (int devIdx, int *redP, int *greenP, int *blueP) |
| Sets and retrieves the brightness of the device's blue LEDs. More... | |
| ScStatus | scGetLed (int devIdx, int ledNo, int *brightnessP) |
| Gets the brightness of a single LED. More... | |
| ScStatus | scSetLed (int devIdx, int ledNo, int *brightnessP) |
| Sets and retrieves the brightness of a single LED. More... | |
| ScStatus | scGetLedsEx (int devIdx, char brightness[LED_NUM]) |
| Gets the brightnesses of all LEDs. More... | |
| ScStatus | scSetLedsEx (int devIdx, char brightness[LED_NUM]) |
| Sets and retrieves the brightness of all LEDs. More... | |
| ScStatus | scGetLcd (int devIdx, int *brightnessP) |
| Retrieves the LCD's brightness. More... | |
| ScStatus | scSetLcd (int devIdx, int *brightnessP) |
| Sets and retrieves the LCD's brightness Example: More... | |
| ScStatus | scSetLcdColor (int devIdx, int *redP, int *greenP, int *blueP) |
| Sets and retrieves the LCD's background color. More... | |
| ScStatus | scSetDsplString (int devIdx, int row, char text[MAX_DSPL_STR_LEN], int *charNumP) |
| Sets a line of text into the display. More... | |
| ScStatus | scGetFmwUpdtState (int devIdx, int *mcuIdP, int *progressP) |
| Retrieves the state of a firmware update in progress. More... | |
| ScStatus | scExecCmd (int devIdx, char *cmd) |
| Executes a special command. More... | |
| ScStatus | scGetLogPars () |
| void | scPrintVersion () |
The SpaceControl DLL's implementing file.
| ScStatus scSetMode | ( | ScDaemonMode | mode | ) |
This function is for internal use only - do not call it.
| mode | SC_DMN_NRM normal mode, SC_DMN_TST test mode |
References SC_COMMUNICATION_ERROR, and SC_OK.
| char* scStatusToStr | ( | ScStatus | ss | ) |
Returns a DLL function's status code as a string.
| ss | status code to be retrieved |
References SC_APPL_NOT_FOUND, SC_COMMUNICATION_ERROR, SC_FILE_IO_ERROR, SC_KEYSTROKE_ERROR, SC_OK, SC_PARAMETER_OUT_OF_RANGE, SC_REGISTRY_ERROR, and SC_WRONG_DEVICE_INDEX.
| Copyright (c) SpaceControl GmbH, Am Technologiepark 10, D-82229 Seefeld |