Subscribe variables in Yumi with PCSDK
When I use PCSDK to read variable values in Yumi, I got a problem.
When the program started, it need register variable events, but it cost too much time.
what's the reason about this, too many variables or other reasons.
Thanks in advance.
program as below:
diWpcReadyLeft.Changed += new EventHandler<SignalChangedEventArgs>(SignalValueChanged);
When the program started, it need register variable events, but it cost too much time.
what's the reason about this, too many variables or other reasons.
Thanks in advance.
program as below:
diWpcReadyLeft.Changed += new EventHandler<SignalChangedEventArgs>(SignalValueChanged);
0
Comments
-
Hello ZhangKeke,
How long does it take to create an event? And how long did you expect it to take?
—Maxim RiabichevPC Software Support Engineer0 -
Dear ZhangKeke,
If you want to subscribe to Rapid Data, this can be the code - Your Rapid Data must be PERSModule myModule = ...;
RapidSymbol rapidSymbol = ...;RapidData rapidData = myModule.GetRapidData(rapidSymbol);
rapidData.ValueChanged += (sender, e) => RapidDataValChanged_Method(sender, e);
Best regards,
Florian0 -
Dear Maxim
I am not sure how long to create an event, may be one or two seconds. Is that normal?
In addition, how can I get the symbol 'MachanicalUnitServiceInfo', such as 'ElapsedProductionTime' or 'LastStart'.
Last but not the least, how can I get the realtime CPU load, this is very import for me.
Sorry for so many questions. Thanks for your advice.0 -
Hello ZhangKeke,
From my experience with PCSDK an event should not take 1 or 2 seconds to set up. Something seems strange in this regard.
I recommend downloading the PCSDK sample I've created and trying it to see if you get similar times with this code (because I do not when trying vs. a Virtual Controller).
Regarding 'MachanicalUnitServiceInfo', such as 'ElapsedProductionTime' or 'LastStart': see this resource: https://developercenter.robotstudio.com/api/pcsdk/api/ABB.Robotics.Controllers.MotionDomain.MechanicalUnitServiceInfo.html
How can I get the realtime CPU load, this is very import for me.
You "can't". The CPU Load indicator that might be available would be the same as is available via the device tree in RobotStudio but since the controller has a prioritized CPU management (motion tasks will always be prioritized for example), this indicator doesn't really say anything of importance.
—Maxim RiabichevPC Software Support Engineer0
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)
- 798 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings