Xsens DOT iOS SDK  ©2022 Xsens Technologies - Version: 2022.0.0
XsensDotSyncManager Class Reference

#import <XsensDotSyncManager.h>

Inheritance diagram for XsensDotSyncManager:

Class Methods

(BOOL) + startSync:result:
 
(void) + addSyncDevice:status:sampleCounter:
 
(BOOL) + canSync
 
(void) + stopSync:
 

Detailed Description

This class is the synchronization manager. All sensors will be time-synced with each other to a common time base after synchronization. Refer to section 3.3.4 in Xsens DOT User Manual for more information. The root node in the iOS SDK is always the first sensor connected. It will take the sensors about 10 seconds to finish the sync period, so you can reconnect the sensors after that.

Method Documentation

◆ addSyncDevice:status:sampleCounter:

+ (void) addSyncDevice: (XsensDotDevice *)  device
status: (NSUInteger)  status
sampleCounter: (UInt32)  sampleCounter 

Add sensor to sync sensors after startSync (Used in SDK)

Parameters
deviceXsensDotDevice
statussync status 0x00 : success ,others are fail
sampleCounterFor root node, the sampleCnt is 0, For scan node, the sampleCnt is 0 if failure reason is SynchorizationResult_Unstarted(0x9).

◆ canSync

+ (BOOL) canSync

Check if sync started.

Returns
The started flag.

◆ startSync:result:

+ (BOOL) startSync: (NSArray< XsensDotDevice * > *)  devices
result: (XsensDotSyncResultBolck resultBlock 

Start synchronization

Parameters
devicesList of Xsens DOT sensor (the firstObject is the root others are scanners)
resultBlockSync result array have macAddress and the sync result.

The result example : ( { address = "D4:CA:6E:F1:6C:0B"; doneSuccess = 1; sampleCounter = 0; status = 0; success = 1; // } ) doneSuccess: sync done status, sampleCounter:sync sample counter, status: sync status code, success: the sync success flag 1 is success and 0 is fail

Returns
If firmware support sync feature this will be YES, otherwise it's NO

◆ stopSync:

+ (void) stopSync: (NSArray< XsensDotDevice * > *)  devices

Stop synchronization After do it , you can check device.isSynced to get current sync status.

Parameters
deviceslist of XsensDotDevice

The documentation for this class was generated from the following file: