Assuming you have a virtual axis (i.e. an axis to which you have not assigned an axis profile), you can use command ctrl-based-homing to affect an immediate position change. For example, use the msg.payload below to set the axis position to 180 units. Axis power required.
{
"type": "object",
"value": {
"homingParam": {
"newRefPos": 180,
"travelDisLim": 0,
"homingDir": "+",
"refType": "STOPPED_POS",
"dynForward": {
"vel": 1,
"acc": 1,
"dec": 1,
"jrkAcc": 0,
"jrkDec": 0
},
"dynBackward": {
"vel": 1,
"acc": 1,
"dec": 1,
"jrkAcc": 0,
"jrkDec": 0
},
"refMode": "SET_POS_DEVICE"
}
}
}
Sample Node-RED flow attached. ctrlX CORE 2.4.x.
... View more