Home
Pointer SDK User`s Manual
Contents
1. Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com li OptoAHRS nertielL obs um Revision 1 1 P ClbAccept P CIbExit P BoresightingSetAngles P BoresightingGetAngles P BoresightingGetStatus P BoresightingStartStep1 P BoresightingStartStep2 P BoresightingStopStep2 P BoresightingAccept P BoresightingExit P StartOptoIMU P ConvertBinParToTxt P Close Upon opening OptoAHRS SDK only Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 1 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com P InertialLabs sin Appendix A Proper Sample Sequences to Perform the Magnetometer Calibrations A 1 3D Calibration Procedure Step 1 before starting calibration in order to allocate memory from the operating system you should call the following function P_Result P_Open Step 2 it s also vital to set proper serial port by using P Result P SetPortNumber unsigned short PortNumber where PortNumber necessary serial port number Step 3 you should set necessary data accumulation time P Result P SetClbAccumulationTime unsigned short AccumulationTime where AccumulationTime sets in seconds Step 4 the next thing is to se
2. Setting Accumulation Time P Result P SetClbAccumulationTime unsigned short AccumulationTime A call to this function sets data accumulation time in seconds for a calibration Setting Reference Azimuth P Result P SetClbRefAzimuth float RefAzimuth A call to this function sets reference azimuth for the Zone 3D calibration Setting Azimuth Shift P Result P_SetClbRefAzimuth float RefAzimuth A call to this function sets azimuth shift relative to reference azimuth for the Zone 3D calibration Getting Calibration Status P Result P GetClbStatus unsigned short Status This function gets current calibration status to indicate the following statuses A received status contains hints in each bit Bit Number Description 0 If 1 then current calibration is successful 1 If 1 then calibration is in progress 2 If 1 then initial alignment is in progress 3 If 1 then data are accumulating 4 If 1 then accumulated data are being calculated 5 If 1 then function P ClbNext is available 6 If 1 then function P ClbStop is available 7 If 1 then function P ClbAccept is available 8 If 1 then function P ClbExit is available Getting Created Reference Frames Status Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 11 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www
3. There are several API functions intended for the boresighting procedure Setting Boresighting Angles P Result P BoresightingSetAngles float heading float pitch Getting Boresighting Angles P Result P BoresightingGetAngles float heading float pitch Getting Boresighting Status P Result P BoresightingGetStatus unsigned short Status This function gets current boresighting status to indicate the following statuses The received status contains hints in each bit Bit Number Description 0 If 1 then step1 is currently running 1 If 1 then step1 data accumulation failed 2 If 1 then step1 data accumulation succeeded 3 If 1 then step2 is currently running 4 If 1 then step2 data accumulation failed 5 If 1 then function P_BoresightingStopStep2 is available 6 If 1 then step2 optic data accumulation failed 7 If 1 then step2 data accumulation succeeded Starting Boresighting Step1 and Step2 Respectively P_Result P_BoresightingStartStep1 short ElevationMils P_Result P_BoresightingStartStep2 where ElevationMils is the initial elevation set in mils Stopping Step2 P_Result P_BoresightingStopStep2 This function calls the P_BoresightingStartStep2 function and waits for the initial alignment completion when status bit 5 is set to 1 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeo
4. InertialLabs sn 4 Initialization There are several functions available that should be called before starting the OptoAHRS in order to initialize its parameters Opening OptoAHRS SDK P_Result P_Open This function allocates memory from the operating system and thus should be called ones only at the very beginning of the work with the OptoAHRS SDK library Setting Serial Port P_Result P_SetPortNumber unsigned short PortNumber It is used for setting necessary serial port OptoAHRS connected to Allowing Data Saving P_Result P_AllowDataSaving bool Allow This function enables disables permission for data saving in all functions mentioned below Note data saving is disabled on default Allowing Saving a Log P_Result P_EnableDebugLog boolEnable This function enables disables permission for saving a debug log which helps to eliminate application bugs Note log saving is disabled on default If data saving is disabled then this function doesn t influence Allowing Data Writing P_Result P_AllowWriting bool Allow This function starts stops writing data into a binary file Note If data saving is disabled then this function doesn t matter Allowing Auto Calibration Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLab
5. TvD First version 2 1 18 23 Mar 26 2012 TvD 1 Removed the bug causing OptoAHRS incorrect heading output i e jumps by 295 2 Removed the OptoAHRS output angle data smoothing filter 3 Added an additional adjustment to optics azimuth output data 4 0 2 3 May 21 2012 TvD 1 Changed the function definitions Now in place of calling a function with many parameter several functions with small number of parameters shall be called 2 Extended the parameter block from 750 bytes up to 2 Kbytes 3 Added the Qt library dependencies the optics software is redeveloped with C 4 Added functions to run the calibrations 5 Added options to select the applicable magnetometer correction parameter set before and during operation Start with and Continue with 6 Added a new parameter to the AHRS memory 4 0 6 6 June 1 2012 TvD 1 Added the creation of a csv file to save the zone calibration results 2 Removed the bug causing saving incorrect magnetic heading into the csv file created for fires 4 0 7 7 June 7 2012 TvD 1 Redeveloped the OptoAHRS SDK_Demo with C and removed all the other demo versions 2 Removed the possibility to set the position from within the calibration options Now the program reads the position from the AHRS memory 3 Removed the callback functions from the Pointer_SDK_manual 4 Removed the record in the csv file when calling P_GetCur
6. Caution Data structure was changed Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 5 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com OptoAHRS SDK Manual InertialLabs Sens 1 Overview This document gives a high level description of the API to be used with the OptoAHRS SDK in pseudo code form The API is precisely defined in demo projects sources accompanying the SDK 2 System Requirements For correct OptoAHRS operation the OptoAHRS SDK requires the following e 1 5 GHz or faster processor 1 Gb internal RAM 256 Mb video RAM OpenGL 2 0 and later DirectX 9 0b or higher iCube Camera Device Driver iCube Camera API ICubeSDK dll Optic Library libvisualgyro dll 3 Data Types Windows 7 Windows Vista Windows XP SP3 Microsoft Visual C 2008 Redistributable Package Qt Libraries libgcc_s_dw2 1 dll mingwm10 dll QtCore4 dll Enumerations Description enum P_Result P_SUCCESS 0x00 P ERROR 0x01 Return values of API functions enum P_ClbType CLB 2D 0x11 CLB 2D2T 0x12 CLB 3D 0x13 CLB ZONE 0x14 Calibration types hi enum P ClbStatusBits CS SUCCESS 0x0001 CS IS STARTED 0x0002 CS INIT ALIGNMENT 0x0004 CS DATA ACCUMULATING 0x0008 CS DATA CALCULATING 0x0010 CS NEXT REQUESTED 0x0020 CS STOP REQUESTED 0x0040 CS ACCEPT REQUE
7. 448 November 13 2012 December 3 2012 TvD TvD Function P GetAdditionalInfo was introduced Several improvements in creation of reference frames Optics auto correction algorithms Function P EnableDebugLog was introduced 15 0 19 459 December 14 2012 TvD Several improvements in auto creation of reference frames Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com OptoAHRS nertiaiLabs Loa Revision 1 1 New parameter RefMode was introduced 15 0 26 476 March 5 2013 SD The principal OptoAHRS KF algorithm was streamlined 15 0 28 486 April 29 2013 SD 1 The library Optics dll was replaced with libvisualgyro dll 2 A bug in the OptoAHRS bore sighting algorithm was fixed The 0 05 deg resolution of the OptoAHRS angles was removed 15 0 29 505 July 4 2013 SD 1 The manual reference frame creation function was transferred into the optic thread 2 The recalculation of the OptoAHRS Euler angles into the tube azimuth and elevation and vice versa was implemented 3 The possibility to perform fires and to create reference frames manually based on the tube azimuth was added Also a file named TestFullTubeData lt DateTime gt csv is created to write tube azimuths and elevations 4 The following new functions were added P_TubeFire to perfor
8. CLB ZONE 0x14 Note the Zone 3D calibration procedure involves pointing of the weapon on at least four corners and intermediate points of the firing zone The maximum number of calibration points is 9 Step 7 once you have started Zone 3D calibration in order to get current calibration status you should call the following function from time to time P Result P_GetClbStatus unsigned short Status Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 26 InertialLabs sin where Status contains information about actions available currently full explanation of status bits see in the end of this document In this stage received Status is equal to e 00000001 00100010 if you used this function right after starting calibration e 00000001 10100010 or 00000001 10100011 if you have already made at least 4 calibration points e 00000001 10000010 or 00000001 10000011 if you have already made 9 calibration points This means that calibration is currently in progress and that you are expected e to call P ClbNext function for data accumulating in the next position if bit 5 1 e tocall P_ClbAccept function for saving calibration results if bit 7 1 e Orto call P CIbExit function to terminate calibration procedure Step 8 to start data accumulating you should set the devi
9. Fire function current frames are writing into lt current date time gt vrw file 4 0 17 17 July 2 2012 TvD 1 Boresighting procedure improved 2 Added creation of reference frames during zone calibration 4 0 20 20 July 11 2012 TvD Added new type for a parameter InitClbType Simple Clb while others have been incremented 4 0 26 26 August 2 2012 TvD Magnetic field calibrations improved 15 0 1 1 August 21 2012 TvD 1 Pointer SDK renamed into OptoAHRS SDK 2 Library was optimized and compiled in C for the first time 3 Fly zone calibration was simplified Functions P_FlyZoneClbClear P_FlyZoneClbAdd andP_FlyZoneClbAccept were deleted P_AllowFlyZoneClb added 15 0 2 2 September 4 2012 TvD New function P GetReferenceFrame was introduced Auto creation of reference frames implemented Performance improved 15 0 3 3 September 12 2012 TvD OptoAHRS algorithms were improved 15 0 4 4 September 13 2012 TvD New parameter RFlimit was added 15 0 6 7 September 22 2012 TvD Some improvements in optical algorithms 15 0 7 9 September 25 2012 TvD Crash error sometimes appeared after OptoAHRS stop was eliminated Improvement of reference frames auto creation algorithm Deleted recording into TestFullData csv during reference frames creation but not during firing which still records 15 0 13 23 15 0 16
10. OptoAHRS InertialLabs sok tn OPTICALLY ENHANCED ATTITUDE AND HEADING REFERENCE SYSTEM OptoAHRS Software Development Kit SDK Manual Revision 1 1 Inertial us ne M Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com OptoAHRS InertialLabs sok tn Table of Contents OptoAHRS SDK VEnSlONS sosise iisi essea ienie ieina Senise di dedide dedide iiai idiin 3 Ds OER c 6 2 System Rel etre GS cde ada ceed da ad dead bd bad dc ad bd bad dead Sad dda cd ed nde bn 6 3 D ta UY D cade Sids cake bhusentupldas 6 LUME ILU I 9 Be OPUOAMIRS Paramiet tS esie Dr n c n bond Do tn RN n E i 10 6 Calibrations croceo be per DusicHeid ae ehh id ep E Pr COR EU eH DUKE DD eA n bis 11 7 Boresighting Procedure MERE T TTE 13 PENES eile rp UA 14 NELSON m 17 10 Finalization RN T T oom 17 11 API Functions Availability usos cina sue Zuba x XX uq exea REX KRER ERE FUR EX Cub E Xxx Ond Run Y as 17 Appendix A Proper Sample Sequences to Perform the Magnetometer Calibrations 19 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 2 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs OptoAHRS SDK Manual Revision 1 1 OptoAHRS SDK Versions Version Date By Changes 2 1 17 21 Dec 07 2011
11. STED 0x0080 CS EXIT REQUESTED 0x0100 Calibration status bits enum P_ClbBiasType BT_DEGS 0x00 BT MILS 0x01 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Heading bias types for zone 3D calibration Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com Inertial Labs OptoAHRS SDK Manual Revision 1 1 ae P_UsedClbType UC_SIMPLE_CLB 0x00 UC_FACTORY_CLB 0x01 UC_2D_2T_CLB 0x02 Used calibration types UC ZONE_CLB 0x03 UC AUTO CLB 0x04 enum P BoresightingStatusBits BS STEP1 STARTED 0x0001 BS STEP1 INIT ERROR 0x0002 BS STEP1 COMPLETED 0x0004 BS STEP2 STARTED 0x0008 BS STEP2 INIT ERROR 0x0010 BS STEP2 CAN STOP 0x0020 BS STEP2 OPTIC ERROR 0x0040 BS STEP2 COMPLETED 0x0080 Boresighting status bits enum P ReferencesStatusBits RSB AUTO UNDEFINED 0x00 RSB AUTO CREATING 0x01 RSB AUTO CORRECTING 0x02 RSB AUTO COMPLETED 0x04 hi References status bits Structures Description pragma pack 1 struct P_Params float Mdec float Latitude float Longitude float Altitude float Mdate uchar ClbInitType uchar RFlimit char Reserved0 char Reserved1 i Parameters data pragma pack 1 struct P_CurrentOutputs float Azimuth Tube azimuth angle float Elevation Tube elevation angle float OptoIMUH OptoAHRS heading after
12. ce in the necessary position and call the following functions P Result P SetClbBias P ClbBiasType BiasType float BiasValue where BiasType should be set whether to BT DEGS 0x00 for setting BiasValue in degrees or to BT MILS 0x01 for setting BiasValue in mills BiasValue is an azimuth shift relative to the reference azimuth set in step 5 Then call P Result P CIbNext which starts data accumulation and moves to step 10 Note that P ClbNext function is available only if you haven t made 9 calibration points yet Step 10 after calling P ClbNext function received Status is equal to 00000000 00001010 which means that data are currently accumulating Note that you shouldn t move the device until this process is done bit 3 0 After data are accumulated you should move to step 7 Step 11 if you have already made at least 4 calibration points you can accept calibration procedure results by using P Result P ClbAccept which terminates further calibration saves results and moves to step 13 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 27 InertialLabs sn Step 12 you can also terminate the whole calibration procedure by using P Result P CIbExit which terminates further calibration without saving its results and moves to s
13. ction P_CIbExit is available Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 25 OptoAHRS nertiaiLabs lt Revision 1 1 A4 Zone 3D Calibration Procedure Step 1 before starting calibration in order to allocate memory from the operating system you should call the following function P_Result P_Open Step 2 it s also vital to set proper serial port by using P_Result P_SetPortNumber unsigned short PortNumber where PortNumber necessary serial port number Step 3 you should set necessary data accumulation time P Result P SetClbAccumulationTime unsigned short AccumulationTime where AccumulationTime sets in seconds Step 4 the next thing is to set current coordinates by using P Result P SetClbCoordinates float Latitude float Longitude float Altitude float Date where Latitude and Longitude set in degrees Altitude in meters Date in years e g May 20 2012 2012 5 12 20 365 2012 4714 Step 5 you should also set proper reference azimuth by calling P Result P SetClbRefAzimuth float RefAzimuth where RefAzimuth sets in degrees Step 6 after this moment you can start calibration and move to the main loop in step 7 P Result P ClbStart P CIbType where P CIbType for Zone 3D calibration is
14. emory for this parameter To stop OptoAHRS operation the following function is available Stopping OptoAHRS P_Result P_Stop Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com Opto AHRS nertiaiLabs Revision 1 1 9 Converter To convert saved binary files bin par into text files the following function is available Converting Data P_Result P_ConvertBinParToTxt char BinFilename 10 Finalization Closing OptoAHRS SDK P_Result P_Close This function closes the OptoAHRS SDK and returns resources to the operating system Note Before using this function you should call P_Stop function mentioned above in order to terminate the operation properly 11 API Functions Availability API Function Availability P_Open p opening the OptoAHRS SDK P SetPortNumber Before starting the OptoAHRS only P AllowDataSaving P EnableDebugLog P AllowWriting P AllowAutoCalibration P AllowFlyZoneCalibration P SetCameraPreview P GetParams P SetParams P LoadParameters P ComputeMagneticDeclination P SetClbAccumulationTime P SetClbRefAzimuth P SetClbBias P GetClbStatus P GetClbRFStatus P ClbClear P CilbStart P ClbNext P CibStop Upon opening the OptoAHRS SDK only Before starting the OptoAHRS only
15. in degrees Altitude in meters Date in years e g May 20 2012 2012 5 12 20 365 2012 4714 Step 5 after this moment you can start calibration P Result P ClbStart P CIbType where P CIbType for 2D calibration is CLB 2D Ox11 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 21 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sin Step 6 once you have started 2D calibration in order to get current calibration status you should call the following function from time to time P Result P GetClbStatus unsigned short Status where Status contains information about actions available currently full explanation of status bits see in the end of this document If you used this function right after starting calibration received Status is equal to 00000000 00000110 which means that calibration and initial alignment are currently in progress Note that you shouldn t move the device until initial alignment is done bit 2 0 After initial alignment is done Status will change to 00000001 01001010 which means that data are accumulating and you can also stop calibration by calling P ClbStop function or terminate calibration procedure by using P CIbExit In this stage you should rotate the device Rotate weapon in azimuth with pitch and roll angles close to zero as possible This rotation must include one
16. inertiallabs com InertialLabs sn P Result P GetClbRFStatus unsigned short Status This function gets the reliability of created reference frames during zone calibration Each bit of a received Status contains the reliability of a corresponding reference frame e g Status 18 10010 in binary means the reference frames in positions 2 and 5 unreliable Clearing Calibration Parameters P Result P ClbClear A call to this function clears the current magnetic field calibration parameters Starting Calibration P Result P ClbStart P CIbTypeCIbType This function starts the selected calibration sequence Continuing Calibration P Result P CIbNext This function is only for 2D 2T and Zone 3D calibrations when next positions are required Stopping Calibration P Result P ClbStop This function stops data accumulation and starts data calculation Accepting Calibration P Result P ClbAccept This function saves the calibration parameters and terminates the calibration Exiting Calibration P Result P CIbExit This function terminates calibration without saving calibration parameters Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 12 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com OptoAHRS f f SDK Manual Revision 1 1 7 Boresighting Procedure
17. ling P_ClbNext function and moving to step 7 note 2D 2T calibration must include at least two runs with full 360 rotations of the weapon in azimuth with different pitch angles e or call P ClbStop function and move to step 13 e orcall P CIbExit function and move to step 15 Step 13 after you used P ClbStop function in step 12 Status will change to 00000001 10000011 or 00000001 10000010 where bit 0 indicates calibration success and other non zero bits mean that it is expected that you e call P CIbExit function without saving calibration results and move to step 15 e or accept them by using P ClbAccept function Step 14 if you are satisfied with calibration results you can save them by using P Result P ClbAccept Step 15 after the calibration is done you are expected to finalize working with Pointer SDK by using P Result P Close This function closes Pointer SDK and returns resources to the operating system Table A3 Status Bit Description Bit Number Description 0 If 1 then current calibration is successful 1 If 1 then calibration is in progress 2 If 1 then initial alignment is in progress 3 If 1 then data are accumulating 4 If 1 then accumulated data are calculating 5 If 1 then function P_ClbNext is available 6 If 1 then function P_ClbStop is available 7 If 1 then function P_ClbAccept is available 8 If 1 then fun
18. m a fire based on tube azimuth P_RecalcOptoIMUHeadingIntoTubeAzimuth to recalculate OptoAHRS heading into tube azimuth based on specified Euler angles P_RecalcTubeAzimuthIntoOptoIMUHeading to recalculate tube azimuth into OptoAHRS heading Caution The P_Reference structure was changed Roll and pitch angles were added The P_CurrentOutputs structure was changed The OptoIMUHBR OptoIMUPBR OptoIMURBR fields were added 15 0 30 517 August 30 2013 SD The Extrinsics angles misalignments between the camera and OptoAHRS axes were added into the algorithm 15 0 33 527 October 23 2013 SD Software 2x2 image binning was implemented to be used when hardware binning is off 15 0 42 550 January 27 2014 SD Several new functions were added P LoadParameters char PrmFileName to load a parameter file into the device memory P ComputeMagneticDeclination to calculate magnetic declination P BoresightingSetAngles and P BoresightingGetAngles to write and read tube s offset angles 15 0 44 553 February 19 2014 SD The error of pulling optic angles down to zero upon recovering optic orientation validity was passed around 15 0 48 565 June 20 2014 SD 1 The crash error due to creation of too many reference frames was fixed 2 Optical obstruction detection was added 15 0 49 574 July 29 2014 SD LoopClosure flag was added LoopClosure is set to 1 upon Loop Closure occurs
19. mentioned reference frame Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 15 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sn Setting an Existing Reference P_Result P_SetReference P_Reference Reference It s also possible to change the current magnetic field calibration parameter set during operation by calling the following function Changing Calibration Type P_Result P_ChangeUsedClbType P_UsedClbTypeUsedClbType For recalculating OptoAHRS heading into tube azimuth and back the following function is available Recalculating Heading into Tube Azimuth based on OptoAHRS Euler angles P_Result P_RecalcOptoIMUHeadingIntoTubeAzimuth P_Reference CurrentAngles float RecountedAzimuth where CurrentAngles input parameter is the structure containing the three OptoAHRS Euler angles RecountedAzimuth output parameter is tube azimuth A caller must pre allocate memory for this parameter If the function returns P_SUCCESS recounting is successful RecountedAzimuth contains the recount azimuth value Recalculating Tube Azimuth into OptoAHRS Heading Based on OptoAHRS Euler Angles P_Result P_RecalcTubeAzimuthIntoOptoIMUHeading P_Reference CurrentAngles float InitialAzimuth float RecountedHeading where CurrentAngles input parameter is the structure three angles structure A caller must pre allocate m
20. nian Springs VA 20129 USA 13 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sn Accepting Boresighting Results P_Result P_BoresightingAccept This function saves the results of boresighting and saves them into the OptoAHRS memory Note This function is available only when step1 and step2 data accumulation are successful bit 2 and bit 7 are set to 1 Exiting Boresighting Procedure P_Result P_BoresightingExit This function terminates the boresighting procedure without saving its results 8 OptoAHRS Operation To start the OptoAHRS the following API function is available StartingOptoAHRS P_Result P_StartOptoIMU Upon this and until operation is stopped there are several functions available Getting Output Data P_Result P_GetCurrentOutputs P_CurrentOutputs Data Getting Additional Info P_Result P_GetAdditionalInfo P_AdditionalInfo Info Firing P_Result P_Fire float TargetHeading A call to this function makes the current output data to be automatically saved to the csv file Tube Firing P Result P TubeFire float TubeAzimuth float Tubeelevation Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 14 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sn A call to this function automa
21. or more full 360 deg turns Step 7 as it has been said before you can stop data accumulating by using P Result P ClbStop which terminates data accumulating and moves to step 9 Step 8 you are also eligible to terminate the whole calibration procedure by using P Result P CIbExit Step 9 after data have been accumulated or P ClbStop function has been called calibration status will change to 00000000 00010010 which means that accumulated data are currently calculating and you should wait until this process is done In this stage you can stop rotating the device Step 10 after calibration data have been calculated calibration status will change to 00000001 10000011 or 00000001 10000010 where bit 0 indicates calibration success and other non zero bits mean that it is expected that you will call whether P CIbExit function without saving calibration results or accept them by using P ClbAccept function Step 11 if you are satisfied with calibration results you can save them by using P Result P ClbAccept Step 12 after the calibration is done you are expected to finalize working with Pointer SDK by using P Result P Close Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 22 InertialLabs sin This function closes Pointer_SDK and returns re
22. rentOutputs since now it is used in SDK_Demo in place of callback 5 Removed the mistake causing zeroing the OptoAHRS parameters in case of an unstopped process in the previous start if the OptoAHRS was not stopped for some reason the next start zeroed the parameters 6 Added an additional call of P_Stop before P_Close in case of a running stream to stop it 4 0 9 9 June 9 2012 TvD Added the P_Result P_Fire float TargetHeading function which when called writes the current OptoAHRS output Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com OptoAHRS InertialLabs sok mana averaged over the 100 last samples into the csv file The Pointer_SDK_Demo interface is supplemented with the corresponding button Fire 4 0 10 10 June 11 2012 TvD 1 Added record of magnetic declination into the SDKZoneClb csv and FlyZoneClb csv files 2 Record of true geographical azimuth instead of magnetic in mentioned above files 4 0 11 11 June 12 2012 TvD Wrong taking into account of magnetic deviation bugs fixed 4 0 14 14 June 21 2012 TvD 1 Pointer_SDK_Demo has been renamed into OptoAHRS_Demo 2 Boresighting functions added 3 Caution current output data structure was changed azimuth and elevation angles were added 4 After each using of P_
23. rounding float OptoIMUP OptoAHRS pitch after rounding float OptoIMUR OptoAHRS roll after rounding float OptoIMUHBR OptoAHRS heading before rounding float OptoIMUPBR OptoAHRS pitch before rounding Current output data Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs OptoAHRS SDK Manual Revision 1 1 float OptoIMURBR OptoAHRS roll before rounding float IMUH AHRS heading float IMUP AHRS pitch float IMUR AHRS roll float OpticH Optic heading float OpticP Optic pitch float OpticR Optic roll float AccMagH heading pitch and float AccMagP roll calculated by float AccMagR accelerometers and magnetometers uchar MagInterference magnetic interference uchar OptInterference optical interference float Vdd supply voltage ushort USW status word hi pragma pack 1 struct P AdditionalInfo short RefNum short RefId short RefStatus uchar RefMode uchar LoopClosure uchar Reserved 92 hi Additional info data pragma pack 1 struct P_Reference int Ref_ID float Heading float Pitch float Roll y Reference data Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com
24. rtial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 23 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sin Step 5 after this moment you can start calibration P Result P ClbStart P CIbType where P CIbType for 2D 2T calibration is CLB 2D2T 0x12 Step 6 once you have started 2D 2T calibration in order to get current calibration status you should call the following function from time to time P Result P GetClbStatus unsigned short Status where Status contains information about actions available currently full explanation of status bits see in the end of this document If you used this function right after starting calibration received Status is equal to 00000001 00100010 which means that calibration is currently in progress and that you are expected e tocall P ClbNext function for data accumulating in the next position e or call P CIbExit function to terminate calibration procedure Step 7 to start data accumulating you should set the device in the position with the necessary pitch angle and call the following function P Result P CIbNext Step 8 you are also eligible to terminate the whole calibration procedure by using P Result P CIbExit which terminates further calibration and moves to step 15 Step 9 after calling P ClbNext function received Status is equal to 00000000 00000110
25. s 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 20 InertialLabs sin Table Ai Status Bit Description Bit Number Description 0 If 1 then current calibration is successful If 1 then calibration is in progress If 1 then initial alignment is in progress If 1 then data are accumulating If 1 then accumulated data are calculating If 1 then function P_ClbNext is available If 1 then function P_ClbStop is available If 1 then function P_ClbAccept is available If 1 then function P_CIbExit is available CO NI OF UT BY OG NO e A 2 2D Calibration Procedure Step 1 before starting calibration in order to allocate memory from the operating system you should call the following function P_Result P_Open Step 2 it s also vital to set proper serial port by using P Result P SetPortNumber unsigned short PortNumber where PortNumber necessary serial port number Step 3 you should set necessary data accumulation time P Result P SetClbAccumulationTime unsigned short AccumulationTime where AccumulationTime sets in seconds Step 4 the next thing is to set current coordinates by using P Result P SetClbCoordinates float Latitude float Longitude float Altitude float Date where Latitude and Longitude set
26. s sin P_Result P_AllowAutoCalibration bool Allow This function enables disables permission for auto calibration during operation Allowing Fly zone Calibration P_Result P_AllowFlyZoneCalibration bool Allow This function enables disables permission for fly zone calibration during operation Setting Camera Preview P_Result P_SetCameraPreview HWND ViewHandle This function makes it possible to preview camera images in a window with indicated descriptor Note if ViewHandle 0 then preview is disabled on default 5 OptoAHRS Parameters There are four functions available to work with the OptoAHRS parameters Getting Current Parameters P_Result P_GetParams P_Params Params Setting Necessary Parameters P_Result P_SetParams P_Params Params Restoring Parameters Loading a Set of OptoAHRS Parameters into the Device P_Result P_LoadParameters char PrmFileName Compute Magnetic Declination Parameter P_Result P_ComputeMagneticDeclination float latitude float longitude float altitude int year int month int day float magDeclination Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 10 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sn 6 Calibrations There are several functions intended for magnetic field calibrations 2D 2T 3D 2D and Zone 3D
27. sing P CIbExit In this stage you should rotate the device During the data accumulation the weapon should be rotated in full azimuth pitch and roll ranges Step 7 as it has been said before you can stop data accumulating by using P Result P ClbStop which terminates data accumulating and moves to step 9 Step 8 you are also eligible to terminate the whole calibration procedure by using P Result P CIbExit Step 9 after data have been accumulated or P ClbStop function has been called calibration status will change to 00000000 00010010 which means that accumulated data are currently calculating and you should wait until this process is done In this stage you can stop rotating the device Step 10 after calibration data have been calculated calibration status will change to 00000001 10000011 or 00000001 10000010 where bit 0 indicates calibration success and other non zero bits mean that it is expected that you will call whether P CIbExit function without saving calibration results or accept them by using P ClbAccept function Step 11 if you are satisfied with calibration results you can save them by using P Result P ClbAccept Step 12 after the calibration is done you are expected to finalize working with Pointer SDK by using P Result P Close This function closes Pointer SDK and returns resources to the operating system Inertial Labs Inc Addres
28. sources to the operating system Table A2 Status Bit Description Bit Number Description If 1 then current calibration is successful eo If 1 then calibration is in progress If 1 then initial alignment is in progress If 1 then data are accumulating If 1 then accumulated data are calculating If 1 then function P ClbNext is available If 1 then function P ClbStop is available If 1 then function P ClbAccept is available If 1 then function P_CIbExit is available co Oo uU1 Cc N e A3 2D 2T Calibration Procedure Step 1 before starting calibration in order to allocate memory from the operating system you should call the following function P Result P Open Step 2 it s also vital to set proper serial port by using P Result P SetPortNumber unsigned short PortNumber where PortNumber necessary serial port number Step 3 you should set necessary data accumulation time P Result P SetClbAccumulationTime unsigned short AccumulationTime where AccumulationTime sets in seconds Step 4 the next thing is to set current coordinates by using P Result P SetClbCoordinates float Latitude float Longitude float Altitude float Date where Latitude and Longitude set in degrees Altitude in meters Date in years e g May 20 2012 2012 5 12 20 365 2012 4714 Ine
29. t current coordinates by using P Result P SetClbCoordinates float Latitude float Longitude float Altitude float Date where Latitude and Longitude set in degrees Altitude in meters Date in years e g May 20 2012 2012 5 12 20 365 2012 4714 Step 5 after this moment you can start calibration P Result P ClbStart P CIbType where P CIbType for 3D calibration is CLB 3D 0x13 Step 6 once you have started 3D calibration in order to get current calibration status you should call the following function from time to time P Result P_GetClbStatus unsigned short Status where Status contains information about actions available currently full explanation of status bits see in the end of this document If you used this function right after starting calibration received Status is equal to 00000000 00000110 which means that calibration and initial alignment are currently in progress Note that you shouldn t move the device until initial alignment is done bit 2 0 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA 19 Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com InertialLabs sin After initial alignment is done Status will change to 00000001 01001010 which means that data are accumulating and you can also stop calibration by calling P ClbStop function or terminate calibration procedure by u
30. tep 13 Step 13 after the calibration is done you are expected to finalize working with Pointer SDK by using P Result P Close This function closes Pointer SDK and returns resources to the operating system Table A4 Status Bit Description Bit Number Description 0 If 1 then current calibration is successful 1 If 1 then calibration is in progress 2 If 1 then initial alignment is in progress 3 If 1 then data are accumulating 4 If 1 then accumulated data are calculating 5 If 1 then function P_ClbNext is available 6 If 1 then function P_ClbStop is available 7 If 1 then function P_ClbAccept is available 8 If 1 then function P_CIbExit is available Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 28
31. tically saves the current azimuth and elevation angles to the TestFullTubeData lt DateTime gt csv file All current reference frames can be deleted by calling the following function Deleting All References P_Result P_ClearReferences Upon calling this function the optical orientation angles will be set to zero For correct OptoAHRS operation it is necessary to create at least one reference frame using the following function Creating a Reference Manually P_Result P_AddReferenceFrame float TargetHeading A call to this function creates a reference frame with a specified geographical target azimuth in degrees and two data files e pgm picture of accepted reference frame e csv full data protocol of the OptoAHRS output at the moment of the reference frame creation The following functions can be used to get and set specified reference frames Getting the Number of Existing References P_Result P_GetNumOfReferences int NumOfReferences where NumOfReferences is the number of existing references Getting an Existing Reference P_Result P_GetReference intNumOfReference P_Reference Reference P_Result P_GetReferenceFrame intNumOfReference uchar Frame int Size Where NumOfReference is the input number of the requested reference Reference is the requested reference Frame is the pointer to the reference frame in bitmap format Size is the size of the
32. which means that initial alignment is currently in progress d After initial alignment is done Status will change to 00000001 01001010 which means that data are accumulating and you can also stop calibration by calling P ClbStop function or terminate calibration procedure by using P ClbExit In this stage you should rotate the device Rotate weapon in azimuth with approximately constant pitch and roll angles as possible This rotation must include one or more full 360 deg turns Step 10 as it has been said before you can stop data accumulating by using P Result P ClbStop which terminates data accumulating and moves to step 11 Inertial Labs Inc Address 39959 Catoctin Ridge Street Paeonian Springs VA 20129 USA Tel 1 703 880 4222 Fax 1 703 991 5378 Website www inertiallabs com 24 OptoAHRS nertielLobs Revision 1 1 Step 11 after data have been accumulated or P ClbStop function has been called calibration status will change to 00000000 00010010 which means that accumulated data are currently calculating and you should wait until this process is done In this stage you can stop rotating the device Step 12 after calibration data have been calculated calibration status will change to 00000001 01100011 or 00000001 01100010 where bit 0 indicates calibration success and other non zero bits mean that it is expected that you e continue data accumulating in the next pitch by cal
Download Pdf Manuals
Related Search
Related Contents
Fiche Information Produit RESYS P40 instrucciones de servicio Relé de protección Bosch 2609256A80 Service Manual MX999 & FR994 HX2 Reference Guide - Honeywell Scanning and Mobility Rubbermaid FG5L3000SDONX Use and Care Manual Philips 3139 125 33021 User's Manual Graef FF 1400 deep fryer Copyright © All rights reserved.
Failed to retrieve file