Hi,
I dont think pose_trans is the correct thing you want. I suspect you want to just manually build your target.
take the x,y,z position from the current_pose.. and the Rx,Ry (and maybe Rz not sure if you want that) from your current position.
The robot stores targets as [x,y,z,Rx,Ry,Rz] with Rx,Ry,Rz forming a rotation vector (with magnitude of the rotation angle). I find these angles hard to work with intuitively if there is more than one rotation so I use the built in rpy2rotvec and rotvec2rpy functions quite a bit.
If you work in RPY (roll pitch yaw) to get the Z axis of the tool aligned with the Z of the plane you need to have the same RX and RY values (Rz can vary as this is rotation about the tool). This is I think close to what the align button in the move screen does. If you adjust the view in the move screen to show roll pitch yaw instead of rotation vectors you may be able to make more sense of what it’s doing.
so if you code something like this;
my_plane = [X, Y, Z, Rx, Ry, Rz]
current_pose = get_actual_tcp_pose()
#get rpy (roll pitch yaw) for current_pose
current_pose_rpy = rotvec2rpy([current_pose[3], current_pose[4], current_pose[5]]),
#get rpy (roll pitch yaw) for my_plane
my_plane_rpy = rotvec2rpy([my_plane[3], my_plane[4], my_plane[5]])
#create target rotvec (rx,ry from my_plane, rz from current_pose.. not sure if this is what you want, but you can see the logic here)
target_rotvec = rpy2rotvec([my_plane_rpy[0], my_plane_rpy[1], current_pose_rpy[2]])
#make a pose with current_pose position (and my_plane rx,ry)
target_pose = p[current_pose[0], current_pose[1], current_pose[2],target_rotvec[0], target_rotvec[1], target_rotvec[2]]
I have just typed this in here so there might be syntax errors.. but you should be able to see the concept I use (convert rotation vectors to rpy so I can understand them and take rx and ry separately if needed, then build a pose with the individual parts you want).
Hope that helps somewhat… took me a while to get my head around this rotation vector thing (and can’t say I get it right 100% now anyway)