RobotStudio 6.07+: Issues loading IRC5 controller on 64bit systems
I believe I have stumbled on a blocking bug in the C# API that affects the 64 bit version and not the 32bit version of RobotStudio.
What I'm trying to do
The exception I get
The cause
When I try this exact same code in the 32bit version of RobotStudio I have no issues and I can read and subscribe to signals just fine.
I've verified that the same bug exists in v6.07 as well as v6.07+
Repro
<div><span>var scanner = new NetworkScanner(); </span><span>var cInfos = scanner.GetControllers(NetworkScannerSearchCriterias.Virtual); </span><span>var first = cInfos.FirstOrDefault(); </span><span>foreach (ControllerInfo c in cInfos) { </span><span> Debug.Print("{0} : {1} : {2}", c.ControllerName, c.Id, c.SystemId); </span>} </div>
Also reproducible using the example code from the ABB developer docs:
<div>Station station = Project.ActiveProject as Station; <span>var activeTask = station.ActiveTask; </span><span>RsIrc5Controller rsIrc5Controller = (RsIrc5Controller) activeTask.Parent; </span><span>var controller = new Controller(new Guid(rsIrc5Controller.SystemId)); </span><span>Debug.Print("Found Controller: {0}", controller.Name); </span></div>
Any known work-around for this for those of us that MUST use the 64 bit version of RobotStudio?
If this is a bug, any timeline on a fix?
BCT Technology AG, Im Lossenfeld 9, 77731 Willstätt, Germany, https://www.bct-technology.com
Vorstand/Officers: Klaus Erdrich, Jürgen Hillemann. Registergericht/Registry Court: Amtsgericht Freiburg, HRB 371105
Aufsichtsrat/Supervisory Board: Prof. Dr. h.c. Horst Weitzmann (Vorsitzender/Chairman), Katja Weber, Markus Menges
Comments
-
Hi,
It looks like you are using a very old version of PCSDK. Try installing the latest version.
Regards, Johannes
Johannes Weiman
Software Engineer
RobotStudio Team, ABB Robotics0 -
Hi Johannes,
Edit (Incorrectly reported this solved before):
I just now downloaded and ran the PCSDK.6.07.7936.1011.zip installer (which is the latest) and having it did not solve my issue.
The problem is still there when I build the system as 64bit.<div>Exception thrown: 'System.IO.FileNotFoundException' in SVERRIR.dll Additional information: Could not load file or assembly 'ABB.Robotics.Adapters.IRC5, Version=5.15.2005.2, Culture=neutral, PublicKeyToken=1da709b7d1f14b7b' or one of its dependencies. The system cannot find the file specified.</div>
The only installer I've run on my machine is the installer for RobotStudio 6.07 and then the RobotStudio 6.07.01 SP1 (and just now the latest PCSDK).There has never been anything else from ABB on this machine.
Regards,
Sverrir S.BCT Technology AG, Im Lossenfeld 9, 77731 Willstätt, Germany, https://www.bct-technology.com
Vorstand/Officers: Klaus Erdrich, Jürgen Hillemann. Registergericht/Registry Court: Amtsgericht Freiburg, HRB 371105
Aufsichtsrat/Supervisory Board: Prof. Dr. h.c. Horst Weitzmann (Vorsitzender/Chairman), Katja Weber, Markus Menges0 -
Which assemblies are you referencing? Note that you should not reference ABB.Robotics.dll or ABB.Robotics.Controllers.dll (legacy PCSDK) but instead ABB.Robotics.Controllers.PC.dll (new PCSDK).
Johannes Weiman
Software Engineer
RobotStudio Team, ABB Robotics0 -
Hi again,
Yeah, I'm referencing the ABB.Robotics.Controllers.PC.dll and using classes from it.
BCT Technology AG, Im Lossenfeld 9, 77731 Willstätt, Germany, https://www.bct-technology.com
Vorstand/Officers: Klaus Erdrich, Jürgen Hillemann. Registergericht/Registry Court: Amtsgericht Freiburg, HRB 371105
Aufsichtsrat/Supervisory Board: Prof. Dr. h.c. Horst Weitzmann (Vorsitzender/Chairman), Katja Weber, Markus Menges0 -
@Johannes Weiman Your comment sent me on the right path, I had a closer look at the references and there seems like there was indeed a conflict in the dll references.
After removing the following references:<Reference Include="RobotStudio.UI.Controller"> <Reference Include="ABB.Robotics, Version=5.15.2005.0, Culture=neutral, PublicKeyToken=1da709b7d1f14b7b, processorArchitecture=MSIL" /> <Reference Include="ABB.Robotics.Controllers, Version=5.15.2005.0, Culture=neutral, PublicKeyToken=1da709b7d1f14b7b, processorArchitecture=MSIL" />
All is working again in 64bits *phew*
Note, I had referenced both the new and the old PCSDK dlls in my project (yeah, that was stupid). But even though I was not using any references from the old dll in my code, just having it in my project seemed to cause issues. Also there was a conflict with the ControllerInfo class which got solved when I removed ABB.Robotics.dll as well.
Thanks for taking the time to help, it is much appreciated
-SverrirBCT Technology AG, Im Lossenfeld 9, 77731 Willstätt, Germany, https://www.bct-technology.com
Vorstand/Officers: Klaus Erdrich, Jürgen Hillemann. Registergericht/Registry Court: Amtsgericht Freiburg, HRB 371105
Aufsichtsrat/Supervisory Board: Prof. Dr. h.c. Horst Weitzmann (Vorsitzender/Chairman), Katja Weber, Markus Menges0 -
I can confirm that the solution above also works on sample code "Accessing Controller Data":
- remove obsolete ABB .dll's references
- add new reference: (current year example: ...\ABB\SDK\PCSDK 2021\ABB.Robotics.Controllers.PC.dll)
- change build target .NET framework to latest on each project that uses new .dll's0
Categories
- All Categories
- 5.5K RobotStudio
- 391 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 305 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 3 RobotStudio AR Viewer
- 773 RAPID Programming
- 17 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings