/******** 轴原点搜索*********//
IF HOME_COMMNDE_BIT AND (NOT AXIS_BUSY) AND (NOT AXIS_EROOR) AND (NOT AXIS_POSITION_DONE) AND(NOT AXIS_POSITION_MOVING) THEN
AXIS_POSITION_BUFFER:=9001;HOME_COMMNDE_TEMP:=TRUE;
ELSE
HOME_COMMNDE_TEMP:=FALSE;
END_IF;
//原点触发,轴不忙,轴无错误,轴无定位完成,轴无定位启动信号;
//******** 轴定位启动*********//
IF POSITION_BIT AND (NOT AXIS_BUSY) AND (NOT AXIS_EROOR) AND (NOT AXIS_POSITION_DONE) AND(NOT AXIS_POSITION_MOVING) THEN
AXIS_POSITION_BUFFER:=1;POSITION_TEMP:=TRUE;
ELSE
POSITION_TEMP:=FALSE;
END_IF;
//定位触发,轴不忙,轴无错误,轴无定位完成,轴无定位启动信号;
//******** 轴定位置位*********//
SET( (HOME_COMMNDE_TEMP OR POSITION_TEMP),AXIS_POSITION_MOVING);
//******** 轴定位复位*********//
RST((AXIS_POSITION_DONE OR AXIS_BUSY)AND AXIS_POSITION_MOVING AND (NOT AXIS_BUSY)),AXIS_POSITION_MOVING);