tsc Posted February 6, 2023 Share Posted February 6, 2023 We are using the PCommServer Pro2 Library for our .NET HMI to talk to our turbo clipper PMAC over USB. We are using a dedicated thread to continuously query the PMAC using GetResponseEx(). We have an event handler set up to deal with unsolicited responses. Everything works well until an unsolicited response (such as a SENDP in a motion file) comes in at the same time as a reply to a GetResponseEx() query. When that happens, the unsolicited reply gets lost or gets merged into the response for the GetResponseEx(). How do we get unsolicited responses to work reliably? Quote Link to comment Share on other sites More sharing options...
steve.milici Posted February 7, 2023 Share Posted February 7, 2023 Using “GetResponseEx()” is not the proper method to retrieve “unsolicited responses”. Use the method outlined in the “PcommServer Library” manual for “Unsolicited Response Event”. Make certain that “I64” (Unsolicited Response Tagged) is set to “1”. Quote Link to comment Share on other sites More sharing options...
tsc Posted February 10, 2023 Author Share Posted February 10, 2023 (edited) Thanks for your reply. We are not using GetResponseEx() to receive unsolicited messages. We are using an event handler (as per the manual) to receive unsolicited messages. We are using GetResponseEx() to continuously query the PMAC for other information (such as P and Q variables). GetResponseEx() works fine and the event handler for unsolicited messages works fine independently. The issue occurs when an unsolicited message comes in at the same time a reply to one of the GetResponseEx() queries comes in. I64 is set to 1 as per the manual but this does not resolve the issue. Note that when the issue occurs, the unsolicited reply also does not show up in pewin32pro, indicating a bug at the pcommserver level. Any advice is highly appreciated. Edited February 10, 2023 by tsc Quote Link to comment Share on other sites More sharing options...
steve.milici Posted February 10, 2023 Share Posted February 10, 2023 There are no known bugs with the current versions of PcommServer or Pewin32Pro2. The current versions are "4.4.0.0" for both. Loss of unsolicited messages is typically caused by losing the setting of “I64 = 1”. Verify this is not happening. Since this would be a technical support issue, please contact ODT's direct technical support with your full issue details at ODT-Support@Omron.com. Make sure to provide the versions of PcommServer and Pewin23Pro2 that you have. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.