S.B.C. Elettronica S.p.A. - Engineering Division
HPDxxN – High Power User’s Manual
58
Example 6: filter (600 msec) for reading the value of a parameter
Example 7: homing
If you are using an operating mode with spatial control (9, 10 or 11) and you need to align the
motor with a zero position defined by a proximity sensor when the system is powered up. You can
use two digital inputs, one for the homing command and one to acquire the proximity sensor signal.
The commands are pulse type and the homing command is executed once only.
After setting the default values set up the required operating mode (Pr31=xx, b99.11=1,
b40.2=1, and any other settings required) and then set the homing speed for the zero proximity
sensor in Pr5 and set b40.12=1 to enable Pr5 when b40.2 reaches zero.
Terminal 13 on X3 = pulse command - execute homing.
Terminal 14 on X3 = PNP axis zero proximity sensor.
Bit b91.10 is utilised to signal that the operation is terminated. Note that bits from b91.8 to b91.15
are at the disposal of the PLC and cannot be stored in the memory.
The program is as follows:
SUB
ADD
DIV
99.13
81.15
60 60 60
35 60 60
60 76 81
ADD
92 76 92
MUL
81 71 81
99.0
LD
99.13
ADD
35,60,60
LD
99.0
DIV
60,76,81
SUB
60,60,60
ADD
92,76,92
LD
81.15
MUL
81,71,81
Add Pr35 and Pr60
if timer 1 expired calculate filtered Pr35
setting result in Pr81
zero set Pr60
reset time m 1 to 600 milliseconds
if Pr81 is negative its sign changes
RST
90.2
91.10
40.2
91.10
90.3
91.10
SET
40.2
SET
70.10
SET
91.10
LD
90.2
ANDN
91.10
RST
40.2
LD
91.10
SET
40.2
LD
90.3
ANDN
91.10
SET
70.10
SET
91.10
If homing command not
executed, disables operating
mode
If homing command executed,
re-enables operating mode
if proximity switch operated
resets operating mode counters
sets homing executed flag