Python Script Step

The Python Script step lets you run your own Python code inside your Robotiq.ai processes. You can use it for complicated logic, changing data, or connecting with other systems.

What You'll Need

  • Python installed on your robot machine (the version you want to use).
  • You should know how to program in Python.

How to Use the Python Script Step

Add a Python Script step to your process to run your own Python code.

Step 1: Add the Python Script Step

  1. Open your process in the Robotiq.ai editor.
  2. Drag the Python Script step from the list of available steps and drop it into your process flow.

Step 2: Set Up Step Information

Step Name (Optional)

  • This is a name you give the step in the editor. It helps you find the step in your process.

Step 3: Map Variables

You can make process variables available to your Python script. You can also make new variables or change existing ones.

  • Input Variables: These are variables already in your process. Your Python script can read their values, but it can't change them.
  • Output Variables: These are variables already in your process. Your Python script can change their values. The new value will be available to the next steps in your process.
  • New Variables: These are new variables you make within the Python Script step. Their values will be available to other steps in your process after the script runs.

Things to Keep in Mind

  • Python Installation: Robotiq.ai doesn't install Python for you. You have to install and keep Python updated on your robot machine yourself.
  • Version Compatibility: If you update your Python version, make sure it works with your current Python scripts.
  • Machine Restart: After installing a new Python version or adding new Python installations, you might need to restart the robot machine for the changes to work.

Related Articles

Need Help?

Can't find what you're looking for? Join the Robotiq Community to get help from other users and the Robotiq team.

Was this article helpful?