SpaceControl DLL  Version 2.8.9
API documentation for the SpaceControl 3D input devices
spc_ctrlr.h File Reference

The SpaceController DLL's header file. More...

#include <string>
#include <vector>
#include "scDevPars.h"
Include dependency graph for spc_ctrlr.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  ScCom
 Structure needed for communication via the MS Windows messaging system or the X-Server messaging system under Linux. More...
 
struct  ScDevInfo
 Information structure concerning a SpaceController device. More...
 
struct  ScVersion
 Structure holding the Daemon software's version no. More...
 
struct  ScFgAppl
 Structure holding a foreground application's name and state. More...
 
struct  ScFilename
 Structure holding the path and filename of a configuration file to write to harddisk or read from it. More...
 

Macros

#define SC_API
 macro is needed for defining DLL ex- and import
 
#define MIN_STD_MODE   0
 smallest standard mode parameter for scSetStdMode()
 
#define MAX_STD_MODE   7
 biggest standard mode parameter for scSetStdMode(), 7 = 00000111
 
#define MIN_CMPR_MODE   0
 smallest compression mode parameter for scSetCmprMode()
 
#define MAX_CMPR_MODE   119
 biggest compression mode parameter for scSetCmprMode(), 119 = 01110111
 
#define MIN_PERIOD   0
 smallest data rate parameter for scSetSendDelay()
 
#define MAX_PERIOD   405
 biggest data rate parameter for scSetSendDelay() (>400 => no data will be sent)
 
#define MIN_SENS   0
 smallest sensitivity for scSetSens()
 
#define MAX_SENS   15
 biggest sensitivity for scSetSens()
 
#define MIN_NULL_RAD   0
 smallest null radius for scSetNullRad()
 
#define MAX_NULL_RAD   15
 biggest null radius for scSetNullRad()
 
#define MIN_BRIGHTNESS   0
 smallest brightness for LEDs and LCD
 
#define MAX_BRIGHTNESS   15
 biggest brightness for LEDs and LCD
 
#define MIN_COLOR_VAL   0
 smallest value of a color compartment (RGB)
 
#define MAX_COLOR_VAL   255
 biggest value of a color compartment (RGB)
 
#define MAX_AVE_NUM   15
 maximal number of values used for averaging the standard data
 
#define NO_BRGHT_CHANGE   MAX_BRIGHTNESS+1
 indicator for no change in brightness
 
#define FORCE_SET_BRIGHTNESS   20
 add this value to the wanted brightness to avoid daemon's suppressing of same values
 
#define MIN_LMH_BND   0
 smallest value for low, mid, high bounderies
 
#define MAX_LMH_BND   5000
 biggest value for low, mid, high bounderies
 
#define RAW_DATA_LEN   28
 length of the raw data buffer
 
#define MAX_FRM_REC_DATA_LEN   83
 max. lenght of a firmware hex record message + controller byte + header byte + NULL
 
#define RAM_PAGE_PART_LEN   69
 length of a message for updating the display's RAM (1/8th page)
 
#define LED_NUM   33
 Anzahl der LEDs.
 
#define MAX_DEV_NUM   16
 max. number of devices to be connected to the computer
 
#define MIN_KEY_IDX   0
 smallest possible index for the device's keys (there are 17 keys)
 
#define MAX_KEY_IDX   16
 biggest possible index for the device's keys (there are 17 keys)
 
#define MAX_STR_LEN   32
 max. length of character strings sent to the daemon
 
#define MAX_DSPL_STR_LEN   40
 max. length of a string in the LCD
 
#define MIN_DSPL_ROW   0
 min. row to be set in the LCD
 
#define MAX_DSPL_ROW   6
 max. row to be set in the LCD
 
#define FLAG_OFFSET   100
 Offset, um besondere Zustaende zu signalisieren.
 
#define MOTION_EVT   "MotionEvent"
 message string for RegisterWindowMessage()
 
#define BUT_PRESS_EVT   "ButtonPressEvent"
 message string for RegisterWindowMessage()
 
#define BUT_REL_EVT   "ButtonReleaseEvent"
 message string for RegisterWindowMessage()
 
#define CMD_EVT   "CommandEvent"
 message string for RegisterWindowMessage()
 
#define TASK_BAR_EVT   "TaskBarEvent"
 message string for RegisterWindowMessage()
 
#define UNNAMED_TRNS   "unnamedTrncvr"
 internal name for applications not given a special name
 
#define DEV_DCN_EVT   "DeviceDisconnectEvent"
 message string for RegisterWindowMessage()
 
#define SB_MOTION_EVT   "SpaceballMotionEventType"
 message string for RegisterWindowMessage()
 
#define SB_BUT_PRESS_EVT   "SpaceballButtonPressEventType"
 message string for RegisterWindowMessage()
 
#define SB_BUT_REL_EVT   "SpaceballButtonReleaseEventType"
 message string for RegisterWindowMessage()
 
#define SB_CMD_EVT   "SpaceballPassThruCommandEventType"
 message string for RegisterWindowMessage()
 
#define SW_CMD_EVT   "SpaceWarePassThruCommandEventType"
 message string for RegisterWindowMessage()
 
#define MAX_SERIALNO_LEN   16
 serial number's max. length
 
#define MAX_DESCRPTN_LEN   64
 description's max. length
 
#define MAX_VERSION_LEN   16
 version number's max. length
 
#define MAX_FILENAME_LEN   256
 max. length of path and filename for configuration files (and logging files)
 
#define MAX_APPL_NAME_LEN   32
 maximal length of an application name
 
#define MAX_APPL_STATE_LEN   32
 maximal length of an application's state
 

Typedefs

typedef int(* stdDataCallbackP) (short x, short y, short z, short a, short b, short c, int traLmh, int rotLmh, int event, long tvSec, long tvUsec)
 Callback function's signature when using scRegisterCallbackFunction() to get data packets from a device. More...
 

Enumerations

enum  WinEvents {
  MotionEvent = 24869, ButtonPressEvent, ButtonReleaseEvent, CommandEvent,
  TaskBarEvent
}
 Enumeration for the various Windows-Events for Windows message handling.
 
enum  WinCommands {
  MagellanNoCommand, MagellanStop, MagellanSetWindowCommand = 27695, MagellanApplicationSensitivity,
  MagellanRingBell, MagellanApplicationStarts, MagellanModeChange, MagellanNullRadiusChange,
  MagellanControlPanel, MagellanInternSendCommand, MagellanSetActiveLed, StopDriver,
  OpenControlPanel, ShowVersionInfo
}
 In case of a command event these commands are possible.
 
enum  ScKey {
  SC_KEY_1 = 0, SC_KEY_2, SC_KEY_3, SC_KEY_4,
  SC_KEY_5, SC_KEY_6, SC_KEY_CTRL, SC_KEY_ALT,
  SC_KEY_SHIFT, SC_KEY_ESC, SC_KEY_FRONT, SC_KEY_RIGHT,
  SC_KEY_TOP, SC_KEY_FIT, SC_KEY_2D3D, SC_KEY_PANEL,
  SC_KEY_MENU, SC_KEY_1_B, SC_KEY_2_B, SC_KEY_3_B,
  SC_KEY_4_B, SC_KEY_5_B, SC_KEY_6_B, SC_KEY_CTRL_B,
  SC_KEY_ALT_B, SC_KEY_SHIFT_B, SC_KEY_ESC_B, SC_KEY_FRONT_B,
  SC_KEY_RIGHT_B, SC_KEY_TOP_B, SC_KEY_FIT_B, SC_KEY_2D3D_B,
  SC_KEY_PANEL_B, SC_KEY_MENU_B, SC_KEY_END
}
 Enumeration to name the device's keys.
 
enum  DaemonPar {
  BAUD, MAX_BYTES_IN_RX_QUEUE, PORT, CFG_AUTO_CHANGE,
  REMEMBER_LAST_CONFIG, DISABLE_CUBE_DEMO, EXPLORER_DELAY, DEVICE_TIMEOUT,
  SEND_MODE, SEND_DELAY, CAP_CHARACTERISTIC, SINGLE_COM_PER_APPL,
  ENABLE_LEGACY_COM1, ENABLE_LEGACY_COM2, BLINK_PERIOD, SEARCH_TOP_WINDOW,
  SKIP_TIMEOUT, TIME_BEFORE_SLEEPING, WHEEL_ACCELERATOR, DEVICE_CHECKING_TIME,
  PROGRAM_PARS_END
}
 Enumeration to name the parameters in the daemon.ini's [PROGRAM] section.
 
enum  ScDaemonMode { SC_DMN_NRM, SC_DMN_TST_SPC, SC_DMN_TST_GEN, SC_DMN_END }
 This enumeration is reserved for internal use.
 
enum  ScStatus {
  SC_OK, SC_COMMUNICATION_ERROR, SC_WRONG_DEVICE_INDEX, SC_PARAMETER_OUT_OF_RANGE,
  SC_FILE_IO_ERROR, SC_KEYSTROKE_ERROR, SC_APPL_NOT_FOUND, SC_REGISTRY_ERROR,
  SC_NOT_SUPPORTED, SC_EXEC_CMD_ERROR, SC_THREAD_ERROR, SC_WRONG_USER,
  SC_ERR_END
}
 These status values are returned by the DLL functions. More...
 

Functions

SC_API char * scStatusToStr (ScStatus ks)
 Returns a DLL function's status code as a string. More...
 
SC_API ScStatus scIsProcessRunning (char *processName, bool *isRunningP)
 Checks if the process with the given name is running or not. More...
 
SC_API 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...
 
SC_API 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...
 
SC_API ScStatus scDelCurrentUserRegValue (char *keyP, char *nameP)
 Deletes a string value in the Windows registry under the base key HKEY_CURRENT_USER. More...
 
SC_API ScStatus scConnect2 (bool isAlwaysReceivingData, char *applName)
 Establishes the connection to the SpaceControl daemon. More...
 
SC_API ScStatus scConnect ()
 
SC_API ScStatus scDisconnect ()
 Closes the connection to the SpaceControl daemon. More...
 
SC_API ScStatus scStop ()
 Sends the SpaceControl Daemon a stop message, the process finishes itself after sending an OK message. More...
 
SC_API ScStatus scGetDmnVrsn (char *versionP, char *pathP)
 Retrieves the SpaceControl daemon's software version and its binary name and path. More...
 
SC_API 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...
 
SC_API ScStatus scGetFgAppl (char *fgApplP, char *fgApplStateP)
 Retrieves the name and potentially the state of the foreground application. More...
 
SC_API 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...
 
SC_API 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...
 
SC_API ScStatus scSetState2 (char *state)
 Informs the daemon about the internal state (mode) of a supported application. More...
 
SC_API ScStatus scSetState (char *str1, char *str2)
 
SC_API ScStatus scSetMode (ScDaemonMode mode)
 This function is for internal use only - do not call it. More...
 
SC_API ScStatus scGetDaemonPar (int par, int *valP)
 Retrieves one of the integer or boolean parameters available in the Daemon's configuration file "daemon.ini". More...
 
SC_API ScStatus scSetDaemonPar (int par, int *valP)
 Sets one of the integer or boolean parameters available in the Daemon's configuration file "daemon.ini". More...
 
SC_API ScStatus scGetDevInfo (int devIdx, ScDevInfo *diP)
 Retrieves some information data about the device with the given index. More...
 
SC_API ScStatus scGetDefDevPars (int devIdx, ScDevPars *dpP)
 Retrieves the default values of the device parameters. More...
 
SC_API ScStatus scGetDevPars (int devIdx, ScDevPars *dpP)
 Retrieves the actual device parameters as listed in the *.cfg files. More...
 
SC_API ScStatus scSetDevPars (int devIdx, ScDevPars *dpP)
 Sets and retrieves the actual device parameters as listed in the device's configuration file. More...
 
SC_API ScStatus scSetDevParsToDefaults (int devIdx, ScDevPars *dpP)
 Sets the actual device parameters to the defaults and retrieves the new parameters. More...
 
SC_API ScStatus scGetBasicSettings (int devIdx, ScBasicSettings *bsP)
 Retrieves the actual basic settings parameters. More...
 
SC_API ScStatus scSetBasicSettings (int devIdx, ScBasicSettings *bsP)
 Sets and retrieves the actual basic settings parameters. More...
 
SC_API ScStatus scGetAdvancedSettings (int devIdx, ScAdvancedSettings *asP)
 Retrieves the actual advanced settings parameters. More...
 
SC_API ScStatus scSetAdvancedSettings (int devIdx, ScAdvancedSettings *bsP)
 Sets and retrieves the actual advanced settings parameters. More...
 
SC_API ScStatus scGetAdvSens (int devIdx, ScAdvSens *dpP)
 Retrieves the actual six sensitivity parameters of the advanced settings. More...
 
SC_API ScStatus scSetAdvSens (int devIdx, ScAdvSens *dpP)
 Sets and retrieves the six actual sensitivity parameters of the advanced settings. More...
 
SC_API ScStatus scGetStdMode (int devIdx, unsigned char *bitmaskP)
 
SC_API ScStatus scSetStdMode (int devIdx, unsigned char *bitmaskP)
 
SC_API ScStatus scGetCmprMode (int devIdx, unsigned char *bitmaskP)
 
SC_API ScStatus scSetCmprMode (int devIdx, unsigned char *bitmaskP)
 
SC_API ScStatus scGetSens (int devIdx, int *transSensP, int *rotSensP)
 Retrieves the device's sensitivity. More...
 
SC_API ScStatus scSetSens (int devIdx, int *transSensP, int *rotSensP)
 Sets and retrieves the device's sensitivity. More...
 
SC_API ScStatus scGetXTraSens (int devIdx, int *sensP)
 Retrieves the device's sensitivity for the x-translation. More...
 
SC_API ScStatus scSetXTraSens (int devIdx, int *sensP)
 Sets and retrieves the device's sensitivity for the x-axis' translation. More...
 
SC_API ScStatus scGetYTraSens (int devIdx, int *sensP)
 Retrieves the device's sensitivity for the y-translation. More...
 
SC_API ScStatus scSetYTraSens (int devIdx, int *sensP)
 Sets and retrieves the device's sensitivity for the y-axis' translation. More...
 
SC_API ScStatus scGetZTraSens (int devIdx, int *sensP)
 Retrieves the device's sensitivity for the z-translation. More...
 
SC_API ScStatus scSetZTraSens (int devIdx, int *sensP)
 Sets and retrieves the device's sensitivity for the z-axis' translation. More...
 
SC_API ScStatus scGetXRotSens (int devIdx, int *sensP)
 Retrieves the device's sensitivity for the x-rotation. More...
 
SC_API ScStatus scSetXRotSens (int devIdx, int *sensP)
 Sets and retrieves the device's sensitivity for the x-axis' rotation. More...
 
SC_API ScStatus scGetYRotSens (int devIdx, int *sensP)
 Retrieves the SC device's sensitivity for the y-rotation. More...
 
SC_API ScStatus scSetYRotSens (int devIdx, int *sensP)
 Sets and retrieves the SpaceControl device's sensitivity for the y-axis' rotation. More...
 
SC_API ScStatus scGetZRotSens (int devIdx, int *sensP)
 Retrieves the device's sensitivity for the z-rotation. More...
 
SC_API ScStatus scSetZRotSens (int devIdx, int *sensP)
 Sets and retrieves the device's sensitivity for the z-axis' rotation. More...
 
SC_API ScStatus scGetSendDelay (int devIdx, int *maxPeriodP, int *minPeriodP)
 Retrieves the devic's data rate parameters. More...
 
SC_API ScStatus scSetSendDelay (int devIdx, int *maxPeriodP, int *minPeriodP)
 Sets and retrieves the devices's data rate parameters. More...
 
SC_API ScStatus scGetNullRad (int devIdx, int *nullRadP)
 Retrieves the device's null radius (threshold). More...
 
SC_API ScStatus scSetNullRad (int devIdx, int *nullRadP)
 Sets and retrieves the device's null radius (threshold). More...
 
SC_API ScStatus scSetStdZero (int devIdx)
 Sets the actual displacement of the cap as the standard 0 value. More...
 
SC_API 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...
 
SC_API 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...
 
SC_API ScStatus scGetTra (int devIdx, bool *isTraP)
 Answers with true if the translational mode is set. More...
 
SC_API ScStatus scSetTra (int devIdx, bool *isTraP)
 Sets and retrieves the translational mode. More...
 
SC_API ScStatus scGetXTra (int devIdx, bool *isTraP)
 Answers with true if the x-axis' translational data will be transmitted. More...
 
SC_API ScStatus scSetXTra (int devIdx, bool *isTraP)
 Sets and retrieves the translational mode for the x-axis. More...
 
SC_API ScStatus scGetYTra (int devIdx, bool *isTraP)
 Answers with true if the y-axis' translational data will be transmitted. More...
 
SC_API ScStatus scSetYTra (int devIdx, bool *isTraP)
 Sets and retrieves the translational mode for the y-axis. More...
 
SC_API ScStatus scGetZTra (int devIdx, bool *isTraP)
 Answers with true if the z-axis' translational data will be transmitted. More...
 
SC_API ScStatus scSetZTra (int devIdx, bool *isTraP)
 Sets and retrieves the translational mode for the z-axis. More...
 
SC_API ScStatus scGetXTraRev (int devIdx, bool *isRevP)
 Answers with true if the x-axis' translational mode is set to reverse. More...
 
SC_API ScStatus scSetXTraRev (int devIdx, bool *isRevP)
 Sets and retrieves the x-axis' reverse translational mode. More...
 
SC_API ScStatus scGetYTraRev (int devIdx, bool *isRevP)
 Answers with true if the y-axis' translational mode is set to reverse. More...
 
SC_API ScStatus scSetYTraRev (int devIdx, bool *isRevP)
 Sets and retrieves the y-axis' reverse translational mode. More...
 
SC_API ScStatus scGetZTraRev (int devIdx, bool *isRevP)
 Answers with true if the z-axis' translational mode is set to reverse. More...
 
SC_API ScStatus scSetZTraRev (int devIdx, bool *isRevP)
 Sets and retrieves the z-axis' reverse translational mode. More...
 
SC_API ScStatus scGetRot (int devIdx, bool *isRotP)
 Answers with true if the rotational mode is set. More...
 
SC_API ScStatus scSetRot (int devIdx, bool *isRotP)
 Sets and retrieves the rotational mode. More...
 
SC_API ScStatus scGetXRot (int devIdx, bool *isRotP)
 Answers with true if the x-axis' rotational data will be transmitted. More...
 
SC_API ScStatus scSetXRot (int devIdx, bool *isRotP)
 Sets and retrieves the rotational mode for the x-axis. More...
 
SC_API ScStatus scGetYRot (int devIdx, bool *isRotP)
 Answers with true if the y-axis' rotational data will be transmitted. More...
 
SC_API ScStatus scSetYRot (int devIdx, bool *isRotP)
 Sets and retrieves the rotational mode for the y-axis. More...
 
SC_API ScStatus scGetZRot (int devIdx, bool *isRotP)
 Answers with true if the z-axis' rotational data will be transmitted. More...
 
SC_API ScStatus scSetZRot (int devIdx, bool *isRotP)
 Sets and retrieves the rotational mode for the z-axis. More...
 
SC_API ScStatus scGetXRotRev (int devIdx, bool *isRevP)
 Answers with true if the x-axis' rotational mode is set to reverse. More...
 
SC_API ScStatus scSetXRotRev (int devIdx, bool *isRevP)
 Sets and retrieves the x-axis' reverse rotational mode. More...
 
SC_API ScStatus scGetYRotRev (int devIdx, bool *isRevP)
 Answers with true if the y-axis' rotational mode is set to reverse. More...
 
SC_API ScStatus scSetYRotRev (int devIdx, bool *isRevP)
 Sets and retrieves the y-axis' reverse rotational mode. More...
 
SC_API ScStatus scGetZRotRev (int devIdx, bool *isRevP)
 Answers with true if the z-axis' rotational mode is set to reverse. More...
 
SC_API ScStatus scSetZRotRev (int devIdx, bool *isRevP)
 Sets and retrieves the z-axis' reverse rotational mode. More...
 
SC_API ScStatus scGetDom (int devIdx, bool *isDomP)
 Answers with true if the dominant mode is set. More...
 
SC_API ScStatus scSetDom (int devIdx, bool *isDomP)
 Sets and retrieves the dominant mode. More...
 
SC_API ScStatus scReadMsg (int devIdx, char *msgP)
 
SC_API ScStatus scGetCfgFilename (int devIdx, char *filenameP)
 Retrieves the name and path of the device's actual configuration file. More...
 
SC_API ScStatus scSaveDevPars (int devIdx, char *filenameP)
 Saves the actual parameters of the device with index devIdx to the configuration file given in filePath. More...
 
SC_API ScStatus scLoadDevPars (int devIdx, char *filenameP, ScDevPars *dpP)
 Loads the parameters in the configuration file given in filePath into the device with index devIdx. More...
 
SC_API ScStatus scPressKey (int devIdx, int key)
 Triggers the same action as is done when a key of the device is pressed, i. More...
 
SC_API ScStatus scRelKey (int devIdx, int key)
 Triggers the same action as is done when a key of the device is released. More...
 
SC_API ScStatus scSetLed (int devIdx, int ledNo, int *brightnessP)
 Sets and retrieves the brightness of a single LED. More...
 
SC_API ScStatus scGetLed (int devIdx, int ledNo, int *brightnessP)
 Gets the brightness of a single LED. More...
 
SC_API ScStatus scSetLeds (int devIdx, int *redP, int *greenP, int *blueP)
 Sets and retrieves the brightness of the device's blue LEDs. More...
 
SC_API ScStatus scSetLedsEx (int devIdx, char brightness[LED_NUM])
 Sets and retrieves the brightness of all LEDs. More...
 
SC_API ScStatus scGetLedsEx (int devIdx, char brightness[LED_NUM])
 Gets the brightnesses of all LEDs. More...
 
SC_API ScStatus scSetLcd (int devIdx, int *brightnessP)
 Sets and retrieves the LCD's brightness
Example: More...
 
SC_API ScStatus scGetLcd (int devIdx, int *brightnessP)
 Retrieves the LCD's brightness. More...
 
SC_API ScStatus scSetLcdColor (int devIdx, int *redP, int *greenP, int *blueP)
 Sets and retrieves the LCD's background color. More...
 
SC_API ScStatus scSetDsplString (int devIdx, int row, char text[MAX_DSPL_STR_LEN], int *charNumP)
 Sets a line of text into the display. More...
 
SC_API ScStatus scGetFmwUpdtState (int devIdx, int *mcuIdP, int *progressP)
 Retrieves the state of a firmware update in progress. More...
 
SC_API ScStatus scExecCmd (int devIdx, char *cmdP)
 Executes a special command. More...
 
SC_API ScStatus scTriggerFunction (int devIdx, int funcIdx)
 Triggers the function with index funcIdx. More...
 
SC_API ScStatus scTransferCallbackFunction (int devIdx, stdDataCallbackP cbP)
 This function hands over a callback function pointer to the API. More...
 

Detailed Description

The SpaceController DLL's header file.

Include this file into your code if using the DLL's commands.

Typedef Documentation

◆ stdDataCallbackP

typedef int(* stdDataCallbackP) (short x, short y, short z, short a, short b, short c, int traLmh, int rotLmh, int event, long tvSec, long tvUsec)

Callback function's signature when using scRegisterCallbackFunction() to get data packets from a device.

Enumeration Type Documentation

◆ ScStatus

enum ScStatus

These status values are returned by the DLL functions.

Enumerator
SC_OK 

function successfully executed

SC_COMMUNICATION_ERROR 

communication error occurred

SC_WRONG_DEVICE_INDEX 

a wrong device index was given

SC_PARAMETER_OUT_OF_RANGE 

one or more parameters are out of range

SC_FILE_IO_ERROR 

file could not be written or read

SC_KEYSTROKE_ERROR 

sending of keystrokes failed

SC_APPL_NOT_FOUND 

the expected application was not found

SC_REGISTRY_ERROR 

error while accessing the Windows registry

SC_NOT_SUPPORTED 

command is not supported by this device type

SC_EXEC_CMD_ERROR 

command could not be executed

SC_THREAD_ERROR 

thread for reading data from devices could not be started

SC_WRONG_USER 

the DLL's user is not the same as the daemon's user

SC_ERR_END 

not used

Function Documentation

◆ scSetMode()

SC_API ScStatus scSetMode ( ScDaemonMode  mode)

This function is for internal use only - do not call it.

Parameters
modeSC_DMN_NRM normal mode, SC_DMN_TST test mode

References SC_COMMUNICATION_ERROR, and SC_OK.

◆ scStatusToStr()

SC_API char* scStatusToStr ( ScStatus  ss)

Returns a DLL function's status code as a string.

Parameters
ssstatus code to be retrieved
Returns
the status code as a string

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.

SC DLL

SpaceControl Copyright (c) SpaceControl GmbH & Co. KG, Am Technologiepark 10, D-82229 Seefeld
Generated by Doxygen