UofI-CDACS/fanuc_ethernet_ip_drivers

Coordinate Frames: `read_cartesian_position()` Doesn't Match World Frame Coordinates on Fanuc TP

Closed this issue · 2 comments

@JamesL-dev can you confirm what frame read_current_joint_position() and read_cartesian_position() are reading from? After using those two methods in my position capture script, somehow points (480, 868) from capture program and (795, 634) from TP current position are at the same location.

Note

to clarify, I am not comparing joint to cartesian, I am comparing cartesian coords acquired through the EIP driver with the current position listed on the FANUC Teach Pendant.

I have found that changing the TP to User Frame #0 in the TP jog menu causes both readings to align. This seems problematic since though since after working for bit more suddenly all of my positions were off and after checking the TP I see that, yes, the User frame has been automatically switched back to frame 1.

Any thoughts? Using a user frame on top of the world frame is quite annoying right now because it messes up using WPR in cartesian coordinates to refine robot movements.

Okay experts and personal experience inform me that:

  1. The ROS2_EIP_MAINV2 driver running on the TP sets UFRAME=1 and UTOOL=1 when the driver is started. Thus, the default coordinates read by the FANUC ethernet ip driver are the USER FRAME. As a result, you may observe some wonky differences between the World coordinates and the coordinates read from get_coords(), read_cartesian_position(), etc.
    • the only way to select another UFRAME or UTOOL other than 1 is through the TP interface, I use the Jog menu where the options are shown on the left hand side of the screen
    • the UFRAME and UTOOL will be set to 1 automatically every time ROS2_EIP_MAINV2 is restarted
  2. The User Frame data can be wiped and reset to 0 (the World frame) if you so desire. Just open the setup menu on the TP and find the UFrame setup menu. When prompted, set XYZWPR to 0 to match the World frame.

This isn't really a problem, but eventually the ability to set UFrame and UTool without being overridden by the EIP driver on the robot, I am going to mark this as a feature request.

Added to requested features.