Problem writing I/O signals with SDK
alopezd
✭
Hello,
I am trying to write I/O signals in a virtual controller with a C# app, but when I set/reset the value of one of them, it is displayed the error:
I tried to fix it by changing the access value of signal in RobotStudio (to ALL), but the problem remains the same. Writing Rapiddata (robtarget, etc.) I have no problems...
My code (the I/O writing part) is as shown below:
if (_controller.OperatingMode == ControllerOperatingMode.Auto)
{
using (Mastership m = Mastership.Request(_controller.Rapid))
{
Signal sig = _controller.IOSystem.GetSignal(item.Text);
DigitalSignal digitalSig = (DigitalSignal)sig;
int val = digitalSig.Get();
if (val == 1)
{
digitalSig.Set();
}
else
{
digitalSig.Reset();
}
}
}
I know there are some issues regarding the same thing, but none of them have been resolved as far as I know. I would appreciate any help or suggestion.
Thank you in advance.
Alex
I am trying to write I/O signals in a virtual controller with a C# app, but when I set/reset the value of one of them, it is displayed the error:
"The operation is not allowed in current operation mode.For
example, a remote user may not be allowed to perform the operation in
manual mode."
I tried to fix it by changing the access value of signal in RobotStudio (to ALL), but the problem remains the same. Writing Rapiddata (robtarget, etc.) I have no problems...
My code (the I/O writing part) is as shown below:
if (_controller.OperatingMode == ControllerOperatingMode.Auto)
{
using (Mastership m = Mastership.Request(_controller.Rapid))
{
Signal sig = _controller.IOSystem.GetSignal(item.Text);
DigitalSignal digitalSig = (DigitalSignal)sig;
int val = digitalSig.Get();
if (val == 1)
{
digitalSig.Set();
}
else
{
digitalSig.Reset();
}
}
}
I know there are some issues regarding the same thing, but none of them have been resolved as far as I know. I would appreciate any help or suggestion.
Thank you in advance.
Alex
0
Categories
- All Categories
- 5.5K RobotStudio
- 396 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.8K Robot Controller
- 316 IRC5
- 61 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 799 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings