Jump to content
OMRON Forums

Linux performance vs. RTI freq...


KEJR

Recommended Posts

Hello, I'm experiencing a very noticeable performance hit in my C# HMI after configuring my servos from the default phase clock/ servo clock to 15Khz phase and 7.5Khz servo clocks. To give an idea of what my HMI is doing, I have a few buttons and 4-5 P variables that get polled every 100ms using the GetPmacVar(char *) function in the C library. Normally without motors enabled it screams and I don't notice any lags at all. After I updated the frequencies it started giving me random 0.5-1.5 second lags and delays which are a bit problematic. My machine has two servos over Macro with the above stated frequencies. Task manager reports the following: Phase Interrupt 15.083 Khz 1.944 usec 5.996 usec 2.932 % Servo Interrupt 7.508 Khz 8.626 usec 21.981 usec 6.476 % Real Time Interrupt 7.482 Khz 23.140 usec 81.181 usec 17.313 % Background Tasks 0.986 Khz 8.666 usec 8,724.090 usec 0.855 % Should I expect poor performance at these rates? given these numbers I would tend to expect at lest 70% of my original processor speed. Thank you, KEJR
Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

[quote='bradp' pid='1243' dateline='1296507663'] Where does this C# HMI execute, on the PPmac CPU with mono or on another PC connected via telnet or SSH? [/quote] I am executing it on the PPMAC using Mono. My calls to read variables are through DllImport direct to the native C library. I am only executing TWM window manager and an xterm as my other applications in addition to PowerPMAC IDE.
Link to comment
Share on other sites

Hello, I think I have found the culprit. I am embarrassed to say that it appears to be a couple basic things on my end: 1) I am testing using a remote X server and not a "real" display plugged in. 2) I forgot that the X server PC was running wireless. I did do some profiling of the C#/mono Hmi application and these stats might be of some use to others: - Updating 5 display items in C# with a "foreach" loop acting on an arraylist took about 1.6ms. In there also was the conversion of double to string that gets copied to the label text used in my Hmi screen. The raw read using GetPMACVar(char *) took an average of 3us from the C#/mono program, which is pretty good considering my 25% loaded processor. I am surprised [a little] that the C#/mono performance is so bad. Since we might have a couple dozen display items on the screen (on some menus, for instance) and polling interval is 100ms I have some work ahead of me to optimize the code a bit. Still, it is always good to know the numbers so you know what you are dealing with. KEJR
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.

×
×
  • Create New...