Jump to content
OMRON Forums

GetResponse not handling user variables names in MONO program


BoneSkier

Recommended Posts

I am pretty sure this is a bug. I have defined a variable as follows:

 

#define AxesEnabled P249

 

When I type "AxesEnabled" in the terminal or from "GPASCII -2" from Telnet, I get the proper expected response:

 

P249=1

 

However, when I enter this same command in GetResponse from within my VB.NET program running with MONO, I get this:

 

"error #20: ILLEGAL CMD: AxesEnabled"

 

The results I am getting are the same as when I do the command using GPASCII (without the -2).

 

"error #20: ILLEGAL CMD: AxesEnabled"

 

So, when InitLibrary is done in my MONO program, is it starting GPASCII with -2?

 

Additionally, I tried doing another command (Coord[1].AmpEna, whichi si defined by Delta Tau) from GetResponse in my MONO program, and it works just fine:

 

Coord[1].AmpEna=1

 

 

 

 

 

Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

I am pretty sure this is a bug. I have defined a variable as follows:

 

#define AxesEnabled P249

 

When I type "AxesEnabled" in the terminal or from "GPASCII -2" from Telnet, I get the proper expected response:

 

 

Can you auto define the variable using the "global" keyword, or do you need the variable explicitly defined to P249? I've used global extensively with Mono without problems. The fact that it behaves "differently" with the #define is interesting. Maybe some under the hood glue that is not present in the C environment, (which is what you are accessing when you do dllimport in the MONO environment).

 

KEJR

Link to comment
Share on other sites

Are you running the program on PowerPMAC ? What do mean "running with MONO"? Are you using mono tools from the IDE and using option Run in Mono? Or are you uploading the .Net app on PowerPMAC and then use Mono to run the App on PowerPMAC?

we tested ...#Define the variable "Test" in project and then downloaded to PowerPMAC.

In HMI called getresponse and read the variable "Test" and got correct value of Test. HMI uses communication library.

Then the App is uploaded to PowerPMAC and then run the app using Mono and it still read the "Test".

 

Thanks,

 

Atul

Link to comment
Share on other sites

  • 2 weeks later...
Guest
This topic is now closed to further replies.

×
×
  • Create New...