Hi,
Sorry to bother you, I have some trouble which pullze me some time, could you please give me some advice.
I am trying to control a step motor.
Now I want to set a number(60) to pv(um distance), send the number*20(60*20=1200) to device. I think CALC would be useful. I could not understand CALC well though I have RRM 3-14.
The following code is what I do.
Thanks!
*******devKohzuAries.db
record(longin,"RPS") # send to device
{
field(DESC, "move relativly")
field(DTYP, "stream")
field(INP, "@devKohzuAries.proto RPS $(PORT) $(A)")
field(FLNK,"um distance")
}
record(calcout,"um distance")
{
field(DTYP,"stream")
field(OUT,"@devKohzuAries.proto RPS $(PORT) $(A)")
field(CALC,"A*20")
field(INPA,"um distance.VAL")
}
******** devKohzuAries.proto
RPS{
out "\x02RPS1/5/%d/0";
}
Liang YX
Institute of High Energy Physics
Chinese Academy of Sciences
P. O. Box 918, 100049 Beijing
R. P. China
Tel: 0086-0188235977-603
Email: [email protected]