PCSDK - Writing a configuration value using RobotStudio jobs to pass in IP Address
Hello,
I'm trying to use the "Run external tool" option in RobotStudio jobs to run a application created by the SDK to write a cfg parameter to each controller. The code I have is not working and I don't know why. I am new to this and I am trying to follow the examples given in the documentation but have been unsuccessful so far. Here's what I have so far. Could someone help me out please?
I'm trying to use the "Run external tool" option in RobotStudio jobs to run a application created by the SDK to write a cfg parameter to each controller. The code I have is not working and I don't know why. I am new to this and I am trying to follow the examples given in the documentation but have been unsuccessful so far. Here's what I have so far. Could someone help me out please?
using System;
using ABB.Robotics;
using ABB.Robotics.Controllers;
using ABB.Robotics.Controllers.ConfigurationDomain;
namespace SimulateMenuDisabler
{
class Disable
{
static string sysID = "A0DFFC2B-F6CE-48C4-AC91-D3A6F1F54799";
static void Main(string[] args)
{
//sysID = "";
try
{
Controller controller = new Controller(ControllerFactory.FormatControllerId(new Guid(sysID)));
Mastership master;
ConfigurationDatabase cfg = controller.Configuration;
using (master = Mastership.Request(controller.Configuration))
{
string[] path = { "SYS", "SYS_MISC", "SimulateMenu", "Value" };
cfg.Write("0", path);
}
}
catch (System.InvalidOperationException ex)
{
//
}
}
}
}
Tagged:
0
Comments
-
Hello,I think you have forgotten to login to the controller.
controller.Logon(UserInfo.DefaultUser);<br>
BRMicky0
Categories
- All Categories
- 5.6K RobotStudio
- 401 UpFeed
- 21 Tutorials
- 15 RobotApps
- 306 PowerPacs
- 407 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.9K Robot Controller
- 363 IRC5
- 79 OmniCore
- 8 RCS (Realistic Controller Simulation)
- 853 RAPID Programming
- 30 AppStudio
- 4 RobotStudio AR Viewer
- 19 Wizard Easy Programming
- 110 Collaborative Robots
- 5 Job listings