This Tutorial demonstrates how to use the measured force values to dictate what actions the robot should perform.
- Smart Behavior - A general term for the use of logic within a task which responds to variables and signals.
- Measured Force - The real-time external forces acting upon the arm. These values can be found in the Shared Data section of Intera Studio.
Measured Force & Shared Data
The measured force values can be accessed at any time on the Intera studio by clicking on the Shared Data option on the Tools Bar.
- Open the shared data panel.
- Scroll to the Measured Forces section and notice that the values are updating in real-time.
- Apply force by hand on the robot, specifically at the end of arm tooling, and notice how the force variables are changing. These variables will be used in this tutorial as conditions for the robot to interpret.
- Specifically, determine the direction of force for positive and negative X, as these variables will be used later in the tutorial.
Creating the Behavior Tree
In this example, the arm will move to a safe point and wait until a force is applied on the arm in one of two directions. The robot's next motions will be dependent upon a force being applied in positive X or negative X, felt at the end of arm tooling.
- Create a Basic Task and add a Move-To Node in a safe location that the robot will wait at.
- Name that Move-To "Safe Pose."
- As children of the priority node, create two Do-If nodes and name them "Force in -X" and "Force in X."
- Select the Do-If node called Force in -X and find the Measure Force - Force.x variable.
- Enter the condition "Force.x is less than or equal to -5"
- Open the Do-If node called Force in X and repeat the steps above, only for this condition use Force.x is greater than or equal to 5.
- Now as children of each of the Do-If nodes, create Move-To nodes that you want the robot to run when those conditions are met.
- Run the task and note the behavior. If the conditions have been set correctly, the robot should wait at the Safe Pose until either force at X is less than -5N OR greater than 5N.
- Apply force by hand to the end of the arm and the arm will move to the trained Move-To poses as specified.