RobotStudio event

How to stop moving 6 axis?

Options
Dear all

I'm Jim from Taiwan.
This is my first time to control robot arm.
I've a question about robot moving.
When I moving my robot to specific position, the robot's 6 axis was also turning.
the 6 axis direction will be the same as Robot direction.
How to stop the 6 axis turning?

Before I move the robot, I copy the CRobT() then change the pos to where I want and
also change the confdata. Is it possible to make this effect like it?



                target_p := CRobT();
                target_p.trans := position;
                target_p.robconf := fillConfdata(target_p.trans);
                MoveJ target_p,v3000,z200,target_tool\WObj:=target_wobj;

    FUNC confdata fillConfdata(pos tarPos)
        VAR confdata rlt;
        VAR robtarget tmp;
        tmp := CRobT(\Tool:=target_tool \WObj:=target_wobj);
        rlt := tmp.robconf;
       
       
        IF (tarPos.x >= 0) AND (tarPos.y >= 0) THEN
            rlt.cf1 := 0;

        ELSEIF (tarPos.x < 0) AND (tarPos.y >= 0) THEN
            rlt.cf1 := 1;

        ELSEIF (tarPos.x >= 0) AND (tarPos.y < 0) THEN
            rlt.cf1 := -1;

        ELSE
            rlt.cf1 := -2;
        ENDIF
           
        RETURN rlt;
    ENDFUNC

Please help me to fix this issue.









Comments

  • Rafał
    Options
    I am not sure if I have good understanding of your problem, but if you want to keep orientation of robot tool you can use OFFS function, or RelTool function, or just create new targets with desired orientation and configuration
  • JimYu
    Options
    Thank you. I fixed this problem. Just need to trun the orientation of robot to 90 degree.
    the axis 6  direction will be the same as axis 1.

    I am sorry about my poor English..XD