Universal Robots Forum

.txt file to .urp

Hallo,

I hvae a doubt. I have a programm in .txt file andd wanted to convert it into .urp file. Is there a technique to copy into robot or i need create a new programm into polyscope and edit every step.

Thanks in advance

*.urp programs are basically compressed XML files so this is indeed possible. You might take a look at its uncompressed structure and rebuild it with a nice XML writer e.g. the ElementTree API for Python

1 Like

@ameyakarnik93
When a (defined) program in PolyScope is saved, this generates 3 files.
Say your program is named “MyProgram”, this would yield the following files:

  1. MyProgram.urp
  2. MyProgram.txt
  3. MyProgram.script

The actual file, that you can import into PolyScope is the URP file.
This contains all the data about waypoints, relations between variables etc.
This is the file you want to import into PolyScope.

The TXT file is just for reference / documentation.
If opened in a text editor, it shows the textual representation of the program:

RobotProgram
   MoveJ
      Waypoint_1
      Waypoint_2

This file contains no information about i.e. positions of waypoints etc. So this file cannot be converted into a loadable program, since you are literally lacking all information.

The SCRIPT file contains the URScript output of all nodes in order.
Hence, the result of any nodes generateScript call.

1 Like