PMAC Product Guide Examples: #1HM ; Do homing search move on Motor 1 J:2000 ; Jog a distance of 2000 counts (to 2000 counts) J:2000 ; Jog a distance of 2000 counts (to 4000 counts) J:* Function : Jog to specified variable distance from present commanded position Scope : Motor specific Syntax : J:* This command causes the addressed motor to jog the distance specified in the motor’s variable jog position/distance register relative to the present commanded position. Jogging acceleration and velocity are determined by the values of Ix19-Ix22 in force at the time of this command. Compare to J^* which is a jog relative to the present actual position.
The variable jog position/distance register is a floating-point register with units of counts. It is best accessed with a floating-point M-Variable. The register is located at PMAC address L:$082B for motor 1, L:$08EB for motor 2, etc. The usual procedure is to write the destination position to this register by assigning a value to the M-Variable, then issuing the J:* command. PMAC will reject this command if the motor is in a coordinate system that is currently running a motion program (reporting ERR001 if I6 is 1 or 3). Examples:
M172->L:$082B ; Define #1 variable jog position/distance register #1HMZ ; Declare present position to be zero M172=3000 ; Assign distance value to register #1J:* ; Jog Motor 1 this distance; end cmd. pos. will be 3000 #1J:* ; Jog Motor 1 this distance; end cmd. pos. will be 6000 M172=P1*SIN(P2) ; Assign new distance value to register #1J:* ; Jog Motor 1 this distance #1J= ; Return to pre-jog target position J= Function : Jog to prejog position Scope : Motor specific Syntax : J= This command causes the addressed motor to jog to the last pre-jog and pre-handwheel-move position (the most recent programmed position).
Jogging acceleration and velocity are determined by the values of Ix19-Ix22 in force at the time of this command. The register containing this position information for the motor is called the target position register (D:$080B for Motor 1, D:$08CB for Motor 2, etc.). Suggested M-Variable definitions M163, M263, etc. can be used in programs to give access to these registers. If the / or \ stop command has been used to suspend program execution and one or more motors jogged away from the stop position, the J= command must be used to return the motor(s) back to the stop position before program execution can be resumed.
The J= command can be useful also if a program has been aborted in the middle of a move, because it will move the motor to the programmed move end position (provided I13=0 so PMAC is not in segmentation mode), so the program may be resumed properly from that point. 168 Online Commands