kernelv_ch_get_total_cs_rot_matrix()
Prototype
KERNELV_RETURN
| kernelv_ch_get_total_cs_rot_matrix(unsigned long int chanIndex,
|
Description
Returns the rotation matrix generated by concatenating all active coordinate systems.
The rotation matrix generated by the parameters ϕ1, ϕ2 ϕ3 of the following NC command is returned:
#CS DEF [CS1] [ <v1>,<v2>,<v3>,<ϕ1>,<ϕ2>,<ϕ3> ]
If no coordinate system is active, the standard matrix is returned.
Parameter
Name | Type | Meaning |
chanIndex | unsigned long | Channel index of the channel. |
matrix | double* | Pointer to the memory location for the rotation matrix. |
bufferSize | unsigned long | Length of the memory area for the rotation matrix must be at least 3 x 3 x sizeof(double). |
returnLength | unsigned long* | Pointer to the value to which the actually returned number of bytes is to be written. If the transferred memory is too small for the return value, the return value ERR_CNC_RET_MEMORY is returned and this parameter returns the required memory size. |
Return values
Symbol | Value | Meaning |
RET_FINISHED | 0 | The function was executed without error. |
ERR_INVALID_CHAN | -1 | The transferred channel index is higher than the number of configured channels –1 |
ERR_CNC_NOT_INIT | -3 | The simulation CNC kernel was not yet initialised. |
ERR_CNC_RET_MEMORY | -4 | The return value(s) does/do not fit into the memory provided. In this case, the minimum size required for the return is returned in returnLength. |