Validity: Rule, Task
This keyword allows a conversion K factor to be defined between the quota detected in bits at the transducer (rawcp) and the desired logical unit of measurement. This K is also active in cycle of 0 modes.
Syntax |
REAL kbit2unit (I32 n) |
---|---|
n |
Index of the axis to which kbit2unit is applied. Minimum representable number: 1 Maximum representable number: 32 |
Doing so, all bit references are replaced with the chosen units.
In case of incremental encoder the counting is done by counting the edges, so in case of encoder of 1024 pulses the number of bits per revolution is equal to 1024*4.
Figure:
NOTE: From RTE 33.18, from configurator it is possible to disable the retentivity of this parameter(DIS_AXES_PAR_RE).
Example
; axis 1 with ; 1024 pulses/revolution encoder ; reduction ratio 1 to 2 ; screw with 5 mm pitch ; The conversion K will result to be: ; units in millimeters KBIT2UNIT(1) = 5.0/((1024.0 * 4.0) * 2.0) ; units in centimeters KBIT2UNIT(1) = 0.5/((1024.0 * 4.0) * 2.0) ; units in meters KBIT2UNIT(1) = 0.005/((1024.0 * 4.0) * 2.0) |