Fanuc SDKControl Fanuc robots from your own software
Quickly create applications in .NET, Python or LabVIEW that communicate with your Fanuc industrial robot. A ready-to-use software library: your PC talks to the robot over the network cable.
From 1100 € / $1300, paid once
Matlab
1// dotnet add package UnderAutomation.Fanuc2using UnderAutomation.Fanuc;34var robot = new FanucRobot();5robot.Connect("192.168.0.1");67var position = robot.Cgtp.ReadCartesianPosition();8robot.Cgtp.WriteVariable("$RMT_MASTER", 1);9robot.Cgtp.RunProgram("MyProgram");
What you get
Plug & Play
Connect your robot in just a few minutes. No license manager to install, no USB key. Only reference the library.
No plugins to install on the robot
Use of network protocols provided as standard by the robot controller.
30-day trial
Try it free for 30 days, no commitment, no registration required
Pay once, use forever
Perpetual license, no subscription required, regardless of the number of robots, developers, or redistributed software
Customer Success Stories
Discover how our customers integrate UnderAutomation solutions into their industrial projects.


GE: Aerospace & Healthcare Automation
GE Accelerates Industrial Automation with UnderAutomation SDKs for Universal Robots and FANUC.


Lockheed Martin: Flexible Aerospace Automation
Refining precision manufacturing and handling with collaborative robots.


Nissan: Driving Efficiency at Scale
How Nissan Smyrna Leverages Fanuc Connectivity for intelligent vehicle assembly.


realvirtual.io: Fanuc Integration for Virtual Commissioning
How realvirtual.io embedded the UnderAutomation Fanuc SDK to deliver first-class robot integration inside their Unity-based digital twin platform.
Fanuc SDK Features: CGTP, Telnet, SNPX, FTP & Kinematics
Each feature comes with a code sample. Click on it to see the full code.
Remote commands
Run, pause and abort programs, reset alarms, set variables and I/O from your PC. Use CGTP, the web server of recent controllers (HTTP / HTTPS), or Telnet KCL on older ones. No option is needed on the controller.
robot.Connect(parameters);// Read a variableCgtpVariableValue var = robot.Cgtp.ReadVariable("$RMT_MASTER");int rmtMaster = var.IntegerValue;// Write a variablerobot.Cgtp.WriteVariable("$RMT_MASTER", 1);// Read a numeric register with commentNumericRegisterWithComment reg = robot.Cgtp.ReadNumericRegisterWithComment(1);// Read I/Oint di1 = robot.Cgtp.ReadIo(CgtpIoPortType.DI, 1);// Write I/Orobot.Cgtp.WriteIo(CgtpIoPortType.DO, 1, 1);// Read current Cartesian positionCartesianPosition pos = robot.Cgtp.ReadCartesianPosition();// Run a programrobot.Cgtp.RunProgram("MY_PROGRAM");}}
High-speed data reading and writing
SNPX (also known as SRTP/Robotif) allows rapid and structured data communication with the robot. It is used to read/write the registers, monitor alarms and check the condition of the robot.
// Connect to the robotrobot.Connect(parameters);// Read a registerPosition posReg1 = robot.Snpx.PositionRegisters.Read(1);float numReg5 = robot.Snpx.NumericRegisters.Read(5);string strReg10 = robot.Snpx.StringRegisters.Read(10);// Write a registerposReg1.CartesianPosition.X = 100;robot.Snpx.PositionRegisters.Write(1, posReg1);robot.Snpx.NumericRegisters.Write(2, 123.45f);robot.Snpx.StringRegisters.Write(3, "Hello, world!");// Read a variableint rmtMaster = robot.Snpx.IntegerSystemVariables.Read("$RMT_MASTER");string lastAlm = robot.Snpx.StringSystemVariables.Read("$ALM_IF.$LAST_ALM");Position cellFloor = robot.Snpx.PositionSystemVariables.Read("$CELL_FLOOR");// Write a system variablerobot.Snpx.IntegerSystemVariables.Write("$RMT_MASTER", 1);robot.Snpx.StringSystemVariables.Write("$ALM_IF.$LAST_ALM", "No alarms");robot.Snpx.PositionSystemVariables.Write("$CELL_FLOOR", cellFloor);// Write a Karel program variablerobot.Snpx.IntegerSystemVariables.Write("$[KarelProgram]KarelVariable", 1);// Read and Write I/O (SDI,SDO,RDI,RDO,UI,UO,SI,SO,WI,WO,WSI,PMC_K,PMC_R)robot.Snpx.RDO.Write(1, true);ushort ai5 = robot.Snpx.AI.Read(5);// Read and Write analogs (AI,AO,GI,GO,PMC_D)robot.Snpx.AO.Write(2, 5);ushort ao3 = robot.Snpx.AO.Read(3);// Clear alarmsrobot.Snpx.ClearAlarms();}
File and decoding
Direct access FTP to the memory of the robot for file transfer, reading variables and the management of the robot state, all in decoded and ready to be used in structured objects.
// Connect to the robotrobot.Connect(parameters);IOState ioState = robot.Ftp.GetIOState();// Read a variablevar variableFiles = robot.Ftp.GetAllVariables();foreach (var variableFile in variableFiles)foreach (var variable in variableFile.Variables)Console.WriteLine($"{variable.Name} = {variable.Value}");// Read system variable $RMT_MASTERint remoteMode = robot.Ftp.KnownVariableFiles.GetSystemFile().RmtMaster;// Read safety statusSafetyStatus safetyStatus = robot.Ftp.GetSafetyStatus();Console.WriteLine($"Emergency Stop: {safetyStatus.ExternalEStop}");Console.WriteLine($"Teach Pendant Enabled: {safetyStatus.TPEnable}");// Get current position for each arm (Joints, World position of each tool, user frame positions)CurrentPosition currentPosition = robot.Ftp.GetCurrentPosition();// Upload a TP program to the controllerrobot.Ftp.DirectFileHandling.UploadFileToController(@"C:\Programs\MyPrg.tp", "md:/MyPrg.tp");// Download a file from the robotrobot.Ftp.DirectFileHandling.DownloadFileFromController("md:/Backup.va", @"C:\Backup\Backup.va");// Delete a file on the robotrobot.Ftp.DirectFileHandling.DeleteFile("md:/OldProgram.tp");}
Inverse kinematics
Algebraic calculation of the direct and inverse kinematics of any Fanuc robot or cobot from its DH parameters.
FanucRobot robot = new FanucRobot();robot.Connect("192.168.0.1");// Get DH parameters// Example: CRX-10iA/LDhParameters dh = new DhParameters(-540, 150, -160, 0, 710, 0);// From a known arm modeldh = DhParameters.FromArmKinematicModel(ArmKinematicModels.CRX10iA);// From OPW parameters: M10iA/7Ldh = DhParameters.FromOpwParameters(0.15, -0.20, 0.60, 0.86, 0.10);// From an online robot (SYSMOTN file)dh = DhParameters.FromSymotnFile(robot.Ftp.KnownVariableFiles.GetSymotnFile())[0];// Forward kinematicsCartesianPosition pose = KinematicsUtils.ForwardKinematics(position, dh);// Inverse kinematics with multiple solutionsJointsPosition[] positions = KinematicsUtils.InverseKinematics(pose, dh);}}
Motion Interfaces
Implementation of the Fanuc RMI (R912) and Stream Motion (J519) protocols which allows you to simply send movement commands to the robot, as well as read and write its inputs, outputs and registers.
parameters.Rmi.Enable = true;robot.Connect(parameters);// Initialize the RMI_MOVE program on the controller.// TP must be disabled and the controller must be in AUTO mode.robot.Rmi.Initialize();// Linear motion at 100 mm/s to a Cartesian target (tool 1, frame 0)var instr = new LinearMotionTpInstruction{SpeedType = RmiLinearSpeedType.MmSec,Speed = 100,TermType = RmiTerminationType.Fine,Target = new CartesianPositionWithUserFrame(500, 200, 300, 0, 90, 0, tool: 1, frame: 0)};RmiInstructionResponse r = robot.Rmi.SendTpInstruction(instr);// Wait for the controller to confirm the motion completedr.WaitForCompletion();if (r.Status == RmiInstructionStatus.Error)System.Console.WriteLine("Error: " + r.ErrorText);// Abort when done - always end the session with Abort() or Disconnect()robot.Rmi.Abort();robot.Disconnect();}}
Offline tools
The features without the need for robot allow you to handle standard file formats (variable file, error list, robot status, etc.).
static void Main(){// Parse a variable file and extract a hierarchical list of variablesGenericVariableFile vaFile = FanucFileReaders.VariableReader.ReadFile("C:/path/to/variable.va", Languages.English);foreach (var variable in vaFile.Variables)Console.WriteLine($"{variable.Name} = {variable.Value} [{variable.Type}]");// Edit and regenerate the variable filevaFile.GenerateVa("C:/path/to/variable_modified.va\"");// Parse several types of filesFanucFileReaders.ErrorListReader.ReadFile("C:/path/to/errall.ls", Languages.English);FanucFileReaders.IOStateReader.ReadFile("C:/path/to/iostate.dg", Languages.English);FanucFileReaders.SafetyStatusReader.ReadFile("C:/path/to/safety.dg", Languages.English);FanucFileReaders.CurrentPositionReader.ReadFile("C:/path/to/curpos.dg", Languages.English);}
See it in action
Video and screenshots of the demo application delivered with the SDK.
Windows application example
No code to write: test the SDK on your robot with the demo application.

Examples on GitHub
The sources of examples of use of this SDK are available on Github
Python example
Example of operation of this SDK with Python to recover the Cartesian position of a robot.
Labview example
Example of VI which allows most of the functions of this SDK to be tested.
Try it in your browser
Two web applications built with the Fanuc SDK. Nothing to install to test them.

Kinematics playground
Move the joints or the tool of a Fanuc CRX in 3D. The forward and inverse kinematics run in your browser, with the same engine as the SDK.

RMI sequence builder
Build a robot sequence with blocks, run it on a simulated robot or on a real one, and get the C# or Python code of your sequence.
Install it in one command
Choose your language. The 30-day trial starts at the first use, with no registration.
.NET
NuGet package for C# and VB.NET, from .NET Framework to the latest .NET.
dotnet add package UnderAutomation.FanucPython
Python package on PyPI, for Windows, Linux and macOS.
pip install UnderAutomation.FanucLabVIEW
LabVIEW library (.lvlib) and its example project, on GitHub.
git clone https://github.com/underautomation/Fanuc.vi.gitAI agents
Skill for AI coding agents (Claude Code, Cursor, Copilot...): your assistant knows the API of the SDK.
npx skills add underautomation/skills --skill underautomation-fanuc-csharpBrowse the documentation
The documentation allows you to quickly start developing with the library. The same functionality is available in all supported languages.
Browse the documentation
The documentation allows you to quickly start developing with the library. The same functionality is available in all supported languages.
Getting started with .NET
Code your application in C# or VB with this 100% managed library, without dependencies and available on NuGet.org in the version and architecture of your choice (x86, x64, ARM, Linux, Windows, MacOS, .NET Framework, .NET Core, UWP, ...)
Get started with Python
Quickly develop a program in Python that communicates with your robot using this library. It is available on PyPI.
Getting started with LabVIEW
Equip your LabVIEW VIs with a communication with your robot.

Getting started with Matlab
Allow your Matlab scripts to drive your robot.
Guides and how-to articles
The SDK covers the main features of Fanuc robots through several native Ethernet protocols. Depending on the options installed on your controller and its generation, some protocols may or may not be available. Each article below explains how to perform a specific task and compares the different approaches.
CGTP overview
CGTP is an HTTP-based protocol providing the richest feature set: program management, variables, registers, I/O, kinematics, batch operations, and file access.
SNPX overview
SNPX (also known as RobotIF or SRTP) is a high-speed protocol for reading and writing registers, variables, I/O signals, alarms, and positions in less than 2 ms.
Telnet overview
Telnet KCL (Keyboard Command Line) sends commands to a Fanuc robot: run programs, reset alarms, read and write variables, control I/O ports.
FTP overview
FTP provides access to internal controller files including variables, programs, diagnostics, safety status, and current position.
RMI overview
RMI (Remote Motion Interface) is a TCP-based protocol for sending motion commands, managing frames, and controlling the robot remotely.
Stream Motion overview
Stream Motion (J519 option) gives the position of the robot at every communication cycle (2 to 8 ms). Requirements, TP program, protocol versions and quick start.
Motion planner overview
Create smooth robot trajectories offline, with velocity, acceleration and jerk limits, using FANUC motion instructions (J, L, C, FINE, CNT, CR).
Forward & Inverse Kinematics
Perform forward and inverse kinematics calculations offline for FANUC industrial robots and CRX cobots using DH parameters.
Offline file parsing
Parse and decode Fanuc variable files (.va), error lists (.ls), I/O state, safety status, and current position files without a robot connection.
Read & write registers
Compare all methods to read and write numeric, position, and string registers on a Fanuc robot: SNPX, FTP, CGTP, and Telnet.
Get current position
Retrieve the current robot position (joint and Cartesian) using SNPX, FTP, CGTP, or Telnet. Compare approaches and choose the best for your use case.
Control inputs & outputs
Set, read, simulate, and unsimulate I/O ports on a Fanuc robot using SNPX, CGTP, or Telnet. Compare port types and methods.
Run a program remotely
Start, pause, abort, and monitor Fanuc programs remotely using Telnet, CGTP, SNPX system variables, or RMI.
Reset alarms remotely
Clear and reset alarms on a Fanuc robot using SNPX, Telnet, or CGTP. Read active alarms and alarm history.
Read & write system variables
Access and modify Fanuc system variables ($RMT_MASTER, $MCR.$GENOVERRIDE, etc.) using Telnet, SNPX, CGTP, or FTP.
Monitor task execution
Supervise running programs, check task states, line numbers, and calling programs using SNPX, FTP, or Telnet.
Move robot remotely
Move a Fanuc robot from an external application using RMI motion commands, Stream Motion real-time streaming, or DPM with SNPX.
Upload, download & backup files
Transfer TP programs, variable files, and backups between your PC and a Fanuc controller using FTP or CGTP.
Read & write I/O comments
Read and write comments (descriptions) for registers and I/O ports using SNPX or CGTP.
Access Karel program variables
Read and write Karel program variables using SNPX ($[Program]Variable syntax), CGTP, or FTP variable files.
Optimize with batch operations
Maximize read/write performance using SNPX batch assignments and CGTP batch variables for high-frequency data exchange.
Move robot with mouse
Control a FANUC robot in real time using Dynamic Path Modification (DPM) and SNPX. Ideal for joystick or 6D mouse teleoperation setups.
TP editor with breakpoints
Prototype your own TP Editor with syntax highlighting and breakpoint debugging using Telnet and FTP features.
Pricing
Libraries can be downloaded for free and can be tested for 30 days. After this period, you can ask us to extend the trial period, or buy the license that suits you best: standard, pro or source. After purchasing, you have a maintenance period, giving you access to the support and the possibility of updating. When you buy a license to use, it is linked to a robot brand, you can use it forever, without recurring fee, regardless of the number of robot, developer or software that you redistribute to your customers. If you are a distributor and wish to offer your customers one of our products, please contact us to discuss special conditions and prices.
Standard Site License
•
Pro License
•
Source license
•
Frequently asked questions
Libraries on GitHub
Each package is published on GitHub with its changelog.
Latest releases
Fanuc.NET
Latest release
Get started now !
Start the 30-day trial today, or ask for a quote.