Thanks SkyeFire, this helps too. As I was working out the details in my planner, some things seemed wrong or overlooked in the documentation.
Posts by mjnewsum
-
-
Thanks Hes ! That helps a ton. This doesn't look to difficult at all.
-
Hey, I have been developing software for simulating robots. I have an Inverse Kinematic solver, and I usually set a starting FK pose for the first position then all the LIN moves are base on that pose.
One of the customers I am working with wants the first position to be a PTP move to a E6POS with S and T values instead of a PTP move to a E6AXIS pose.
I haven't found good documentation for status and turn. I am assuming I could take my FK pose and determine these values if I knew the logic.
Is there a document that describes what the binary values for S and T represent? I know I have seen it before, but I can't figure out where it was.
-
I am working with a KRC5 with KSS 8.6.9 KR70 R2100 with an external axis.
The process the robot is doing has the external axis rotating for a long time in one direction.
Right now, we are running a program to unwind the axis after a process is complete, because we have run into an integer overflow error before.
I want to know if there is a command that will "master" the external axis or set the degrees to 0.0 so we don't have to unwind?
Our starting angle doesn't really matter, but we could go the the nearest (angle % 360 = 0.0) before mastering if needed.
I feel like I am missing something in the programming manual that would solve this issue without these kinds of shenanigans.
Thanks for the help in advance! Please let me know if you need any additional information.
-
Thanks Fubini, I haven't ever messed with $SR_VEL_RED or $SR_OV_RED.
This makes sense for what I was I was seeing, so I will dig into those options when I am near that machine again.
-
Hey all, I am running some test to validate I am limiting the speed of my robot correctly.
I am using a KRC5 8.7.5 with a KR 20 R1810-2.
I have read through this post which was very helpful, but I still had some questions.
How to limt the speed of KUKA robotI setup this simple program to make the robot Move at 200 mm, Twist 30 degrees, Swivel 30 degrees, then return to the starting position before I set any limits on the velocity.
I ran the program before and after setting a velocity limit at 20 mm.
I was doing this to check multiple things:- make sure the velocity limit would slow down my tool after setting velocity limit
- I monitored $VEL_ACT while running to see the speed reduction
- Before limiting velocity, $VEL_ACT topped out at 180 mm/s
- After limiting velocity, $VEL_ACT topped out at 15mm/s
- I am not sure why I wasn't getting up to the set velocity. My LIN move seemed long enough to accelerate to 200 mm/s.
- I monitored $VEL_ACT while running to see the speed reduction
- see if any warnings or errors are thrown if I exceed my set limit
- No warnings or errors popped up when I commanded a most at 200mm when the limit was set to 20m
- I guess this is something I could check for in the submit and throw my own warnings
- No warnings or errors popped up when I commanded a most at 200mm when the limit was set to 20m
- confirm that swivel and twist would happen at the same speed after setting the velocity limit if the point of the positions were the same
- Swivel and Twist happened at the same speed with or without the velocity limit (as assumed)
- I changed $VEL.ORI1 and $VEL.ORI2 to control the rotations speeds
- This doesn't seem like a "safe" way to limit the robot
- I guess my only real option is to limit the degrees/s for the axis of the arm
Code
Display MoreDECL E6POS startPos DECL E6POS endPos DECL E6POS twistPos DECL E6POS swivPos ;make positions startPos = $POS_Act endPos = startPos endPos.Y = endPos.Y + 200 twistPos = endPos twistPos.c = twistPos.c - 30 swivPos = endPos : {x 0,y 0, z 0,a 30,b 0,c 0} ;set coordinates BAS (#INITMOV, 0) FDAT_ACT.TOOL_NO = 0 FDAT_ACT.BASE_NO = 0 BAS (#FRAMES) ;set speed $APO.CDIS = 20 BAS(#VEL_CP, 200) $vel.ori1 = 200 $vel.ori2 = 200 ;move PTP $AXIS_ACT LIN startPos LIN endPos LIN twistPos LIN endPos LIN swivPos LIN endPos LIN startPos
I have a couple of questions ( sorry if I provided too much information up front ).
- Is there a reason why the robot went slower than my commanded velocity?
- I can understand why it didn't reach 200 mm/s before the set limit, but I don't understand why it couldn't get to 20 mm/s with the limit on the exact same move.
- Is there any other "safe" way to limit ORI1 and ORI2 directly other than limiting the degrees/s of the Axis?
- Is there a way to make the robot report warnings if the set velocity exceeds the Velocity limit
- Is there a way to make the robot report warnings if the joint speed is commanded to exceed rotation limits?
Thank you for the help in advance! I hope this post is informative and helpful for others as well.
- make sure the velocity limit would slow down my tool after setting velocity limit
-
Thank you panic mode ! Those details help a lot, and thank you for the very very clear example for testing and understanding.
-
Fubini do you know where I could look for more information about KUKA data types?
I have looked around, but I can't seem to find what the max value would be for a REAL, so I can know how much precision is being lost each time we go another digit of revolutions. -
We have our external axis set so that we can go from +179 to -179 and it will only rotate the 2 degrees, so we don't have to specify really large numbers. I am wondering, if the external axis has rotated 10,000 revolutions for whatever reason, and we tell it to go to 120.456789123, will the the decimal values be truncated in some way to lose precision in the actual position of the axis?
-
-
I want to know if I am losing some precision if I let my rotary axis rotate 10,000s of revolutions.
I noticed, when I show the $AXIS_ACT value, I only get a couple of decimal places on my rotary axis and it has many more integer values than any other axis.
I don't know if there is a way to see the full precision of the REAL value, or if what I am seeing is all that can be known because of the limitations of 32-bit REAL.
If I am losing precision, is there anything I can do to keep my external axis value low so I have better decimal precision? I don't need to know that I have rotated millions of degrees... Is there any way to set the value back to 0.0 without re-mastering the axis?
-
hermann that is correct. After getting the turntable integrated correctly into the motion, it did move the arm in and out along the motion. I put in a variable to control the angle that is added to E1 each loop. Right now it is running with 1 degree, but that could be an issue if the robot is very close to the center of the table. I wanted to do this with CIRC moves, but was advised to avoid them without a good reason why. I think lots of people just have had bad experiences with CIRC moves so they linearize the arc at some resolution.
-
Ok, I figured out the issue. I was not using BAS(#FRAMES ) and I guess there is something in Frames ( ) that was required to the motion to work correctly in the moving frame of the turntable.
Here's what I had to do.
CodeBAS (#INITMOV, 0) ROBOT_FRAME.TOOL_NO = tool ROBOT_FRAME.BASE_NO = base FDAT_ACT = ROBOT_FRAME BAS (#FRAMES )
Thank you all for the help! This was a very confusing little problem. This was the first time I am making a program from scratch that runs on a robot using a turntable as the coordinate system. I'm not sure what in Frames ( ) made the difference, but I will use the BAS functions more in the future.
hermann You are totally correct. The last program I posed is using Base[2] which is the integrated base of the turntable. Instead of calculating where the points will be or figuring out the ABC angles, I used an FK E6AXIS pose as the variable that I could modify E1. Then, I used Forward() to get the E6POS position of that pose. Then I can LIN to the position. That way, I get everything other that E1 calculated by the controller (XYZABC). I think it is a nice way to do it. This will let me put the tool in any position and any orientation and still drive the turntable at a set velocity relative to the current tool position.
-
I realized I forgot C_DIS after LIN position. Tried that and it didn't change anything. I also tried C_VEL.
I also tried adding $APO settings, but that didn't do anything either.
$APO.CDIS = 10.0
$APO.CVEL = 100
I am really stumped. I can't figure out why it pauses between each move. It is like $Advance is not actually being read or something.
-
Ok, so I tried converting E6Axis to E6Pos, and that motion works well. The robot goes where I want it to.
But, the robot still pauses at every position. I am not using our typical base. I don't understand why the robot keeps pausing.Code
Display MoreDEF noDatSpin ( ) DECL E6POS position DECL E6AXIS pose DECL int status GLOBAL INTERRUPT DECL 3 WHEN $STOPMESS==TRUE DO IR_STOPM ( ) INTERRUPT ON 3 BAS (#INITMOV, 0) BAS (#TOOL, 5) BAS (#BASE, 2) pose = $AXIS_ACT status = 0 PTP pose $ADVANCE = 5 $VEL.CP=0.25 WHILE TRUE pose.E1 = pose.E1 + 90 position = Forward(pose, status) LIN position ENDWHILE END
-
Thanks for explaining that @skyfire. Is there any way to set the PTP velocity to be relative to where the TCP is located?
I was trying to think through another idea of just having the pose as an E6Axis type.
pose = $AXIS_ACT
While true
pose.E1 = pose.E1 + 90
; convert E6Axis to E6Pos position using tool and base
LIN position
EndWhile
I am not sure how to convert an E6Axis to an E6Pos. Is that possible?
Edit - I looked into it more and I think the Forward function should get me the E6POS I am looking for. Trying this next.
-
SkyeFire I modified the program to use PTP. The turntable did not pause, but I seem to have almost no control of the rotation speed. The turn tables moves very slowly no matter what I set in PDAT_ACT.
I did notice a very strange behavior in this program. If I Block Select the PDAT_ACT line, the turn table would turn much faster (I am assuming this is the speed I set). The turntable would turn at the faster speed for one move then go back to a painfully slow speed that it would normally go if I did not block select the PDAT_ACT line. Not sure what is going on there.
Code
Display MoreDEF noDatSpin ( ) DECL E6POS position GLOBAL INTERRUPT DECL 3 WHEN $STOPMESS==TRUE DO IR_STOPM ( ) INTERRUPT ON 3 BAS (#INITMOV, 0) BAS (#TOOL, 5) BAS (#BASE, 0) ;BAS (#PTP_PARAMS, 15) position = $POS_ACT PTP position $ADVANCE = 5 WHILE TRUE $BWDSTART = FALSE PDAT_ACT = {VEL 100.0000,ACC 100.000,APO_DIST 500.000,APO_MODE #CDIS,GEAR_JERK 100.000,EXAX_IGN 0} FDAT_ACT = {TOOL_NO 1,BASE_NO 0,IPO_FRAME #BASE,POINT2[] " "} PTP position C_Dis position.E1 = position.E2+90 ENDWHILE END
-
SkyeFire, thanks for following up. I am about to go play around with the bot some more to see if I can get it to behave. I think you are right that CIRC moves might be the easiest way to go. I can probably just make each rotation in 2 moves by Negating X and Y, adding 180 to A, and 180 to E1.
I guess I could LIN to a E6Axis position, with only the E1 changed.... I think. This should even work in our typical base.
I am still surprised that the robot pauses. I could understand it it was moving the wrong speed, but the pause is still strange to me.
Also, thank you for the generator program. I will keep this as a backup plan.
-
1. KS V8.5.465_HF3
2. The turntable is typically configured to be the base coordinate system. It works this way when running our typical programs. I am using Base 0 so I can just tell E1 to move without updating the position's XYZ values. I could put in in our normal base, but then I would have to specify XYZ and A with E1 to keep the tool in the same position. Also, the turn table seems to be configured so that a LIN move is more like an Arc. I am not sure how this was setup, but the LIN moves in the program do not move the arm, so if a pen was attached to the tool it would draw an arc on the turn table.
3. I am using LIN because it actually makes arcs, I could use PTP, but I want to specify the relative velocity at the TCP instead of a percentage of the max rotation speed.
4. I will try C_VEL. I haven't used this before. I will also try a PTP move to see if it also pauses.
hermann I am using Base 0 so that the turntable transformations are not taken into consideration. Our other base numbers have the base transformed to the turntable and moving with it, so I would have to specify XYZA and E1 to keep the tool in a fixed location as the turntable rotates (which is how my typical programs run). You do make a good point that the velocity of the LIN move doesn't make sense if I am using Base[0] because the tool doesn't have a calculated relative movement. I will look into this more. It seems like this would be an issue with the velocity, but it shouldn't cause the turntable to pause after each motion (I don't think).
-
I tried re-writing the program and it still has the same behavior; the robot pauses at the end of each move.
Code
Display MoreDEF noDatSpin ( ) DECL E6POS position GLOBAL INTERRUPT DECL 3 WHEN $STOPMESS==TRUE DO IR_STOPM ( ) INTERRUPT ON 3 BAS (#INITMOV,0 ) position = $POS_ACT $BWDSTART = FALSE PDAT_ACT = {VEL 15,ACC 100,APO_DIST 50} FDAT_ACT = {TOOL_NO 5,BASE_NO 0,IPO_FRAME #BASE} BAS (#PTP_PARAMS,15) PTP position $VEL.CP=0.25 $ADVANCE=3 WHILE TRUE LIN position C_DIS position.E1 = position.E1 + 120 ENDWHILE END
I have tried adding and changing $APO.CDIS and $ACC.CP but it doesn't seem to change anything.