📄 API Function: Reference Frame Adjustment (v2.4)

API Function: Reference Frame Adjustment

Configure adjustments to the reference frame before each new program execution

State: Feature is deprecated. Replaced with "Reference Frame Correction", available from version 2.4.

This feature allows adjusting programs to account for workpieces that do not lay the same exact place as when the program was recorded.

Recorded positions in a Mimic program are all relative to a calibrated reference frame. This feature allows users to apply and transform to the recorded position to transform the whole program. See figure below.

The adjusted frame (F_adjusted) transform is equal to the reference frame (F_reference) multiplied with the adjustment transform(T_adjustment).

Setting the adjustment transform through the API will apply it to the next time the program is executed. Adjustment will reset after an execution. Adjustment is also reset if Mimic is restarted.

See example below. The example will move the Reference Frame 100 mm in Z and rotate 15 degrees around Z.

import grpc
install scipy  from scipy.spatial.transform import Rotation from nordbo.mimic.v1 import runtime_service_pb2 from nordbo.mimic.v1 import runtime_service_pb2_grpc def setReferenceFrameAdjustment():   with grpc.insecure_channel("localhost:50195") as channel:     stub = runtime_service_pb2_grpc.RuntimeServiceStub(channel)     x = 100     y = 0     z = 0     rx = 0     ry = 0     rz = 15     quaternion = Rotation.from_euler('xyz', [rx, ry, rz], degrees=True).as_quat()     request = runtime_service_pb2.ReferenceFrameAdjustmentRequest()     request.adjustment.translation_mm.x = x     request.adjustment.translation_mm.y = y     request.adjustment.translation_mm.z = z     request.adjustment.rotation.qx = quaternion[0]     request.adjustment.rotation.qy = quaternion[1]     request.adjustment.rotation.qz = quaternion[2]     request.adjustment.rotation.qw = quaternion[3]     response = stub.SetReferenceFrameAdjustment(request) if __name__== "__main__":   setReferenceFrameAdjustment()


💡

Proto files are supplied with Mimic. They are updated when Mimic is updated via the Nordbo Update Tool.

Feature proto file: rigid_transformation.proto

File location on Mimic Controller:

/home/nordbo/NordboUpdateTool/Mimic/mimic-[VERSION]/mimic-api-[VERSION].zip

Example: "/home/nordbo/NordboUpdateTool/Mimic/mimic-2.2+beta.5/". File name is: "mimic-api-2.2+beta.5+4735-2204.zip"