Group Miscellaneous¶
These functions are general helpers to dealing with errors etc. More...
Public Functions¶
Type | Name |
---|---|
EXPORTED void PRE | jsGetAPISemanticVersion (uint32_t * major, uint32_t * minor, uint32_t * patch) Obtains the semantic version of the client API presented as unsigned integer values. |
EXPORTED void PRE | jsGetAPIVersion (const char ** version_str) Obtains the semantic version of the client API presented in this header. The version string will be of the form vX.Y.Z , whereX is the major version number,Y is the minor version number, andZ is the patch number. In some cases, additional information may be appended to the version string, separated by hyphens. |
EXPORTED void PRE | jsGetError (int32_t return_code, const char ** error_str) Converts a jsError error value returned from an API function call to a string value. |
EXPORTED int32_t | jsPowerCycleScanHead (uint32_t serial_number) Performs a remote soft power cycle of a scan head. |
EXPORTED int32_t PRE | jsScanHeadGetCapabilities (jsScanHead scan_head, jsScanHeadCapabilities * capabilities) Obtains the capabilities for a given scan head. |
EXPORTED int32_t PRE | jsScanHeadGetFirmwareVersion (jsScanHead scan_head, uint32_t * major, uint32_t * minor, uint32_t * patch) Obtains the firmware version of the scan head presented as unsigned integer values. |
EXPORTED uint32_t PRE | jsScanHeadGetId (jsScanHead scan_head) Obtains the ID of the scan head. |
EXPORTED int32_t PRE | jsScanHeadGetLastErrorExtended (jsScanHead scan_head, const char ** error_extended_str) When a jsScanHead function returns an error, this function can be called immediately after to obtain a more detailed message regarding the error. |
EXPORTED uint32_t PRE | jsScanHeadGetSerial (jsScanHead scan_head) Obtains the serial number of the scan head. |
EXPORTED int32_t PRE | jsScanHeadGetStatus (jsScanHead scan_head, jsScanHeadStatus * status) Reads the last reported status update from a scan head. |
DEPRECATED EXPORTED int PRE | jsScanSystemGetEncoder (jsScanSystem scan_system, jsEncoder encoder, int64_t * value) |
EXPORTED int32_t PRE | jsScanSystemGetLastErrorExtended (jsScanSystem scan_system, const char ** error_extended_str) When a jsScanSystem function returns an error, this function can be called immediately after to obtain a more detailed message regarding the error. |
EXPORTED jsScanHead PRE | jsScanSystemGetScanHeadById (jsScanSystem scan_system, uint32_t id) Obtains a reference to an existing jsScanHead object. |
Detailed Description¶
These methods are not used in the setup and usage of the scan system and profile gathering. They do provide useful diagnostic information, such as firmware version, scan head status, and error descriptions.
Public Functions Documentation¶
function jsGetAPISemanticVersion¶
Obtains the semantic version of the client API presented as unsigned integer values.
EXPORTED void PRE jsGetAPISemanticVersion (
uint32_t * major,
uint32_t * minor,
uint32_t * patch
)
Parameters:
major
The major version number.minor
The minor version number.patch
The patch version number.
function jsGetAPIVersion¶
Obtains the semantic version of the client API presented in this header. The version string will be of the form vX.Y.Z
, whereX
is the major version number,Y
is the minor version number, andZ
is the patch number. In some cases, additional information may be appended to the version string, separated by hyphens.
EXPORTED void PRE jsGetAPIVersion (
const char ** version_str
)
Parameters:
version_str
Address to be updated with API version string.
function jsGetError¶
Converts a jsError
error value returned from an API function call to a string value.
EXPORTED void PRE jsGetError (
int32_t return_code,
const char ** error_str
)
Parameters:
return_code
ThejsError
value returned from API call.error_str
Address to be updated with error string.
function jsPowerCycleScanHead¶
Performs a remote soft power cycle of a scan head.
EXPORTED int32_t jsPowerCycleScanHead (
uint32_t serial_number
)
Note:
This function will only work with scan heads running v16.x.x firmware or higher.
Note:
Extreme care should be used when using this function. The scan head being power cycled should NOT be connected or scanning. It is recommended to have the entire scan system in a disconnected state.
Note:
After this function successfully completes, it will take several seconds before the scan head will appear on the network and be available for use. On average, the scan head will take 30 seconds to reboot.
Parameters:
serial_number
The serial number of the scan head to power cycle.
Returns:
0
on success, negative value jsError
on error.
function jsScanHeadGetCapabilities¶
Obtains the capabilities for a given scan head.
EXPORTED int32_t PRE jsScanHeadGetCapabilities (
jsScanHead scan_head,
jsScanHeadCapabilities * capabilities
)
Parameters:
type
The scan head product type to obtain capabilities for.capabilities
Pointer to struct to be filled with capabilities.
Returns:
0
on success, negative value mapping to jsError
on error.
function jsScanHeadGetFirmwareVersion¶
Obtains the firmware version of the scan head presented as unsigned integer values.
EXPORTED int32_t PRE jsScanHeadGetFirmwareVersion (
jsScanHead scan_head,
uint32_t * major,
uint32_t * minor,
uint32_t * patch
)
Parameters:
major
The major version number.minor
The minor version number.patch
The patch version number.
Returns:
0
on success, negative value mapping to jsError
on error.
function jsScanHeadGetId¶
Obtains the ID of the scan head.
EXPORTED uint32_t PRE jsScanHeadGetId (
jsScanHead scan_head
)
Parameters:
scan_head
Reference to scan head.
Returns:
The numeric ID of the scan head.
function jsScanHeadGetLastErrorExtended¶
When a jsScanHead
function returns an error, this function can be called immediately after to obtain a more detailed message regarding the error.
EXPORTED int32_t PRE jsScanHeadGetLastErrorExtended (
jsScanHead scan_head,
const char ** error_extended_str
)
Note:
Calling another jsScanHead
function will clear the error message set from a previous function call.
Parameters:
scan_head
The scan head that encountered an error.error_extended_str
Address to be updated with detailed error string.
function jsScanHeadGetSerial¶
Obtains the serial number of the scan head.
EXPORTED uint32_t PRE jsScanHeadGetSerial (
jsScanHead scan_head
)
Parameters:
scan_head
Reference to scan head.
Returns:
The serial number of the scan head.
function jsScanHeadGetStatus¶
Reads the last reported status update from a scan head.
EXPORTED int32_t PRE jsScanHeadGetStatus (
jsScanHead scan_head,
jsScanHeadStatus * status
)
Parameters:
scan_head
Reference to scan head.status
Pointer to be updated with status contents.
Returns:
0
on success, negative value mapping to jsError
on error.
function jsScanSystemGetEncoder¶
DEPRECATED EXPORTED int PRE jsScanSystemGetEncoder (
jsScanSystem scan_system,
jsEncoder encoder,
int64_t * value
)
Deprecated
Will be removed in a future release. Use jsScanSystemGetScanSyncStatus
instead.
Returns:
JS_ERROR_DEPRECATED
.
function jsScanSystemGetLastErrorExtended¶
When a jsScanSystem
function returns an error, this function can be called immediately after to obtain a more detailed message regarding the error.
EXPORTED int32_t PRE jsScanSystemGetLastErrorExtended (
jsScanSystem scan_system,
const char ** error_extended_str
)
Note:
Calling another jsScanSystem
function will clear the error message set from a previous function call.
Parameters:
scan_system
The scan system that encountered an error.error_extended_str
Address to be updated with detailed error string.
function jsScanSystemGetScanHeadById¶
Obtains a reference to an existing jsScanHead
object.
EXPORTED jsScanHead PRE jsScanSystemGetScanHeadById (
jsScanSystem scan_system,
uint32_t id
)
Parameters:
scan_system
Reference to system that owns the scan head.id
The numeric ID of thejsScanHead
object.
Returns:
Positive valued token on success, negative value mapping to jsError
on error.