Stop programpointer without stopping Robot

Hi

I'm trying to optimize an Glue robot. Between every glue-string there is an Checkbead to check if the Glue-string was ok or not.
This takes cycletime, approx 1 sec per bead.

Been trying to optimze this and not to stop the robot inside the Checkbead routine but without success. 

The problem is that the robot stops in an Waittime/inpos instruction. This instruction is used cause the program pointer jump's so much forward in the rapid code. If we don't use the
waittime/inpos instruction the Program pointer resets the bead so we don't get any glue.

My question is if there is any instruction I can use to stop the program pointer without stopping the robot. Anyone who had similar problems?


Here is the code in the "work-routine"

Proc Myworkroutine()

        Toolchange Doser511;

        PrepareEquipment Doser511,HomeDoser511;

        Doser511AutoPurgeSch;

        !

        MoveAbsJ HomeDoser511,vmax,fine,Doser511TCP;

        !

        MoveJ ToBS1_10,v2000,z50,Doser511TCP\WObj:=BSStn020;

        PrepareBead bdbead 1_1;

        MoveL ToBSdb30,v2000,z50,Doser511TCP\WObj:=BSStn020;

        !

        DispL\ON,BSdb_Start,v150,bdbead1_1,z5,Doser511TCP\WObj:=BSStn020;

        DispL\OFF,BSdb70,v150,bdbead1_1,z5,Doser511TCP\WObj:=BSStn020;

        MoveL BSdb71, v150, z50, Doser511TCP\WObj:=BSStn020;

        CheckBead bdbead1_1;

        PrepareBead bdbead2_1;

        DispL\ON,BSdb50,v150,bdbead2_1,z5,Doser511TCP\WObj:=BSStn020;

        DispL\OFF,BSdb60,v150,bdbead2_1,z5,Doser511TCP\WObj:=BSStn020;

        MoveL BSdb70, v150, z50, Doser511TCP\WObj:=BSStn020;

        CheckBead bdbead2_1;

        PrepareBead bdbead3_1;

        DispL\ON,BSdb73,v150, bdbead3_1,z5,Doser511TCP\WObj:=BSStn020;

        DispL\OFF,BSdbEnd,v150, bdbead 3_1,z5,Doser511TCP\WObj:=BSStn020;

        MoveL ToBSdb30, v150, z50, Doser511TCP\WObj:=BSStn020;

        !

        CheckBead bdbead 3_1;

 _____________________________________________________________________________________________________________

Here is the code inside the Checkbead routine

Proc Checkbead()

        IF dp_dry=FALSE THEN

            !----------------------------

            ! Wait until previous bead finished  

            !----------------------------                                                                                                                       

            WaitUntil NewBeadOk=TRUE\MaxTime:=10\TimeFlag:=timeout\PollRate:=0.02;

            WaitUntil DInput(I_BeadActive)=0\MaxTime:=30\TimeFlag:=timeout\PollRate:=0.02;

            WaitTime\InPos,0;

            !----------------------------

            ! Reset Bead number to disp. equipment

            !----------------------------                                                                                                                  

            WaitTime 0.02;

           SetGO GO_BeadNo,0;

           SetGO GO_PartAreaNo,0;

            !CheckInput I_ReadyToDose,1\CheckTimeOut:=3\AlarmNumber:=A_DispSystemNotOK,strVolumeError531;

            WaitTime 0.03;

            !----------------------------

            ! Save the bead cons. to memory Volume    

            !----------------------------                                                                                                                       

            Volume:=(AI_BeadCons);

            !----------------------------

            ! Check if the volume in the bead was OK   

            !----------------------------                                                                                                                                                      

            IF DInput(I_BeadVolumeOk)=0 THEN

                !----------------------------

                ! Set local variable O_ErrorApplic           

                !----------------------------                                                                                                                                                  

                SetDO O_ErrorApplic,1;

                !----------------------------

                ! Ändrat 180116 för att spara volumfel till bVolumeFault

                bVolumeFault:=TRUE;

                !----------------------------

                ! Get errortext        

                !----------------------------                                                                                                                                                  

                SaveDispErrorTxt;

                !----------------------------

                ! Asign information to Disp_ErrorTxt

                !----------------------------                                                                                                                                                                                                  

                Disp_ErrorTxt{8}:=targetId;

                Disp_ErrorTxt{9}:="   Material consumption "+NumToStr(Volume,3)+"CCM";

                Disp_ErrorTxt{19}:=targetId;

                Disp_ErrorTxt{20}:="   Material förbrukning "+NumToStr(Volume,3)+"CCM";

                !----------------------------

                ! Operator comunication

                !----------------------------

                !CheckInput I_BeadVolumeOk,1\CheckTimeOut:=3\AlarmNumber:=A_DispSystemNotOK,strVolumeError531;

                WHILE DInput(I_BeadVolumeOk)=0 DO

                    ErrDisplay 1,key_in,A_DispVolumeError,Disp_ErrorTxt,stBuPROCEED_5\stProcessID:=processId;

                    !----------------------------

                    ! Reset alarm in disp. equipment

                    !----------------------------                                                                                                                                                                                                              

                    PulseDO\High\PLength:=1,O_ResetAlarms;

                    !----------------------------

                    WaitTime 1.2;

                ENDWHILE

                !ErrDisplay 1, key_in, A_DispVolumeError,Disp_ErrorTxt,stBuPROCEED_5\stProcessID:=processId; 

                ! Reset alarm in PLC

                !----------------------------                                                                                                                                                                                                  

                SendAlarm A_DispVolumeError,""\sum_alarm\Reset;

 

Comments

Sign In or Register to comment.