; Let AB-ABC-BC be the sequential state and vice versa
INC RO; Next state
; Determine whether 10 states have been completed. If it is reached, execute it sequentially. If it does not reach 10 times, jump to ZZ
; assign a value of 0
; give the next state to A
; call Table ABC gives the pointer DPTR
; adds the state offset A
; outputs A
; returns the call
; abc table It’s the trademark content
;================================
;Return to the previous state
;Judge whether it is <0, if less, execute sequentially, otherwise jump to FZ
;Assign 9
;Put the next Give a state to A
; call table ABC to pointer DPTR
; add state offset A
; output A
;Return call
The program in the following 2 sections is similar to this. Only the contents of the tables are different. The reason is that the one above uses a five-phase ten-beat stepper motor working mode; the one below uses a five-phase ten-beat stepper motor working mode.