Skip to main content
Skip table of contents

CDRFLEx.check_force_condition

Features

This function checks the status of the given force. It disregards the force direction and only compares the sizes. This condition can be repeated with the while or if statement. Measuring the force, eForceAxis is based on the ref coordinate(eTargetRef) and measuring the moment, eForceAxis is based on the tool coordinate.

Parameter

Parameter Name

Data Type

Default Value

Description

eForceAxis

enum.FORCE_AXIS

-

Refer to the Definition of Constant and Enumeration Type

fTargetMin

float

-

Minimum value

fTargetMax

float

-

Maximum value

eForceReference

enum.COORDINATE_SYSTEM

COORDINATE_SYSTEM_TOOL

Refer to the Definition of Constant and Enumeration Type

Return

Value

Description

1

The condition is True

0

The condition is False

Example

CPP
bool fcon1 = Drfl.check_force_condition(FORCE_AXIS_Z, 5, 10, COORDINATE_SYSTEM_WORLD);
bool fcon2;
bool pcon1;
while(true){
    fcon2 = Drfl.check_force_condition(FORCE_AXIS_C, 30, -10000);
    pcon1 = Drfl.check_position_condition_abs(FORCE_AXIS_X, 0, 0.1);
    if(fcon2 && pcon1)
    {
        break;
    }
}

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.