When trying to create a move relative to a waypoint it’s doing something completely different to what thought it would. What I’m trying to do is take a set waypoint (w1), and then move 25mm in the x and y direction relative to w1
Rather than just moving 25mm in the x and y (x and y are defined on the same horizontal plane), the robot is rotating and moving down into the table and then giving a crash error as it seems to want to go to a point bellow the table, even though the plane I’m using has its origin defined above the table.
Can anyone see a problem with what I’m doing or offer a different solution to what I’m trying to do,
It sounds like what you really want is a Relative waypoint, as opposed to a variable waypoint. Either way, your current setup is not sending the robot an additional 25mm in the x and y from W1, it’s sending it to 25mm in the x and y from the center of the base.
Consider the base of the robot is located at [0,0,0]. If you create a waypoint with [0.025, 0.025, 0, 0 ,0 ,0], that’s where it’s going to go. You will need to add the current positional data of W1 with this 25mm offset.
I tend to lean on full blown script files with custom functions for this, because I’m more of an Object Oriented Programming person, but you can do something like this if you want to use just Polyscope:
Now, I notice you’re using a Feature “table top plane” (at least I think). If that Feature’s coordinate plane is not the same as the Base frame, this will not shift along that Feature’s frame. This will shift relative to the robot’s Base frame. If you need to shift along a Feature frame, I would really just advise to use the Relative Move function instead, as the script is somewhat nasty.
Edit:
You can easily set this up with a relative move by jogging to W1, then setting the “From Point” to that position. Then click the “to point” Set Point, and from the following Move screen, just tap any of the Tool Position values in the top right. This will allow you to manually type values. Just take whatever values are in there and add 25mm to the X and the Y values
This will take the a position 25mm in the x and y direction of the feature, subtract it from the feature so that you only have the new offset to apply which you then add to the original waypoint.
If you are going just off of the Base orientation the you can just use
Sooo… if:
pose add(p 1, p 2)
Pose addition
This function calculates the result x 3 as the addition of the given poses as
follows:
p 3.P = p 1.P + p 2.P
p 3.R = p 1.R * p 2.R
Parameters
p 1: tool pose 1(pose)
p 2: tool pose 2 (pose)
-if this is true…
Shouldnt the offset position be P[0.025,0.025,0,1,1,1] ?
Explanation p1r can have whatever rotations if its *0 it will end with 0.
I will test this tomorrow, I was wondering the same thing with addition rather than counting matrices…
I’m not 100% sure, but that notation of * in the manual might be for something like convolution. I confess my understanding of rotation matrices is very limited, so I could be way off base. In short though, no I don’t think it just 0s out rotation if you add some rotation with a 0 in that spot of the array.