Skip to content

πŸš€ A powerful .NET library for seamless communication with your Universal Robots cobot. Supports RTDE, URScript execution, Dashboard Server, SFTP, SSH, and more!

License

Notifications You must be signed in to change notification settings

underautomation/UniversalRobots.NET

Repository files navigation

Universal Robots Communication SDK

UnderAutomation Universal Robots communication SDK

NuGet .NET Framework .NET Standard .NET Core .NET Versions

πŸ€– Effortlessly Communicate with Universal Robots

The Universal Robots SDK enables seamless integration with Universal Robots for automation, data exchange, and remote control. Ideal for industrial automation, research, and advanced robotics applications.

πŸ”— More Information: https://underautomation.com/universal-robots
πŸ”— Also available for 🟨 LabVIEW & 🐍 Python


⭐ Star if you like it !

πŸ‘οΈ Watch to be notified of latest updates !


πŸš€ TL;DR (Too Long; Didn’t Read)

βœ”οΈ Full RTDE Support – Read & write at up to 500Hz
βœ”οΈ Send URScript Commands – Control robots in real-time
βœ”οΈ Dashboard Server – Manage power, programs, and states
βœ”οΈ Secure Connections – SSH & SFTP support
βœ”οΈ Multi-Platform – Works on Windows, Linux, and macOS
βœ”οΈ Commercial License – Deploy with no royalties

πŸ“Ή Watch Introduction Video

Universal.Robots.communication.SDK.mp4

πŸ“₯ Download Example Applications

Explore the Universal Robots SDK with fully functional example applications and precompiled binaries for various platforms. See Github releases

πŸ”Ή Windows Forms Application (Full Feature Showcase)

A Windows Forms application demonstrating all the features of the library.

πŸ“Œ Download: πŸ“₯ UnderAutomation.UniversalRobots.Showcase.Forms.exe

UnderAutomation.UniversalRobots.Showcase.Console


πŸ”Ή Console Applications (Multi-Platform)

Precompiled console applications showcasing compilation for multiple operating systems.

πŸ“Œ Downloads:

UnderAutomation.UniversalRobots.Showcase.Console

OS Architecture Download
🐧 Linux ARM πŸ“₯ Download
🐧 Linux x64 πŸ“₯ Download
🍏 macOS ARM64 πŸ“₯ Download
🍏 macOS x64 πŸ“₯ Download
πŸ–₯ Windows x64 πŸ“₯ Download
πŸ–₯ Windows x86 πŸ“₯ Download

πŸ“Œ Features

πŸ”Ή Real-Time Data Exchange (RTDE)

Communicate with your robot at 500Hz, read live data, and control its behavior.

var robot = new UR();

var param = new ConnectParameters("192.168.0.1");

// Enable RTDE
param.Rtde.Enable = true;

// Exchange data at 500Hz
param.Rtde.Frequency = 500;

// Select data you want to write in robot controller
param.Rtde.InputSetup.Add(RtdeInputData.StandardAnalogOutput0);
param.Rtde.InputSetup.Add(RtdeInputData.InputIntRegisters, 0);

// Select data you want the robot to send
param.Rtde.OutputSetup.Add(RtdeOutputData.ActualTcpPose);
param.Rtde.OutputSetup.Add(RtdeOutputData.ToolOutputVoltage);
param.Rtde.OutputSetup.Add(RtdeOutputData.OutputDoubleRegisters, 10);

// Connect to robot
robot.Connect(param);

// Be notified at 500Hz when data is received
robot.Rtde.OutputDataReceived += Rtde_OutputDataReceived;

// Write input values in robot
var inputValues = new RtdeInputValues();
inputValues.StandardAnalogOutput0 = 0.2;
inputValues.InputIntRegisters.X0 = 12;
robot.Rtde.WriteInputs(inputValues);

πŸ”Ή Primary Interface

Send URScript commands and monitor robot state at 10Hz.

// Send script
robot.PrimaryInterface.Script.Send("movej([-1.5,-1.5,-2,-0.5,1.8,0], a=1.4, v=1.05)");

// Get data
double x = robot.PrimaryInterface.CartesianInfo.TCPOffsetX;
double shoulderSpeed = robot.PrimaryInterface.JointData.Shoulder.ActualSpeed;

// Read program variables
GlobalVariable myVar = robot.PrimaryInterface.GlobalVariables.GetByName("myVar");
GlobalVariable[] variables =  robot.PrimaryInterface.GlobalVariables.GetAll();

πŸ”Ή Dashboard Server – Remote Robot Control

Manage power, brakes, program execution, and more.

robot.Dashboard.PowerOn();
robot.Dashboard.ReleaseBrake();
robot.Dashboard.LoadProgram("prg1.urp");
robot.Dashboard.Play();

πŸ”Ή XML-RPC – Call .NET Functions from URScript

Enable remote function calls from your robot program.

rpc := rpc_factory("xmlrpc", "http://192.168.0.10:50000")
answer := rpc.GetPose(100)
// Answer sent to the robot
robot.XmlRpc.XmlRpcServerRequest += (o, request) =>
  {
    if(request.MethodName == "GetPose") request.Answer = new Pose(request.Arguments[0], 200, 100, 0, 0, 0);
  };

πŸ”Ή Socket Communication

Allow robots to send and receive custom data via sockets.

robot.SocketCommunication.SocketWrite("Hello, Robot!");
robot.SocketCommunication.SocketRequest += (sender, e) => Console.WriteLine(e.Message);

πŸ”Ή Secure File Transfer (SFTP)

Upload, download, and manage files securely on your robot.

robot.Sftp.UploadFile(content, "/home/ur/ursim/programs/my-program.urp");
robot.Sftp.Delete("/home/ur/ursim/programs/old-program.urp");

πŸ”Ή SSH – Run Terminal Commands

Execute shell commands remotely.

robot.Ssh.RunCommand("echo 'Hello' > /home/ur/Desktop/NewFile.txt");

πŸ›  Installation

1️⃣ Get the SDK

Choose the installation method that works best for you:

Method NuGet (Recommended) Direct Download
How to Install Install via NuGet. See on Nuget Download and reference the DLL manually
dotnet add package UnderAutomation.UniversalRobots πŸ“₯ Download ZIP

2️⃣ Reference the SDK in Your Code

using UnderAutomation.UniversalRobots;

3️⃣ Connect to Your Robot

var robot = new UR();
robot.Connect(new ConnectParameters("192.168.0.1"));

πŸ” Compatibility

βœ… Supported Robots: UR3, UR5, UR10, UR16, UR20, UR30, CB-Series, e-Series, Polyscope, Polyscope X
βœ… Operating Systems: Windows, Linux, macOS
βœ… .NET Versions: .NET Framework (β‰₯3.5), .NET Standard, .NET Core, .NET 5/6/8/9


πŸ“’ Contributing

We welcome contributions! Feel free to:

  • Report issues via GitHub Issues
  • Submit pull requests with improvements
  • Share feedback & feature requests

πŸ“œ License

⚠️ This SDK requires a commercial license.
πŸ”— Learn more: UnderAutomation Licensing


πŸ“¬ Need Help?

If you have any questions or need support: