xArm5 - Stop Motion Blockly with IF Clause

Hey,

we have the following Case:

  • The Vakuum Gripper moves to a defined Position
  • The Gripper shall move downwards to a Maximum of 65mm
  • If The Vakuum Gripper gets something, it shall stop the Downward Movement and move up to a designated Position (or to the Position before moving Down)

Our Problem is, we cannot stop the Original downward Movement without leaving the whole Blockly call (motion(stop)).

Is there any chance to get a clean downward movement without interruptions, like we do now? ( Check Blockly Picture)

Greetings
Screenshot 2024-01-29 150608

Hi Sir,

I tried your Blockly project on my side, it looks working fine. If something is picked up, the arm will move to the defined position immediately. And it seems the variable ‘schrittzaehler’ is useless in this case?

Do you mean it will keep moving downwards to 65mm even if something is picked up on your side?
What is the firmware and ufactory Studio vesrion? I did the test on the latest V2.3.0 version.

Best regards,
Minna

Hey,

thank you for testing. I just saw, i made a mistake in my example.

Please look at the new Picture i added. This would be the statement, we would like to use.
The If Clause for object is picked up with the timeout is working properly, but the original “move down 50mm wait=false” does not get stopped when we want to order the command to move back to original position once something has been picked up. It just keeps moving down even if something was picked up.

The COmmand motion(stop) quits the whole blockly task, so we cannot queue more commands.

Hi Sir,

Please note that the state of our Blockly is bound to the state of the robot arm. Once the state of the arm is set to 4, the Blockly program will exits as well.
If you want to interrupt the current movement, you can use mode 6/7 -online trajectory planning mode.
Below is a simple demo for your reference.

Best regards,
Minna

1 Like

Hey,

we just managed to get the Function working as intended. Thank you for your support.

I was having the exact same issue - thanks for the solution! It would be great to add this functionality natively into Blockly without having to use a (currently undocumented) Python call. Things like tool zeroing and calibration rely on this kind of function frequently.

Do you mean add the joint&Cartesian online trajectory planning method(mode 6& mode7) to the Blockly?