| ThreeSpace API 2 2.0.6.1 Serial wrapper for YEI 3-Space Sensor Protocol

- Main Page
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines
yei_threespace_api.h
Go to the documentation of this file.

    00001 /********************************************/
    00023 #ifndef YEI_THREESPACE_API_H_INCLUDED
    00024 #define YEI_THREESPACE_API_H_INCLUDED
    00025 #include <stdio.h>
    00026 #include <string.h>
    00027 #include <windows.h>
    00028 #include <process.h>
    00029 #include <math.h>
    00030
    00031
    00032 #ifdef __cplusplus
    00033     extern "C"
    00034     {
    00035 #endif
    00036
    00037 #if defined(__GNUC__)
    00038 #define _inline inline
    00039 #endif
    00040
    00041 #if defined(TSS_STATIC_LIB)
    00042 #define TSS_EXPORT
    00043 #elif defined(_MSC_VER)
    00044 #define TSS_EXPORT __declspec(dllexport)
    00045 #elif defined(__GNUC__)
    00046 #define TSS_EXPORT __attribute__ ((dllexport))
    00047 #endif
    00048
    00049 /********************************************/
    00052 #define TSS_INFINITE_DURATION 0xffffffff
    00053
    00054 /********************************************/
    00058 #define TSS_DEFAULT_WIRLESSS_RETRIES 5
    00059
    00060 /********************************************/
    00064 #define TSS_DEFAULT_BAUD_RATE 115200
    00065
    00066 /********************************************/
    00069 typedef unsigned int TSS_Device_Id;
    00070
    00071 /********************************************/
    00074 typedef enum TSS_Device_Id_Mask
    00075 {
    00076     TSS_NO_DEVICE_ID    = 0x00800000,
    00077     TSS_BOOTLOADER_ID   = 0x01000000,
    00078     TSS_DONGLE_ID       = 0x02000000,
    00079     TSS_USB_ID          = 0x04000000,
    00080     TSS_EMBEDDED_ID     = 0x08000000,
    00081     TSS_WIRELESS_ID     = 0x10000000,
    00082     TSS_WIRELESS_W_ID   = 0x20000000,
    00083     TSS_DATALOGGER_ID   = 0x40000000,
    00084     TSS_BLUETOOTH_ID    = 0x80000000,
    00085     TSS_NO_DONGLE_ID    = 0xfd000000,
    00086     TSS_ALL_SENSORS_ID  = 0xff000000
    00087 }TSS_Device_Id_Mask;
    00088
    00089 /********************************************/
    00092 typedef enum TSS_Timestamp_Mode{
    00093     TSS_TIMESTAMP_NONE,
    00094     TSS_TIMESTAMP_SENSOR,
    00095     TSS_TIMESTAMP_SYSTEM
    00096 }TSS_Timestamp_Mode;
    00097
    00098 /********************************************/
    00101 typedef enum TSS_Error
    00102 {
    00103     TSS_NO_ERROR,
    00104     TSS_ERROR_COMMAND_FAIL,
    00105     TSS_INVALID_COMMAND,
    00106     TSS_INVALID_ID,
    00107     TSS_ERROR_PARAMETER,
    00108     TSS_ERROR_TIMEOUT,
    00109     TSS_ERROR_WRITE,
    00110     TSS_ERROR_READ,
    00111     TSS_ERROR_STREAM_SLOTS_FULL,
    00112     TSS_ERROR_STREAM_CONFIG,
    00113     TSS_ERROR_MEMORY,
    00114     TSS_ERROR_FIRMWARE_INCOMPATIBLE
    00115 }TSS_Error;
    00116
    00117 static const char* const TSS_Error_String[] = {
    00118     "TSS_NO_ERROR",
    00119     "TSS_ERROR_COMMAND_FAIL",
    00120     "TSS_INVALID_COMMAND",
    00121     "TSS_INVALID_ID",
    00122     "TSS_ERROR_PARAMETER",
    00123     "TSS_ERROR_TIMEOUT",
    00124     "TSS_ERROR_WRITE",
    00125     "TSS_ERROR_READ",
    00126     "TSS_ERROR_STREAM_SLOTS_FULL",
    00127     "TSS_ERROR_STREAM_CONFIG",
    00128     "TSS_ERROR_MEMORY",
    00129     "TSS_ERROR_FIRMWARE_INCOMPATIBLE"
    00130 };
    00131
    00132 /********************************************/
    00135 typedef enum TSS_Firmware_Compatibility
    00136 {
    00137     TSS_FW_NOT_COMPATIBLE,
    00138     TSS_FW_20R7_COMPATIBLE,
    00139     TSS_FW_20R10_COMPATIBLE,
    00140     TSS_FW_20R13_COMPATIBLE
    00141 }TSS_Firmware_Compatibility;
    00142
    00143 static const char* const TSS_Firmware_Version_String[] = {
    00144     "00Jan2000A00",
    00145     "25Apr2013A00",
    00146     "21Jun2013A00",
    00147     "28Aug2013A00"
    00148 };
    00149
    00150 /********************************************/
    00158 typedef enum TSS_Stream_Command_Enum
    00159 {
    00160     TSS_GET_TARED_ORIENTATION_AS_QUATERNION                 = 0x00,
    00161     TSS_GET_TARED_ORIENTATION_AS_EULER_ANGLES               = 0x01,
    00162     TSS_GET_TARED_ORIENTATION_AS_ROTATION_MATRIX            = 0x02,
    00163     TSS_GET_TARED_ORIENTATION_AS_AXIS_ANGLE                 = 0x03,
    00164     TSS_GET_TARED_ORIENTATION_AS_TWO_VECTOR                 = 0x04,
    00165     TSS_GET_DIFFERENCE_QUATERNION                           = 0x05,
    00166     TSS_GET_UNTARED_ORIENTATION_AS_QUATERNION               = 0x06,
    00167     TSS_GET_UNTARED_ORIENTATION_AS_EULER_ANGLES             = 0x07,
    00168     TSS_GET_UNTARED_ORIENTATION_AS_ROTATION_MATRIX          = 0x08,
    00169     TSS_GET_UNTARED_ORIENTATION_AS_AXIS_ANGLE               = 0x09,
    00170     TSS_GET_UNTARED_ORIENTATION_AS_TWO_VECTOR               = 0x0a,
    00171     TSS_GET_TARED_TWO_VECTOR_IN_SENSOR_FRAME                = 0x0b,
    00172     TSS_GET_UNTARED_TWO_VECTOR_IN_SENSOR_FRAME              = 0x0c,
    00173     TSS_GET_ALL_NORMALIZED_COMPONENT_SENSOR_DATA            = 0x20,
    00174     TSS_GET_NORMALIZED_GYRO_RATE                            = 0x21,
    00175     TSS_GET_NORMALIZED_ACCELEROMETER_VECTOR                 = 0x22,
    00176     TSS_GET_NORMALIZED_COMPASS_VECTOR                       = 0x23,
    00177     TSS_GET_ALL_CORRECTED_COMPONENT_SENSOR_DATA             = 0x25,
    00178     TSS_GET_CORRECTED_GYRO_RATE                             = 0x26,
    00179     TSS_GET_CORRECTED_ACCELEROMETER_VECTOR                  = 0x27,
    00180     TSS_GET_CORRECTED_COMPASS_VECTOR                        = 0x28,
    00181     TSS_GET_CORRECTED_LINEAR_ACCELERATION_IN_GLOBAL_SPACE   = 0x29,
    00182     TSS_GET_TEMPERATURE_C                                   = 0x2b,
    00183     TSS_GET_TEMPERATURE_F                                   = 0x2c,
    00184     TSS_GET_CONFIDENCE_FACTOR                               = 0x2d,
    00185     TSS_GET_ALL_RAW_COMPONENT_SENSOR_DATA                   = 0x40,
    00186     TSS_GET_RAW_GYROSCOPE_RATE                              = 0x41,
    00187     TSS_GET_RAW_ACCELEROMETER_DATA                          = 0x42,
    00188     TSS_GET_RAW_COMPASS_DATA                                = 0x43,
    00189     TSS_GET_BATTERY_VOLTAGE                                 = 0xc9,
    00190     TSS_GET_BATTERY_PERCENT_REMAINING                       = 0xca,
    00191     TSS_GET_BATTERY_STATUS                                  = 0xcb,
    00192     TSS_GET_BUTTON_STATE                                    = 0xfa,
    00193     TSS_NULL                                                = 0xff
    00194 }TSS_Stream_Command_Enum;
    00195
    00196 /********************************************/
    00199 typedef unsigned char TSS_Stream_Command;
    00200
    00201 /********************************************/
    00204 typedef enum TSS_Find
    00205 {
    00206     TSS_FIND_BTL        = 0x00000001,
    00207     TSS_FIND_USB        = 0x00000002,
    00208     TSS_FIND_DNG        = 0x00000004,
    00209     TSS_FIND_WL         = 0x00000008,
    00210     TSS_FIND_EM         = 0x00000010,
    00211     TSS_FIND_DL         = 0x00000020,
    00212     TSS_FIND_BT         = 0x00000040,
    00213     TSS_FIND_UNKNOWN    = 0x80000000,
    00214     TSS_FIND_ALL_KNOWN  = 0x7fffffff,
    00215     TSS_FIND_ALL        = 0xffffffff
    00216 }TSS_Find;
    00217
    00218 /********************************************/
    00221 typedef enum TSS_Type
    00222 {
    00223     TSS_UNKNOWN,
    00224     TSS_BTL,
    00225     TSS_USB,
    00226     TSS_DNG,
    00227     TSS_WL,
    00228     TSS_WL_W,
    00229     TSS_EM,
    00230     TSS_DL,
    00231     TSS_BT,
    00232 }TSS_Type;
    00233
    00234 static const char* const TSS_Type_String[] = {
    00235     "TSS_UNKNOWN",
    00236     "TSS_BTL",
    00237     "TSS_USB",
    00238     "TSS_DNG",
    00239     "TSS_WL",        //wireless wired (connected to PC)
    00240     "TSS_WL_W",    //wireless wireless
    00241     "TSS_EM",
    00242     "TSS_DL",
    00243     "TSS_BT",
    00244 };
    00245
    00246 /********************************************/
    00249 typedef enum TSS_Axis_Direction
    00250 {
    00251     TSS_XYZ,
    00252     TSS_XZY,
    00253     TSS_YXZ,
    00254     TSS_YZX,
    00255     TSS_ZXY,
    00256     TSS_ZYX,
    00257 }TSS_Axis_Direction;
    00258
    00259 /********************************************/
    00262 typedef enum TSS_Filter_Mode
    00263 {
    00264     TSS_FILTER_IMU,
    00265     TSS_FILTER_KALMAN,
    00266     TSS_FILTER_ALTERNATING_KALMAN,
    00267     TSS_FILTER_COMPLEMENTARY,
    00268     TSS_FILTER_QUATERNION_GRADIENT_DECENT,
    00269 }TSS_Filter_Mode;
    00270
    00271 /********************************************/
    00274 typedef struct TSS_ComPort
    00275 {
    00276     char com_port[32];
    00277     char friendly_name[64];
    00278     int sensor_type;         //Change?
    00279 }TSS_ComPort;
    00280
    00281 /********************************************/
    00284 typedef struct TSS_ComInfo
    00285 {
    00286     TSS_Type device_type;
    00287     unsigned int serial_number;
    00288     char firmware_version[13];
    00289     char hardware_version[33];
    00290     TSS_Firmware_Compatibility fw_compatibility;
    00291 }TSS_ComInfo;
    00292
    00293 /********************************************/
    00303 typedef void CALLBACK TSS_CallBack(TSS_Device_Id device, char * output_data, unsigned int output_data_len, unsigned int * timestamp);
    00304
    00305 // Allow to call those directly when not using a DLL
    00306 #ifdef TSS_STATIC_LIB
    00307 TSS_EXPORT int tss_initThreeSpaceAPI();
    00308 TSS_EXPORT int tss_delThreeSpaceAPI();
    00309 #endif // TSS_STATIC_LIB
    00310
    00311 //convenience functions
    00312 /********************************************/
    00320 TSS_EXPORT void tss_parseAxisDirections(unsigned char axis_byte, TSS_Axis_Direction * axis_order, char * neg_x, char * neg_y, char * neg_z);
    00321
    00322 /********************************************/
    00330 TSS_EXPORT unsigned char tss_generateAxisDirections(TSS_Axis_Direction axis_order, char neg_x, char neg_y, char neg_z);
    00331
    00332 //API specific functions
    00333 // Sets the amount of retries on wireless commands via software, note there is 3 hardware retries by default
    00334 /********************************************/
    00340 TSS_EXPORT void tss_setSoftwareWirelessRetries(unsigned int retries);
    00341
    00342 /********************************************/
    00346 TSS_EXPORT unsigned int tss_getSoftwareWirelessRetries();
    00347
    00348 /********************************************/
    00352 TSS_EXPORT void tss_setDefaultCreateDeviceBaudRate(int baud_rate);
    00353
    00354 /********************************************/
    00358 TSS_EXPORT int tss_getDefaultCreateDeviceBaudRate();
    00359
    00360 /********************************************/
    00368 TSS_EXPORT int tss_getComPorts(TSS_ComPort * ports_vec, unsigned int ports_vec_size, unsigned int offset, unsigned int filter);
    00369
    00370 /********************************************/
    00379 TSS_EXPORT TSS_Error tss_getTSDeviceInfoFromComPort(const char* com_port, TSS_ComInfo * com_info);
    00380
    00381 /********************************************/
    00389 TSS_EXPORT TSS_Error tss_getTSDeviceInfo(TSS_Device_Id device, TSS_ComInfo * com_info);
    00390
    00391 /********************************************/
    00401 TSS_EXPORT TSS_Device_Id tss_createTSDeviceU16Str(const wchar_t* com_port, TSS_Timestamp_Mode mode);
    00402
    00403 /********************************************/
    00413 TSS_EXPORT TSS_Device_Id tss_createTSDeviceStr(const char* com_port, TSS_Timestamp_Mode mode);
    00414
    00415 /********************************************/
    00426 TSS_EXPORT TSS_Device_Id tss_createTSDeviceU16StrEx(const wchar_t* com_port, int baud_rate, TSS_Timestamp_Mode mode);
    00427
    00428 /********************************************/
    00439 TSS_EXPORT TSS_Device_Id tss_createTSDeviceStrEx(const char* com_port, int baud_rate, TSS_Timestamp_Mode mode);
    00440
    00441 /********************************************/
    00447 TSS_EXPORT TSS_Error tss_closeTSDevice(TSS_Device_Id device);
    00448
    00449 /********************************************/
    00461 TSS_EXPORT TSS_Error tss_getSensorFromDongle(TSS_Device_Id device, int logical_id, unsigned int * w_ts_device);
    00462
    00463 /********************************************/
    00474 TSS_EXPORT TSS_Error tss_setSensorToDongle(TSS_Device_Id device, int logical_id, unsigned int w_serial_number);
    00475
    00476 /********************************************/
    00482 TSS_EXPORT TSS_Error tss_setTimestampMode(TSS_Device_Id device, TSS_Timestamp_Mode mode);
    00483
    00484 /********************************************/
    00496 TSS_EXPORT TSS_Error tss_getLastStreamData(TSS_Device_Id device, char * output_data, unsigned int output_data_len, unsigned int * timestamp);
    00497
    00498 /********************************************/
    00510 TSS_EXPORT TSS_Error tss_getLastStreamData2(TSS_Device_Id device, char * output_data, unsigned int output_data_len, unsigned int * timestamp);
    00511
    00512 /********************************************/
    00524 TSS_EXPORT TSS_Error tss_getLatestStreamData(TSS_Device_Id device, char * output_data, unsigned int output_data_len, unsigned int timeout, unsigned int * timestamp);
    00525
    00526 /********************************************/
    00535 TSS_EXPORT TSS_Error tss_setNewDataCallBack(TSS_Device_Id device, TSS_CallBack callback_func);
    00536
    00537 /********************************************/
    00565 TSS_EXPORT TSS_Error tss_sendRawCommandFormatted(   TSS_Device_Id device,
    00566                                                     unsigned char command,
    00567                                                     char* in_data,
    00568                                                     char* in_data_detail,
    00569                                                     char * rtn_data,
    00570                                                     char* rtn_data_detail,
    00571                                                     unsigned int * timestamp);
    00572
    00573 /********************************************/
    00591 TSS_EXPORT TSS_Error tss_sendRawCommand(TSS_Device_Id device,
    00592                                         unsigned char command,
    00593                                         char* in_data,
    00594                                         int in_data_size,
    00595                                         char * rtn_data,
    00596                                         int rtn_data_size,
    00597                                         unsigned int * timestamp);
    00598
    00599 //Remove debug func
    00600 //TSS_EXPORT TSS_Error tss_getRecordCount(TSS_Device_Id device);
    00601
    00602 /********************************************/
    00610 TSS_EXPORT int tss_isConnected(TSS_Device_Id device, int reconnect);
    00611
    00612 /********************************************/
    00618 TSS_EXPORT TSS_Error tss_getTSDeviceType(TSS_Device_Id device, TSS_Type * device_type);
    00619
    00620 /********************************************/
    00627 TSS_EXPORT int tss_resetThreeSpaceAPI();
    00628
    00629 /********************************************/
    00645 TSS_EXPORT int tss_createTSDevicesBySerialNumber(   unsigned int * serial_list,
    00646                                                     TSS_Device_Id * device_list,
    00647                                                     int list_length,
    00648                                                     int search_wireless,
    00649                                                     int search_unknown_devices,
    00650                                                     TSS_Timestamp_Mode mode);
    00651
    00652 /********************************************/
    00663 TSS_EXPORT int tss_getDeviceIDs( TSS_Device_Id * device_list, int list_length, int offset, int filter);
    00664
    00665 //Orientation Commands
    00666 //   0(0x00)
    00667  /*****************AutoGenerated*************/
    00678 TSS_EXPORT TSS_Error tss_getTaredOrientationAsQuaternion(TSS_Device_Id device, float * quat4, unsigned int * timestamp);
    00679 //   1(0x01)
    00680  /*****************AutoGenerated*************/
    00691 TSS_EXPORT TSS_Error tss_getTaredOrientationAsEulerAngles(TSS_Device_Id device, float * euler3, unsigned int * timestamp);
    00692 //   2(0x02)
    00693  /*****************AutoGenerated*************/
    00704 TSS_EXPORT TSS_Error tss_getTaredOrientationAsRotationMatrix(TSS_Device_Id device, float * matrix9, unsigned int * timestamp);
    00705 //   3(0x03)
    00706  /*****************AutoGenerated*************/
    00717 TSS_EXPORT TSS_Error tss_getTaredOrientationAsAxisAngle(TSS_Device_Id device, float * axis_angle4, unsigned int * timestamp);
    00718 //   4(0x04)
    00719  /*****************AutoGenerated*************/
    00730 TSS_EXPORT TSS_Error tss_getTaredOrientationAsTwoVector(TSS_Device_Id device, float * forward3, float * down3, unsigned int * timestamp);
    00731 //   5(0x05)
    00732  /*****************AutoGenerated*************/
    00743 TSS_EXPORT TSS_Error tss_getDifferenceQuaternion(TSS_Device_Id device, float * quat4, unsigned int * timestamp);
    00744 //   6(0x06)
    00745  /*****************AutoGenerated*************/
    00756 TSS_EXPORT TSS_Error tss_getUntaredOrientationAsQuaternion(TSS_Device_Id device, float * quat4, unsigned int * timestamp);
    00757 //   7(0x07)
    00758  /*****************AutoGenerated*************/
    00769 TSS_EXPORT TSS_Error tss_getUntaredOrientationAsEulerAngles(TSS_Device_Id device, float * euler3, unsigned int * timestamp);
    00770 //   8(0x08)
    00771  /*****************AutoGenerated*************/
    00782 TSS_EXPORT TSS_Error tss_getUntaredOrientationAsRotationMatrix(TSS_Device_Id device, float * matrix9, unsigned int * timestamp);
    00783 //   9(0x09)
    00784  /*****************AutoGenerated*************/
    00795 TSS_EXPORT TSS_Error tss_getUntaredOrientationAsAxisAngle(TSS_Device_Id device, float * axis_angle4, unsigned int * timestamp);
    00796 //  10(0x0a)
    00797  /*****************AutoGenerated*************/
    00808 TSS_EXPORT TSS_Error tss_getUntaredOrientationAsTwoVector(TSS_Device_Id device, float * north3, float * gravity3, unsigned int * timestamp);
    00809 //  11(0x0b)
    00810  /*****************AutoGenerated*************/
    00821 TSS_EXPORT TSS_Error tss_getTaredTwoVectorInSensorFrame(TSS_Device_Id device, float * forward3, float * down3, unsigned int * timestamp);
    00822 //  12(0x0c)
    00823  /*****************AutoGenerated*************/
    00834 TSS_EXPORT TSS_Error tss_getUntaredTwoVectorInSensorFrame(TSS_Device_Id device, float * north3, float * gravity3, unsigned int * timestamp);
    00835
    00836 //Embedded Commands
    00837 //  29(0x1d)
    00838  /*****************AutoGenerated*************/
    00849 TSS_EXPORT TSS_Error tss_setInterruptType(TSS_Device_Id device, unsigned char mode, unsigned char pin, unsigned int * timestamp);
    00850 //  30(0x1e)
    00851  /*****************AutoGenerated*************/
    00862 TSS_EXPORT TSS_Error tss_getInterruptType(TSS_Device_Id device, unsigned char * mode, unsigned char * pin, unsigned int * timestamp);
    00863 //  31(0x1f)
    00864  /*****************AutoGenerated*************/
    00875 TSS_EXPORT TSS_Error tss_getInterruptStatus(TSS_Device_Id device, unsigned char * status, unsigned int * timestamp);
    00876
    00877 //Normalized Data Commands
    00878 //  32(0x20)
    00879  /*****************AutoGenerated*************/
    00890 TSS_EXPORT TSS_Error tss_getAllNormalizedComponentSensorData(TSS_Device_Id device, float * gyro_rate3, float * gravity_direction3, float * north_direction3, unsigned int * timestamp);
    00891 //  33(0x21)
    00892  /*****************AutoGenerated*************/
    00903 TSS_EXPORT TSS_Error tss_getNormalizedGyroRate(TSS_Device_Id device, float * gyro_rate3, unsigned int * timestamp);
    00904 //  34(0x22)
    00905  /*****************AutoGenerated*************/
    00916 TSS_EXPORT TSS_Error tss_getNormalizedAccelerometerVector(TSS_Device_Id device, float * gravity_direction3, unsigned int * timestamp);
    00917 //  35(0x23)
    00918  /*****************AutoGenerated*************/
    00929 TSS_EXPORT TSS_Error tss_getNormalizedCompassVector(TSS_Device_Id device, float * north_direction3, unsigned int * timestamp);
    00930
    00931 //Corrected Data Commands
    00932 //  37(0x25)
    00933  /*****************AutoGenerated*************/
    00944 TSS_EXPORT TSS_Error tss_getAllCorrectedComponentSensorData(TSS_Device_Id device, float * gyro_rate3, float * accelerometer3, float * compass3, unsigned int * timestamp);
    00945 //  38(0x26)
    00946  /*****************AutoGenerated*************/
    00957 TSS_EXPORT TSS_Error tss_getCorrectedGyroRate(TSS_Device_Id device, float * gyro_rate3, unsigned int * timestamp);
    00958 //  39(0x27)
    00959  /*****************AutoGenerated*************/
    00970 TSS_EXPORT TSS_Error tss_getCorrectedAccelerometerVector(TSS_Device_Id device, float * accelerometer3, unsigned int * timestamp);
    00971 //  40(0x28)
    00972  /*****************AutoGenerated*************/
    00983 TSS_EXPORT TSS_Error tss_getCorrectedCompassVector(TSS_Device_Id device, float * compass3, unsigned int * timestamp);
    00984 //  41(0x29)
    00985  /*****************AutoGenerated*************/
    00996 TSS_EXPORT TSS_Error tss_getCorrectedLinearAccelerationInGlobalSpace(TSS_Device_Id device, float * accelerometer3, unsigned int * timestamp);
    00997
    00998 //Other Data Commands
    00999 //  43(0x2b)
    01000  /*****************AutoGenerated*************/
    01011 TSS_EXPORT TSS_Error tss_getTemperatureC(TSS_Device_Id device, float * temperature, unsigned int * timestamp);
    01012 //  44(0x2c)
    01013  /*****************AutoGenerated*************/
    01024 TSS_EXPORT TSS_Error tss_getTemperatureF(TSS_Device_Id device, float * temperature, unsigned int * timestamp);
    01025 //  45(0x2d)
    01026  /*****************AutoGenerated*************/
    01037 TSS_EXPORT TSS_Error tss_getConfidenceFactor(TSS_Device_Id device, float * confidence, unsigned int * timestamp);
    01038
    01039 //Data-Logging Commands
    01040 //  57(0x39)
    01041  /*****************AutoGenerated*************/
    01052 TSS_EXPORT TSS_Error tss_turnOnMassStorage(TSS_Device_Id device, unsigned int * timestamp);
    01053 //  58(0x3a)
    01054  /*****************AutoGenerated*************/
    01065 TSS_EXPORT TSS_Error tss_turnOffMassStorage(TSS_Device_Id device, unsigned int * timestamp);
    01066 //  59(0x3b)
    01067  /*****************AutoGenerated*************/
    01078 TSS_EXPORT TSS_Error tss_formatAndInitializeSDCard(TSS_Device_Id device, unsigned int * timestamp);
    01079 //  60(0x3c)
    01080  /*****************AutoGenerated*************/
    01091 TSS_EXPORT TSS_Error tss_beginDataLoggingSession(TSS_Device_Id device, unsigned int * timestamp);
    01092 //  61(0x3d)
    01093  /*****************AutoGenerated*************/
    01104 TSS_EXPORT TSS_Error tss_endDataLoggingSession(TSS_Device_Id device, unsigned int * timestamp);
    01105 //  62(0x3e)
    01106  /*****************AutoGenerated*************/
    01117 TSS_EXPORT TSS_Error tss_setClockValues(TSS_Device_Id device,   unsigned char month,
    01118                                                                 unsigned char day,
    01119                                                                 unsigned char year,
    01120                                                                 unsigned char hour,
    01121                                                                 unsigned char minute,
    01122                                                                 unsigned char second,
    01123                                                                 unsigned int * timestamp);
    01124 //  63(0x3f)
    01125  /*****************AutoGenerated*************/
    01136 TSS_EXPORT TSS_Error tss_getClockValues(TSS_Device_Id device,    unsigned char * month,
    01137                                                                 unsigned char * day,
    01138                                                                 unsigned char * year,
    01139                                                                 unsigned char * hour,
    01140                                                                 unsigned char * minute,
    01141                                                                 unsigned char * second,
    01142                                                                 unsigned int * timestamp);
    01143
    01144 //Raw Data Commands
    01145 //  64(0x40)
    01146  /*****************AutoGenerated*************/
    01157 TSS_EXPORT TSS_Error tss_getAllRawComponentSensorData(TSS_Device_Id device, float * gyro_rate3, float * accelerometer3, float * compass3, unsigned int * timestamp);
    01158 //  65(0x41)
    01159  /*****************AutoGenerated*************/
    01170 TSS_EXPORT TSS_Error tss_getRawGyroscopeRate(TSS_Device_Id device, float * gyro_rate3, unsigned int * timestamp);
    01171 //  66(0x42)
    01172  /*****************AutoGenerated*************/
    01183 TSS_EXPORT TSS_Error tss_getRawAccelerometerData(TSS_Device_Id device, float * accelerometer3, unsigned int * timestamp);
    01184 //  67(0x43)
    01185  /*****************AutoGenerated*************/
    01196 TSS_EXPORT TSS_Error tss_getRawCompassData(TSS_Device_Id device, float * compass3, unsigned int * timestamp);
    01197
    01198 //Streaming Commands
    01199 //  80(0x50)
    01200  /*****************AutoGenerated*************/
    01211 TSS_EXPORT TSS_Error tss_setStreamingSlots(TSS_Device_Id device, const TSS_Stream_Command * slots8, unsigned int * timestamp);
    01212 //  81(0x51)
    01213  /*****************AutoGenerated*************/
    01224 TSS_EXPORT TSS_Error tss_getStreamingSlots(TSS_Device_Id device, TSS_Stream_Command * slots8, unsigned int * timestamp);
    01225 //  82(0x52)
    01226  /*****************AutoGenerated*************/
    01237 TSS_EXPORT TSS_Error tss_setStreamingTiming(TSS_Device_Id device, unsigned int interval, unsigned int duration, unsigned int delay, unsigned int * timestamp);
    01238 //  83(0x53)
    01239  /*****************AutoGenerated*************/
    01250 TSS_EXPORT TSS_Error tss_getStreamingTiming(TSS_Device_Id device, unsigned int * interval, unsigned int * duration, unsigned int * delay, unsigned int * timestamp);
    01251 //  84(0x54)
    01252  /*****************AutoGenerated*************/
    01263 TSS_EXPORT TSS_Error tss_getStreamingBatch(TSS_Device_Id device, char * output_data, unsigned int output_data_len, unsigned int * timestamp);
    01264 //  85(0x55)
    01265  /*****************AutoGenerated*************/
    01276 TSS_EXPORT TSS_Error tss_startStreaming(TSS_Device_Id device, unsigned int * timestamp);
    01277 //  86(0x56)
    01278  /*****************AutoGenerated*************/
    01289 TSS_EXPORT TSS_Error tss_stopStreaming(TSS_Device_Id device, unsigned int * timestamp);
    01290 //  95(0x5f)
    01291  /*****************AutoGenerated*************/
    01302 TSS_EXPORT TSS_Error tss_updateCurrentTimestamp(TSS_Device_Id device, unsigned int set_timestamp, unsigned int * timestamp);
    01303
    01304 //Configuration Write Commands
    01305 //  16(0x10)
    01306  /*****************AutoGenerated*************/
    01317 TSS_EXPORT TSS_Error tss_setEulerAngleDecompositionOrder(TSS_Device_Id device, unsigned char order, unsigned int * timestamp);
    01318 //  17(0x11)
    01319  /*****************AutoGenerated*************/
    01330 TSS_EXPORT TSS_Error tss_setMagnetoresistiveThreshold(TSS_Device_Id device, float threshold, unsigned int trust_frames, float lockout_decay, float perturbation_detection_value, unsigned int * timestamp);
    01331 //  18(0x12)
    01332  /*****************AutoGenerated*************/
    01343 TSS_EXPORT TSS_Error tss_setAccelerometerResistanceThreshold(TSS_Device_Id device, float threshold, unsigned int lockout_frames, unsigned int * timestamp);
    01344 //  19(0x13)
    01345  /*****************AutoGenerated*************/
    01356 TSS_EXPORT TSS_Error tss_offsetWithCurrentOrientation(TSS_Device_Id device, unsigned int * timestamp);
    01357 //  20(0x14)
    01358  /*****************AutoGenerated*************/
    01369 TSS_EXPORT TSS_Error tss_resetBaseOffset(TSS_Device_Id device, unsigned int * timestamp);
    01370 //  21(0x15)
    01371  /*****************AutoGenerated*************/
    01382 TSS_EXPORT TSS_Error tss_offsetWithQuaternion(TSS_Device_Id device, const float * quat4, unsigned int * timestamp);
    01383 //  22(0x16)
    01384  /*****************AutoGenerated*************/
    01395 TSS_EXPORT TSS_Error tss_setBaseOffsetWithCurrentOrientation(TSS_Device_Id device, unsigned int * timestamp);
    01396 //  96(0x60)
    01397  /*****************AutoGenerated*************/
    01408 TSS_EXPORT TSS_Error tss_tareWithCurrentOrientation(TSS_Device_Id device, unsigned int * timestamp);
    01409 //  97(0x61)
    01410  /*****************AutoGenerated*************/
    01421 TSS_EXPORT TSS_Error tss_tareWithQuaternion(TSS_Device_Id device, const float * quat4, unsigned int * timestamp);
    01422 //  98(0x62)
    01423  /*****************AutoGenerated*************/
    01434 TSS_EXPORT TSS_Error tss_tareWithRotationMatrix(TSS_Device_Id device, const float * matrix9, unsigned int * timestamp);
    01435 //  99(0x63)
    01436  /*****************AutoGenerated*************/
    01447 //TSS_EXPORT TSS_Error tss_setStaticAccelerometerRhoMode(TSS_Device_Id device, float rho_value, unsigned int * timestamp);
    01448 TSS_EXPORT TSS_Error tss_setStaticAccelerometerTrustValue(TSS_Device_Id device, float trust_value, unsigned int * timestamp);
    01449 // 100(0x64)
    01450  /*****************AutoGenerated*************/
    01461 //TSS_EXPORT TSS_Error tss_setConfidenceAccelerometerRhoMode(TSS_Device_Id device, float min_rho_value, float max_rho_value, unsigned int * timestamp);
    01462 TSS_EXPORT TSS_Error tss_setConfidenceAccelerometerTrustValues(TSS_Device_Id device, float min_trust_value, float max_trust_value, unsigned int * timestamp);
    01463 // 101(0x65)
    01464  /*****************AutoGenerated*************/
    01475 //TSS_EXPORT TSS_Error tss_setStaticCompassRhoMode(TSS_Device_Id device, float rho_value, unsigned int * timestamp);
    01476 TSS_EXPORT TSS_Error tss_setStaticCompassTrustValue(TSS_Device_Id device, float trust_value, unsigned int * timestamp);
    01477 // 102(0x66)
    01478  /*****************AutoGenerated*************/
    01489 //TSS_EXPORT TSS_Error tss_setConfidenceCompassRhoMode(TSS_Device_Id device, float min_rho_value, float max_rho_value, unsigned int * timestamp);
    01490 TSS_EXPORT TSS_Error tss_setConfidenceCompassTrustValues(TSS_Device_Id device, float min_trust_value, float max_trust_value, unsigned int * timestamp);
    01491 // 103(0x67)
    01492  /*****************AutoGenerated*************/
    01503 TSS_EXPORT TSS_Error tss_setDesiredUpdateRate(TSS_Device_Id device, unsigned int update_rate, unsigned int * timestamp);
    01504 // 105(0x69)
    01505  /*****************AutoGenerated*************/
    01516 TSS_EXPORT TSS_Error tss_setReferenceVectorMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    01517 // 106(0x6a)
    01518  /*****************AutoGenerated*************/
    01529 TSS_EXPORT TSS_Error tss_setOversampleRate(TSS_Device_Id device, unsigned char samples_per_iteration, unsigned int * timestamp);
    01530 // 107(0x6b)
    01531  /*****************AutoGenerated*************/
    01542 TSS_EXPORT TSS_Error tss_setGyroscopeEnabled(TSS_Device_Id device, unsigned char enabled, unsigned int * timestamp);
    01543 // 108(0x6c)
    01544  /*****************AutoGenerated*************/
    01555 TSS_EXPORT TSS_Error tss_setAccelerometerEnabled(TSS_Device_Id device, unsigned char enabled, unsigned int * timestamp);
    01556 // 109(0x6d)
    01557  /*****************AutoGenerated*************/
    01568 TSS_EXPORT TSS_Error tss_setCompassEnabled(TSS_Device_Id device, unsigned char enabled, unsigned int * timestamp);
    01569 // 116(0x74)
    01570  /*****************AutoGenerated*************/
    01581 TSS_EXPORT TSS_Error tss_setAxisDirections(TSS_Device_Id device, unsigned char axis_direction_byte, unsigned int * timestamp);
    01582 // 117(0x75)
    01583  /*****************AutoGenerated*************/
    01594 TSS_EXPORT TSS_Error tss_setRunningAveragePercent(TSS_Device_Id device, float running_average_percent, unsigned int * timestamp);
    01595 // 118(0x76)
    01596  /*****************AutoGenerated*************/
    01607 TSS_EXPORT TSS_Error tss_setCompassReferenceVector(TSS_Device_Id device, const float * reference_vector3, unsigned int * timestamp);
    01608 // 119(0x77)
    01609  /*****************AutoGenerated*************/
    01620 TSS_EXPORT TSS_Error tss_setAccelerometerReferenceVector(TSS_Device_Id device, const float * reference_vector3, unsigned int * timestamp);
    01621 // 120(0x78)
    01622  /*****************AutoGenerated*************/
    01633 TSS_EXPORT TSS_Error tss_resetKalmanFilter(TSS_Device_Id device, unsigned int * timestamp);
    01634 // 121(0x79)
    01635  /*****************AutoGenerated*************/
    01646 TSS_EXPORT TSS_Error tss_setAccelerometerRange(TSS_Device_Id device, unsigned char accelerometer_range_setting, unsigned int * timestamp);
    01647 // 123(0x7b)
    01648  /*****************AutoGenerated*************/
    01659 TSS_EXPORT TSS_Error tss_setFilterMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    01660 // 124(0x7c)
    01661  /*****************AutoGenerated*************/
    01672 TSS_EXPORT TSS_Error tss_setRunningAverageMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    01673 // 125(0x7d)
    01674  /*****************AutoGenerated*************/
    01685 TSS_EXPORT TSS_Error tss_setGyroscopeRange(TSS_Device_Id device, unsigned char gyroscope_range_setting, unsigned int * timestamp);
    01686 // 126(0x7e)
    01687  /*****************AutoGenerated*************/
    01698 TSS_EXPORT TSS_Error tss_setCompassRange(TSS_Device_Id device, unsigned char compass_range_setting, unsigned int * timestamp);
    01699
    01700 // Configuration Read Commands
    01701 // 128(0x80)  Get tare orientation as quaternion
    01702  /*****************AutoGenerated*************/
    01713 TSS_EXPORT TSS_Error tss_getTareAsQuaternion(TSS_Device_Id device, float * quat4, unsigned int * timestamp);
    01714 // 129(0x81)  Get tare orientation as rotation matrix
    01715  /*****************AutoGenerated*************/
    01726 TSS_EXPORT TSS_Error tss_getTareAsRotationMatrix(TSS_Device_Id device, float * matrix9, unsigned int * timestamp);
    01727 // 130(0x82)
    01728  /*****************AutoGenerated*************/
    01739 //TSS_EXPORT TSS_Error tss_getAccelerometerRhoValue(TSS_Device_Id device, unsigned char * rho_mode, float * rho_min, float * rho_max, unsigned int * timestamp);
    01740 TSS_EXPORT TSS_Error tss_getAccelerometerTrustValues(TSS_Device_Id device, float * min_trust_value, float * max_trust_value, unsigned int * timestamp);
    01741 // 131(0x83)
    01742  /*****************AutoGenerated*************/
    01753 //TSS_EXPORT TSS_Error tss_getCompassRhoValue(TSS_Device_Id device, unsigned char * rho_mode, float * rho_min, float * rho_max, unsigned int * timestamp);
    01754 TSS_EXPORT TSS_Error tss_getCompassTrustValues(TSS_Device_Id device, float * min_trust_value, float * max_trust_value, unsigned int * timestamp);
    01755 // 132(0x84)
    01756  /*****************AutoGenerated*************/
    01767 TSS_EXPORT TSS_Error tss_getCurrentUpdateRate(TSS_Device_Id device, unsigned int * last_update, unsigned int * timestamp);
    01768 // 133(0x85)
    01769  /*****************AutoGenerated*************/
    01780 TSS_EXPORT TSS_Error tss_getCompassReferenceVector(TSS_Device_Id device, float * reference_vector, unsigned int * timestamp);
    01781 // 134(0x86)
    01782  /*****************AutoGenerated*************/
    01793 TSS_EXPORT TSS_Error tss_getAccelerometerReferenceVector(TSS_Device_Id device, float * reference_vector, unsigned int * timestamp);
    01794 // 135(0x87)
    01795  /*****************AutoGenerated*************/
    01806 TSS_EXPORT TSS_Error tss_getReferenceVectorMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    01807 // 140(0x8c)
    01808  /*****************AutoGenerated*************/
    01819 TSS_EXPORT TSS_Error tss_getGyroscopeEnabledState(TSS_Device_Id device, unsigned char * enabled, unsigned int * timestamp);
    01820 // 141(0x8d)
    01821  /*****************AutoGenerated*************/
    01832 TSS_EXPORT TSS_Error tss_getAccelerometerEnabledState(TSS_Device_Id device, unsigned char * enabled, unsigned int * timestamp);
    01833 // 142(0x8e)
    01834  /*****************AutoGenerated*************/
    01845 TSS_EXPORT TSS_Error tss_getCompassEnabledState(TSS_Device_Id device, unsigned char * enabled, unsigned int * timestamp);
    01846 // 143(0x8f)
    01847  /*****************AutoGenerated*************/
    01858 TSS_EXPORT TSS_Error tss_getAxisDirections(TSS_Device_Id device, unsigned char * axis_directions, unsigned int * timestamp);
    01859 // 144(0x90)
    01860  /*****************AutoGenerated*************/
    01871 TSS_EXPORT TSS_Error tss_getOversampleRate(TSS_Device_Id device, unsigned char * oversample_rate, unsigned int * timestamp);
    01872 // 145(0x91)
    01873  /*****************AutoGenerated*************/
    01884 TSS_EXPORT TSS_Error tss_getRunningAveragePercent(TSS_Device_Id device, float * running_average_percent, unsigned int * timestamp);
    01885 // 146(0x92)
    01886  /*****************AutoGenerated*************/
    01897 TSS_EXPORT TSS_Error tss_getDesiredUpdateRate(TSS_Device_Id device, unsigned int * update_rate, unsigned int * timestamp);
    01898 // 148(0x94)
    01899  /*****************AutoGenerated*************/
    01910 TSS_EXPORT TSS_Error tss_getAccelerometerRange(TSS_Device_Id device, unsigned char * accelerometer_range_setting, unsigned int * timestamp);
    01911 // 152(0x98)
    01912  /*****************AutoGenerated*************/
    01923 TSS_EXPORT TSS_Error tss_getFilterMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    01924 // 153(0x99)
    01925  /*****************AutoGenerated*************/
    01936 TSS_EXPORT TSS_Error tss_getRunningAverageMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    01937 // 154(0x9a)
    01938  /*****************AutoGenerated*************/
    01949 TSS_EXPORT TSS_Error tss_getGyroscopeRange(TSS_Device_Id device, unsigned char * gyroscope_range_setting, unsigned int * timestamp);
    01950 // 155(0x9b)
    01951  /*****************AutoGenerated*************/
    01962 TSS_EXPORT TSS_Error tss_getCompassRange(TSS_Device_Id device, unsigned char * compass_range_setting, unsigned int * timestamp);
    01963 // 156(0x9c)
    01964  /*****************AutoGenerated*************/
    01975 TSS_EXPORT TSS_Error tss_getEulerAngleDecompositionOrder(TSS_Device_Id device, unsigned char * order, unsigned int * timestamp);
    01976 // 157(0x9d)
    01977  /*****************AutoGenerated*************/
    01988 TSS_EXPORT TSS_Error tss_getMagnetoresistiveThreshold(TSS_Device_Id device, float * threshold, unsigned int * trust_frames, float * lockout_decay, float * perturbation_detection_value, unsigned int * timestamp);
    01989 // 158(0x9e)
    01990  /*****************AutoGenerated*************/
    02001 TSS_EXPORT TSS_Error tss_getAccelerometerResistanceThreshold(TSS_Device_Id device, float * threshold, unsigned int * lockout_frames, unsigned int * timestamp);
    02002 // 159(0x9f)
    02003  /*****************AutoGenerated*************/
    02014 TSS_EXPORT TSS_Error tss_getOffsetOrientationAsQuaternion(TSS_Device_Id device, float * quat4, unsigned int * timestamp);
    02015
    02016 //Calibration Commands
    02017 // 160(0xa0)
    02018  /*****************AutoGenerated*************/
    02029 TSS_EXPORT TSS_Error tss_setCompassCalibrationCoefficients(TSS_Device_Id device, const float * matrix9, const float * bias3, unsigned int * timestamp);
    02030 // 161(0xa1)
    02031  /*****************AutoGenerated*************/
    02042 TSS_EXPORT TSS_Error tss_setAccelerometerCalibrationCoefficients(TSS_Device_Id device,const float * matrix9, const float * bias3, unsigned int * timestamp);
    02043 // 162(0xa2)
    02044  /*****************AutoGenerated*************/
    02055 TSS_EXPORT TSS_Error tss_getCompassCalibrationCoefficients(TSS_Device_Id device, float * matrix9, float * bias3, unsigned int * timestamp);
    02056 // 163(0xa3)
    02057  /*****************AutoGenerated*************/
    02068 TSS_EXPORT TSS_Error tss_getAccelerometerCalibrationCoefficients(TSS_Device_Id device, float * matrix9, float * bias3, unsigned int * timestamp);
    02069 // 164(0xa4)
    02070  /*****************AutoGenerated*************/
    02081 TSS_EXPORT TSS_Error tss_getGyroscopeCalibrationCoefficients(TSS_Device_Id device, float * matrix9, float * bias3, unsigned int * timestamp);
    02082 // 165(0xa5)
    02083  /*****************AutoGenerated*************/
    02094 TSS_EXPORT TSS_Error tss_beginGyroscopeAutoCalibration(TSS_Device_Id device, unsigned int * timestamp);
    02095 // 166(0xa6)
    02096  /*****************AutoGenerated*************/
    02107 TSS_EXPORT TSS_Error tss_setGyroscopeCalibrationCoefficients(TSS_Device_Id device, const float * matrix9, const float * bias3, unsigned int * timestamp);
    02108 // 169(0xa9)
    02109  /*****************AutoGenerated*************/
    02120 TSS_EXPORT TSS_Error tss_setCalibrationMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    02121 // 170(0xaa)
    02122  /*****************AutoGenerated*************/
    02133 TSS_EXPORT TSS_Error tss_getCalibrationMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    02134 // 171(0xab)
    02135  /*****************AutoGenerated*************/
    02146 TSS_EXPORT TSS_Error tss_setOrthoCalibrationDataPointFromCurrentOrientation(TSS_Device_Id device, unsigned int * timestamp);
    02147 // 172(0xac)
    02148  /*****************AutoGenerated*************/
    02159 TSS_EXPORT TSS_Error tss_setOrthoCalibrationDataPointFromVector(TSS_Device_Id device, unsigned char type, unsigned char index, const float * vector3, unsigned int * timestamp);
    02160 // 173(0xad)
    02161  /*****************AutoGenerated*************/
    02172 TSS_EXPORT TSS_Error tss_getOrthoCalibrationDataPoint(TSS_Device_Id device, unsigned char type, unsigned char index, float * vector3, unsigned int * timestamp);
    02173 // 174(0xae)
    02174  /*****************AutoGenerated*************/
    02185 TSS_EXPORT TSS_Error tss_performOrthoCalibration(TSS_Device_Id device, unsigned int * timestamp);
    02186 // 175(0xaf)
    02187  /*****************AutoGenerated*************/
    02198 TSS_EXPORT TSS_Error tss_clearOrthoCalibrationData(TSS_Device_Id device, unsigned int * timestamp);
    02199
    02200 //Dongle Commands
    02201 // 176(0xb0)
    02202  /*****************AutoGenerated*************/
    02213 TSS_EXPORT TSS_Error tss_setWirelessStreamingAutoFlushMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    02214 // 177(0xb1)
    02215  /*****************AutoGenerated*************/
    02226 TSS_EXPORT TSS_Error tss_getWirelessStreamingAutoFlushMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    02227 // 178(0xb2)
    02228  /*****************AutoGenerated*************/
    02239 TSS_EXPORT TSS_Error tss_setWirelessStreamingManualFlushBitfield(TSS_Device_Id device, unsigned short manual_flush_bitfield, unsigned int * timestamp);
    02240 // 179(0xb3)
    02241  /*****************AutoGenerated*************/
    02252 TSS_EXPORT TSS_Error tss_getWirelessStreamingManualFlushBitfield(TSS_Device_Id device, unsigned short * manual_flush_bitfield, unsigned int * timestamp);
    02253 // 180(0xb4)
    02254  /*****************AutoGenerated*************/
    02265 TSS_EXPORT TSS_Error tss_getManualFlushSingle(TSS_Device_Id device, unsigned char index, char * data, int in_data_size, int * out_data_size, unsigned int * timestamp);
    02266 // 181(0xb5)
    02267  /*****************AutoGenerated*************/
    02278 TSS_EXPORT TSS_Error tss_getManualFlushBulk(TSS_Device_Id device, char * data, int in_data_size, int * out_data_size, unsigned int * timestamp);
    02279 // 182(0xb6)
    02280  /*****************AutoGenerated*************/
    02291 TSS_EXPORT TSS_Error tss_broadcastSynchronizationPulse(TSS_Device_Id device, unsigned int * timestamp);
    02292 // 208(0xd0)
    02293  /*****************AutoGenerated*************/
    02304 TSS_EXPORT TSS_Error tss_getSerialNumberAtLogicalID(TSS_Device_Id device, unsigned char logical_id, unsigned int * serial_number, unsigned int * timestamp);
    02305 // 209(0xd1)
    02306  /*****************AutoGenerated*************/
    02317 TSS_EXPORT TSS_Error tss_setSerialNumberAtLogicalID(TSS_Device_Id device, unsigned char logical_id, unsigned int serial_number, unsigned int * timestamp);
    02318 // 210(0xd2)
    02319  /*****************AutoGenerated*************/
    02330 TSS_EXPORT TSS_Error tss_getWirelessChannelNoiseLevels(TSS_Device_Id device, unsigned char * channel_strengths16, unsigned int * timestamp);
    02331 // 211(0xd3)
    02332  /*****************AutoGenerated*************/
    02343 TSS_EXPORT TSS_Error tss_setWirelessRetries(TSS_Device_Id device, unsigned char retries, unsigned int * timestamp);
    02344 // 212(0xd4)
    02345  /*****************AutoGenerated*************/
    02356 TSS_EXPORT TSS_Error tss_getWirelessRetries(TSS_Device_Id device, unsigned char * retries, unsigned int * timestamp);
    02357 // 213(0xd5)
    02358  /*****************AutoGenerated*************/
    02369 TSS_EXPORT TSS_Error tss_getWirelessSlotsOpen(TSS_Device_Id device, unsigned char * slots_open, unsigned int * timestamp);
    02370 // 214(0xd6)
    02371  /*****************AutoGenerated*************/
    02382 TSS_EXPORT TSS_Error tss_getSignalStrength(TSS_Device_Id device, unsigned char * last_packet_signal_strength, unsigned int * timestamp);
    02383 // 219(0xdb)
    02384  /*****************AutoGenerated*************/
    02395 TSS_EXPORT TSS_Error tss_setWirelessResponseHeaderBitfield(TSS_Device_Id device, unsigned int header_bitfield, unsigned int * timestamp);
    02396 // 220(0xdc)
    02397  /*****************AutoGenerated*************/
    02408 TSS_EXPORT TSS_Error tss_getWirelessResponseHeaderBitfield(TSS_Device_Id device, unsigned int * header_bitfield, unsigned int * timestamp);
    02409
    02410 //Wireless Sensor & Dongle Commands
    02411 // 192(0xc0)
    02412  /*****************AutoGenerated*************/
    02423 TSS_EXPORT TSS_Error tss_getWirelessPanID(TSS_Device_Id device, unsigned short * pan_id, unsigned int * timestamp);
    02424 // 193(0xc1)
    02425  /*****************AutoGenerated*************/
    02436 TSS_EXPORT TSS_Error tss_setWirelessPanID(TSS_Device_Id device, unsigned short pan_id, unsigned int * timestamp);
    02437 // 194(0xc2)
    02438  /*****************AutoGenerated*************/
    02449 TSS_EXPORT TSS_Error tss_getWirelessChannel(TSS_Device_Id device, unsigned char * channel, unsigned int * timestamp);
    02450 // 195(0xc3)
    02451  /*****************AutoGenerated*************/
    02462 TSS_EXPORT TSS_Error tss_setWirelessChannel(TSS_Device_Id device, unsigned char channel, unsigned int * timestamp);
    02463 // 197(0xc5)
    02464  /*****************AutoGenerated*************/
    02475 TSS_EXPORT TSS_Error tss_commitWirelessSettings(TSS_Device_Id device, unsigned int * timestamp);
    02476 // 198(0xc6)
    02477  /*****************AutoGenerated*************/
    02488 TSS_EXPORT TSS_Error tss_getWirelessAddress(TSS_Device_Id device, unsigned short * address, unsigned int * timestamp);
    02489
    02490 //Battery Commands
    02491 // 201(0xc9)
    02492  /*****************AutoGenerated*************/
    02503 TSS_EXPORT TSS_Error tss_getBatteryVoltage(TSS_Device_Id device, float * battery_voltage, unsigned int * timestamp);
    02504 // 202(0xca)
    02505  /*****************AutoGenerated*************/
    02516 TSS_EXPORT TSS_Error tss_getBatteryPercentRemaining(TSS_Device_Id device, unsigned char * battery_percent, unsigned int * timestamp);
    02517 // 203(0xcb)
    02518  /*****************AutoGenerated*************/
    02529 TSS_EXPORT TSS_Error tss_getBatteryStatus(TSS_Device_Id device, unsigned char * battery_charge_status, unsigned int * timestamp);
    02530
    02531 //General Commands
    02532 // 196(0xc4)
    02533  /*****************AutoGenerated*************/
    02544 TSS_EXPORT TSS_Error tss_setLEDMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    02545 // 200(0xc8)
    02546  /*****************AutoGenerated*************/
    02557 TSS_EXPORT TSS_Error tss_getLEDMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    02558 // 221(0xdd)
    02559  /*****************AutoGenerated*************/
    02570 TSS_EXPORT TSS_Error tss_setWiredResponseHeaderBitfield(TSS_Device_Id device, unsigned int header_bitfield, unsigned int * timestamp);
    02571 // 222(0xde)
    02572  /*****************AutoGenerated*************/
    02583 TSS_EXPORT TSS_Error tss_getWiredResponseHeaderBitfield(TSS_Device_Id device, unsigned int * header_bitfield, unsigned int * timestamp);
    02584 // 223(0xdf) note: adds null terminator
    02585  /*****************AutoGenerated*************/
    02596 TSS_EXPORT TSS_Error tss_getFirmwareVersionString(TSS_Device_Id device, char * firmware_version13, unsigned int * timestamp);
    02597 // 224(0xe0)
    02598  /*****************AutoGenerated*************/
    02609 TSS_EXPORT TSS_Error tss_restoreFactorySettings(TSS_Device_Id device, unsigned int * timestamp);
    02610 // 225(0xe1)
    02611  /*****************AutoGenerated*************/
    02622 TSS_EXPORT TSS_Error tss_commitSettings(TSS_Device_Id device, unsigned int * timestamp);
    02623 // 226(0xe2)
    02624  /*****************AutoGenerated*************/
    02635 TSS_EXPORT TSS_Error tss_softwareReset(TSS_Device_Id device, unsigned int * timestamp);
    02636 // 227(0xe3)
    02637  /*****************AutoGenerated*************/
    02648 TSS_EXPORT TSS_Error tss_setSleepMode(TSS_Device_Id device,unsigned char mode, unsigned int * timestamp);
    02649 // 228(0xe4)
    02650  /*****************AutoGenerated*************/
    02661 TSS_EXPORT TSS_Error tss_getSleepMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    02662 // 229(0xe5)
    02663  /*****************AutoGenerated*************/
    02674 TSS_EXPORT TSS_Error tss_enterBootloaderMode(TSS_Device_Id device, unsigned int * timestamp);
    02675 // 230(0xe6) note: adds null terminator
    02676  /*****************AutoGenerated*************/
    02687 TSS_EXPORT TSS_Error tss_getHardwareVersionString(TSS_Device_Id device, char * hardware_version33, unsigned int * timestamp);
    02688 // 231(0xe7)
    02689  /*****************AutoGenerated*************/
    02700 TSS_EXPORT TSS_Error tss_setUARTBaudRate(TSS_Device_Id device, unsigned int baud_rate, unsigned int * timestamp);
    02701 // 232(0xe8)
    02702  /*****************AutoGenerated*************/
    02713 TSS_EXPORT TSS_Error tss_getUARTBaudRate(TSS_Device_Id device, unsigned int * baud_rate, unsigned int * timestamp);
    02714 // 233(0xe9)
    02715  /*****************AutoGenerated*************/
    02726 TSS_EXPORT TSS_Error tss_setUSBMode(TSS_Device_Id device, unsigned int mode, unsigned int * timestamp);
    02727 // 234(0xea)
    02728  /*****************AutoGenerated*************/
    02739 TSS_EXPORT TSS_Error tss_getUSBMode(TSS_Device_Id device, unsigned int * mode, unsigned int * timestamp);
    02740 // 237(0xed)
    02741  /*****************AutoGenerated*************/
    02752 TSS_EXPORT TSS_Error tss_getSerialNumber(TSS_Device_Id device, unsigned int * serial_number, unsigned int * timestamp);
    02753 // 238(0xee)
    02754  /*****************AutoGenerated*************/
    02765 TSS_EXPORT TSS_Error tss_setLEDColor(TSS_Device_Id device,const float * rgb_color3, unsigned int * timestamp);
    02766 // 239(0xef)
    02767  /*****************AutoGenerated*************/
    02778 TSS_EXPORT TSS_Error tss_getLEDColor(TSS_Device_Id device, float * rgb_color3, unsigned int * timestamp);
    02779
    02780 //Wireless HID Commands
    02781 // 215(0xd7)
    02782  /*****************AutoGenerated*************/
    02793 TSS_EXPORT TSS_Error tss_setWirelessHIDUpdateRate(TSS_Device_Id device, unsigned char HID_update_rate, unsigned int * timestamp);
    02794 // 216(0xd8)
    02795  /*****************AutoGenerated*************/
    02806 TSS_EXPORT TSS_Error tss_getWirelessHIDUpdateRate(TSS_Device_Id device, unsigned char * HID_update_rate, unsigned int * timestamp);
    02807 // 217(0xd9)
    02808  /*****************AutoGenerated*************/
    02819 TSS_EXPORT TSS_Error tss_setWirelessHIDAsynchronousMode(TSS_Device_Id device, unsigned char HID_communication_mode , unsigned int * timestamp);
    02820 // 218(0xda)
    02821  /*****************AutoGenerated*************/
    02832 TSS_EXPORT TSS_Error tss_getWirelessHIDAsynchronousMode(TSS_Device_Id device, unsigned char * HID_communication_mode , unsigned int * timestamp);
    02833 // 240(0xf0)
    02834  /*****************AutoGenerated*************/
    02845 TSS_EXPORT TSS_Error tss_setJoystickLogicalID(TSS_Device_Id device, unsigned char logical_ID , unsigned int * timestamp);
    02846 // 241(0xf1)
    02847  /*****************AutoGenerated*************/
    02858 TSS_EXPORT TSS_Error tss_setMouseLogicalID(TSS_Device_Id device, unsigned char * logical_ID , unsigned int * timestamp);
    02859 // 242(0xf2)
    02860  /*****************AutoGenerated*************/
    02871 TSS_EXPORT TSS_Error tss_getJoystickLogicalID(TSS_Device_Id device, unsigned char * logical_ID , unsigned int * timestamp);
    02872 // 243(0xf3)
    02873  /*****************AutoGenerated*************/
    02884 TSS_EXPORT TSS_Error tss_getMouseLogicalID(TSS_Device_Id device, unsigned char * logical_ID , unsigned int * timestamp);
    02885
    02886 //Wired HID Commands
    02887 // 240(0xf0)
    02888  /*****************AutoGenerated*************/
    02899 TSS_EXPORT TSS_Error tss_setJoystickEnabled(TSS_Device_Id device, unsigned char enabled_state , unsigned int * timestamp);
    02900 // 241(0xf1)
    02901  /*****************AutoGenerated*************/
    02912 TSS_EXPORT TSS_Error tss_setMouseEnabled(TSS_Device_Id device, unsigned char enabled_state , unsigned int * timestamp);
    02913 // 242(0xf2)
    02914  /*****************AutoGenerated*************/
    02925 TSS_EXPORT TSS_Error tss_getJoystickEnabled(TSS_Device_Id device, unsigned char * enabled_state , unsigned int * timestamp);
    02926 // 243(0xf3)
    02927  /*****************AutoGenerated*************/
    02938 TSS_EXPORT TSS_Error tss_getMouseEnabled(TSS_Device_Id device, unsigned char * enabled_state , unsigned int * timestamp);
    02939
    02940 //General HID Commands
    02941 // 244(0xf4)
    02942  /*****************AutoGenerated*************/
    02953 TSS_EXPORT TSS_Error tss_setControlMode(TSS_Device_Id device, unsigned char control_class, unsigned char control_index, unsigned char handler_index, unsigned int * timestamp);
    02954 // 245(0xf5)
    02955  /*****************AutoGenerated*************/
    02966 TSS_EXPORT TSS_Error tss_setControlData(TSS_Device_Id device, unsigned char control_class, unsigned char control_index, unsigned char data_point_index, float data_point, unsigned int * timestamp);
    02967 // 246(0xf6)
    02968  /*****************AutoGenerated*************/
    02979 TSS_EXPORT TSS_Error tss_getControlMode(TSS_Device_Id device, unsigned char control_class, unsigned char control_index, unsigned char * handler_index, unsigned int * timestamp);
    02980 // 247(0xf7)
    02981  /*****************AutoGenerated*************/
    02992 TSS_EXPORT TSS_Error tss_getControlData(TSS_Device_Id device, unsigned char control_class, unsigned char control_index, unsigned char data_point_index, float * data_point, unsigned int * timestamp);
    02993 // 248(0xf8)
    02994  /*****************AutoGenerated*************/
    03005 TSS_EXPORT TSS_Error tss_setButtonGyroDisableLength(TSS_Device_Id device, unsigned char number_of_frames, unsigned int * timestamp);
    03006 // 249(0xf9)
    03007  /*****************AutoGenerated*************/
    03018 TSS_EXPORT TSS_Error tss_getButtonGyroDisableLength(TSS_Device_Id device, unsigned char * number_of_frames, unsigned int * timestamp);
    03019 // 250(0xfa)
    03020  /*****************AutoGenerated*************/
    03031 TSS_EXPORT TSS_Error tss_getButtonState(TSS_Device_Id device, unsigned char * button_state, unsigned int * timestamp);
    03032 // 251(0xfb)
    03033  /*****************AutoGenerated*************/
    03044 TSS_EXPORT TSS_Error tss_setMouseAbsoluteRelativeMode(TSS_Device_Id device, unsigned char mode, unsigned int * timestamp);
    03045 // 252(0xfc)
    03046  /*****************AutoGenerated*************/
    03057 TSS_EXPORT TSS_Error tss_getMouseAbsoluteRelativeMode(TSS_Device_Id device, unsigned char * mode, unsigned int * timestamp);
    03058 // 253(0xfd)
    03059  /*****************AutoGenerated*************/
    03070 TSS_EXPORT TSS_Error tss_setJoystickAndMousePresentRemoved(TSS_Device_Id device, unsigned char joystick, unsigned char mouse, unsigned int * timestamp);
    03071 // 254(0xfe)
    03072  /*****************AutoGenerated*************/
    03083 TSS_EXPORT TSS_Error tss_getJoystickAndMousePresentRemoved(TSS_Device_Id device, unsigned char * joystick, unsigned char * mouse, unsigned int * timestamp);
    03084
    03085
    03086
    03087 #ifdef __cplusplus
    03088     }
    03089 #endif
    03090
    03091 #endif // YEI_THREESPACE_API_H_INCLUDED