Main job from scratch?

  • Hello, I recently rejoined a former employer who bought 7 or so motoman xrc's and a mrc.
    I am having a devil of a time, I got into them, and was able to write subjobs just fine (welding) but the Main jobs are very bad, and cycle wrong, (the worst is actually acting like the switch (25 and 26) are shorted,, the machine will run perfect stepping through, or if I play with the cycle but the momen its in auto it just wants to do the called job continually! (I think the previous programmer had some variables in strange places and am not sure what he was thinking) Maybe I can write a new Main Job?


    XRC 2 arm machines mostly, arm type is YR UP20M with a UP20m Controller.

  • Nope, there is supposed to be a laptop, (older with pcmcia slots,,) but has possibly disapeared.
    I will need to key it all in on the machine, ( I will start shopping for a usb adapter to pcmcia)


    but the gist is similar to:


    Dout 26 OFF
    Dout 27 OFF
    Dout 30 ON
    *Loop
    IF I 26 Call 084 sub
    IF I 27 Call 085 sub
    Jump Loop


    I will copy down what they currently have (which is not working) then read some more and look for some examples, (we at another shop would use index switches for our variables,, operator would dial in job based on what the switch was,,later we added small allen bradley pc's running wince which would send variables to set jobs,, so we had a vary generic main job and spent our time on the called jobs,,,
    I have not mucked about with this in a long time..

  • YAY! I found a possible backup from a controls guy (I am not sure if this man initialized these or not,, but looks like his work was butchered, (these machines do not have the parellel start option,, (this may be a orginal motoman example? or ? but I like this,, and think this might be something I can splice and call my own jobs into,,, maybe)..(if I can restore this, does this look okay?) (I would like to have part numbers as job names then just call them in ,, (maybe later set up variables to change what job is called so operators can do changeovers,,) 1992 predates the xrc's so this was erc originally coded on?)



    here is some of the jobs,,


    main job below,,
    /JOB
    //NAME MAIN
    //POS
    ///NPOS 1,0,0,0,0,0
    ///TOOL 0
    ///POSTYPE PULSE
    ///PULSE
    C00000=-33,-58257,-130774,-164,38734,829
    //INST
    ///DATE 1992/01/22 23:44
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    MOVJ C00000 VJ=20.00
    DOUT OT#(25) OFF
    DOUT OT#(26) OFF
    DOUT OT#(29) OFF
    DOUT OT#(33) ON
    *LOOP
    CALL JOB:A_SIDE IF IN#(25)=ON
    CALL JOB:B_SIDE IF IN#(26)=ON
    TIMER T=0.10
    JUMP *LOOP
    END


    side a
    /JOB
    //NAME A_SIDE
    //POS
    ///NPOS 14,0,0,0,0,0
    ///TOOL 0
    ///POSTYPE PULSE
    ///PULSE
    C00000=-35,-58270,-130798,-165,38729,829
    C00001=-23223,-58270,-90935,-165,38728,829
    C00002=-53290,-54561,-96191,-23577,46584,19658
    C00003=-53351,-48598,-108700,-36702,55891,27214
    C00004=-56216,-44380,-105048,-39222,55297,29341
    C00005=-51728,-53239,-105376,-25977,51401,21119
    C00006=-8715,-63179,-91238,6638,35489,-6105
    C00007=-53290,-54561,-96191,-23577,46584,19658
    C00008=-52084,-46336,-105501,-29733,54688,23662
    C00009=-55526,-41622,-101564,-32710,54253,26212
    C00010=-52370,-54711,-106795,-26223,51048,21381
    C00011=-33496,-75784,-121763,-10088,50299,8025
    C00012=-9068,-84404,-102584,260,21981,2018
    C00013=-35,-58270,-130798,-165,38729,829
    //INST
    ///DATE 1992/01/24 16:23
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    MOVJ C00000 VJ=20.00
    '********************************
    '********************************
    '********************************
    'START ROBOT 2 A SIDE WELD 1
    DOUT OT#(25) ON
    WAIT IN#(27)=ON
    WAIT IN#(29)=OFF
    WAIT IN#(32)=OFF
    DOUT OT#(25) OFF
    '********************************
    '********************************
    '********************************
    'START WELD 1
    MOVJ C00001 VJ=20.00
    CALL JOB:ENTER_ZN
    MOVL C00002 V=250.0
    MOVL C00003 V=250.0
    ARCON AC=290 AV=20.0 V=5.5
    MOVL C00004 V=8.5
    ARCOF
    MOVL C00005 V=84.7
    MOVL C00006 V=250.0
    CALL JOB:EXIT_ZN
    'WELD 1 FINISHED
    '********************************
    '********************************
    '********************************
    'WAIT ROBOT 2 A SIDE WELD 1 DONE
    WAIT IN#(25)=ON
    'START ROBOT 2 A SIDE WELD 2
    DOUT OT#(29) ON
    WAIT IN#(29)=ON
    DOUT OT#(29) OFF
    '********************************
    '********************************
    '********************************
    'WELD 2
    CALL JOB:ENTER_ZN
    MOVL C00007 V=250.0
    MOVL C00008 V=250.0
    ARCON AC=290 AV=20.0 V=5.5
    MOVL C00009 V=8.5
    ARCOF
    MOVL C00010 V=84.7
    MOVL C00011 V=84.7
    CALL JOB:EXIT_ZN
    'WELD 2 FINISHED
    '********************************
    '********************************
    '********************************
    'WAIT ROBOT 2 A SIDE WELD 2 DONE
    WAIT IN#(32)=ON
    MOVL C00012 V=84.7
    CALL JOB:CLEAN
    MOVL C00013 V=211.7
    END


    side b
    /JOB
    //NAME B_SIDE
    //POS
    ///NPOS 4,0,0,0,0,0
    ///TOOL 0
    ///POSTYPE PULSE
    ///PULSE
    C00000=-35,-58270,-130798,-165,38729,829
    C00001=49436,-63180,-91241,6638,35489,-6104
    C00002=49436,-60301,-107133,7900,44286,-7122
    C00003=-35,-58271,-130801,-164,38729,828
    //INST
    ///DATE 1992/01/23 21:30
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    MOVJ C00000 VJ=20.00
    '********************************
    '********************************
    '********************************
    'START ROBOT 2 B SIDE WELD 1
    DOUT OT#(26) ON
    WAIT IN#(28)=ON
    WAIT IN#(29)=OFF
    WAIT IN#(32)=OFF
    DOUT OT#(26) OFF
    '********************************
    '********************************
    '********************************
    'START WELD 1
    MOVJ C00001 VJ=20.00
    TIMER T=5.00
    'WELD 1 FINISHED
    '********************************
    '********************************
    '********************************
    'WAIT ROBOT 2 B SIDE WELD 1 DONE
    WAIT IN#(26)=ON
    'START ROBOT 2 B SIDE WELD 2
    DOUT OT#(29) ON
    WAIT IN#(29)=ON
    DOUT OT#(29) OFF
    '********************************
    '********************************
    '********************************
    'WELD 2
    MOVJ C00002 VJ=20.00
    TIMER T=5.00
    'WELD 2 FINISHED
    '********************************
    '********************************
    '********************************
    'WAIT ROBOT 2 B SIDE WELD 2 DONE
    MOVJ C00003 VJ=20.00
    WAIT IN#(32)=ON
    END



    zn
    /JOB
    //NAME ENTER_ZN
    //POS
    ///NPOS 0,0,0,0,0,0
    //INST
    ///DATE 1992/01/23 14:59
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    '********************************
    '********************************
    '********************************
    'WAIT ROBOT 2 CLR OF ZONE
    WAIT IN#(33)=ON
    DOUT OT#(33) OFF
    TIMER T=0.30
    WAIT IN#(33)=ON
    END



    zn out
    /JOB
    //NAME EXIT_ZN
    //POS
    ///NPOS 0,0,0,0,0,0
    //INST
    ///DATE 1992/01/23 14:59
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    DOUT OT#(33) ON
    END


    cleaner
    /JOB
    //NAME CLEAN
    //POS
    ///NPOS 13,0,0,0,0,0
    ///TOOL 0
    ///POSTYPE PULSE
    ///PULSE
    C00000=-47530,-63002,-85032,-22633,30749,22399
    C00001=-96789,-38830,-82271,-42179,22767,45221
    C00002=-96789,-34370,-89693,-44527,26671,48096
    C00003=-96789,-38830,-82271,-42179,22767,45221
    C00004=-92415,-48225,-91700,-41717,24042,43576
    C00005=-92633,-43164,-100436,-44637,28487,47010
    C00006=-92397,-42781,-100495,-44762,28747,47077
    C00007=-92660,-43319,-100311,-44567,28382,46941
    C00008=-92441,-48205,-91830,-41743,24077,43615
    C00009=-97997,-29019,-70594,-42266,22379,45648
    C00010=-97997,-25430,-77150,-44195,25704,48069
    C00011=-97997,-29019,-70594,-42266,22379,45648
    C00012=-32072,-54021,-76020,-19205,27698,14297
    //INST
    ///DATE 1992/01/24 15:10
    ///ATTR SC,RW
    ///GROUP1 RB1
    NOP
    MOVJ C00000 VJ=20.00
    CALL JOB:ENTER_ZN
    MOVL C00001 V=250.0
    WAIT IN#(8)=ON
    MOVL C00002 V=100.0 PL=0
    DOUT OT#(6) ON
    TIMER T=0.50
    DOUT OT#(5) ON
    TIMER T=2.00
    WAIT IN#(8)=OFF
    DOUT OT#(5) OFF
    TIMER T=2.00
    WAIT IN#(8)=ON
    DOUT OT#(6) OFF
    TIMER T=1.00
    MOVL C00003 V=250.0
    MOVL C00004 V=250.0
    MOVL C00005 V=250.0
    MOVL C00006 V=50.0 PL=0
    PULSE OT#(191) T=0.50
    TIMER T=1.00
    DOUT OT#(7) ON
    TIMER T=0.50
    DOUT OT#(7) OFF
    TIMER T=0.50
    MOVL C00007 V=16.7
    MOVL C00008 V=83.3
    MOVL C00009 V=83.3
    MOVL C00010 V=83.3 PL=0
    DOUT OT#(8) ON
    TIMER T=0.50
    DOUT OT#(8) OFF
    MOVL C00011 V=83.3
    MOVL C00012 V=250.0
    CALL JOB:EXIT_ZN
    END

  • I dont see anything wrong with the jobs


    As far as
    DOUT OT#(33) ON
    *LOOP
    CALL JOB:A_SIDE IF IN#(25)=ON
    CALL JOB:B_SIDE IF IN#(26)=ON
    TIMER T=0.10
    JUMP *LOOP
    END
    I assuming your problem is that you always have 25 or 25 so the robot always run.
    Let say you add a pushbutton to IN24, you could do


    *LOOP
    CALL JOB:A_SIDE IF IN#(25)=ON
    JUMP *END
    CALL JOB:B_SIDE IF IN#(26)=ON
    JUMP *END
    *END
    WAIT IN#24 ON
    JUMP *LOOP


    So, now until you dont push the PB neither side will run

    Retired but still helping

Advertising from our partners