14.01.2015 Views

Gemini GV6K and Gemini GT6K Programmer's Guide

Gemini GV6K and Gemini GT6K Programmer's Guide

Gemini GV6K and Gemini GT6K Programmer's Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Profile<br />

<br />

<br />

<br />

Program<br />

<br />

<br />

; Setup code<br />

FOLMAS1<br />

FOLEN1<br />

INFNC1-H<br />

<br />

<br />

<br />

<br />

<br />

; Master is coming in on the master encoder input<br />

; Enable Following<br />

; Assign onboard input 1 (TRG-1A) as trigger interrupt<br />

; Motion program<br />

DEL EXPL2<br />

; Delete program (in case it already exists in memory)<br />

DEF EXPL2 ; Begin definition of program example 2<br />

1TRGFNA1<br />

; Launch axis 1 profile upon receiving TRG-1A<br />

; (1st product detected)<br />

PLOOP0<br />

; Loop continuously to mimic a mechanical cam<br />

; Program first move - dwell<br />

FOLRN1<br />

; Set up ratios - numerator<br />

FOLRD1<br />

; <strong>and</strong> denominator<br />

FOLMD2000<br />

; Over a distance of 2000 master steps<br />

D0<br />

; slave will not move<br />

FOLRNF0<br />

; <strong>and</strong> end at zero ratio<br />

GOBUF1<br />

; Build motion<br />

; Program second move - positive slave move<br />

FOLMD6000<br />

; Over a distance of 6000 master steps<br />

D4000<br />

; slave will move 4000 steps<br />

FOLRNF0<br />

; <strong>and</strong> end at zero ratio<br />

GOBUF1<br />

; Build motion<br />

; Program third move - negative slave move<br />

FOLRN3<br />

; New ratio to accommodate larger distance of slave travel<br />

FOLMD2000<br />

; Over a distance of 2000 master steps<br />

D-4000 ; slave will move -4000 steps<br />

FOLRNF0<br />

; <strong>and</strong> end at zero ratio<br />

GOBUF1<br />

; Build motion<br />

; Program last move - dwell<br />

FOLMD2000<br />

; Over a distance of 2000 master steps<br />

D0<br />

; slave will not move<br />

FOLRNF0<br />

; <strong>and</strong> end at zero ratio<br />

GOBUF1<br />

; Build motion<br />

PLN1<br />

; Close cam loop<br />

END ; End program example 2<br />

PCOMP EXPL2 ; Compile program EXPL2<br />

; ** To execute the program, enter the PRUN EXPL2 comm<strong>and</strong> **<br />

Chapter 6. Following 149

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!