Jump to content
OMRON Forums

Connecting to PowerPmacServer from VB


RickJames

Recommended Posts

I am trying to open a connection to the PowerPmacServer on the Delta Tau demo rack from a VB application. Here is the connection code: [i]bIsConnected = objPPMac.GPAsciiConnect("192.168.0.222", 8086, "root", "deltatau")[/i] All the parameters are correct. They work when I connect using Telnet with a port number of 23. I've also tried the sample C# Visual studio projects with the same results. Telnet opens, PowerPmacServer doesn't. How do I tell if the server is actually running on the PowerPmac? And is there some other code that I'm missing? It lookes pretty simple in the sample projects. Thanks for the help.
Link to comment
Share on other sites

  • 5 months later...
  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

[quote='shelinej' pid='1077' dateline='1295012428'] I am trying to do something like this and I can't get it to work either. Did you ever find a solution? [/quote] Right now there is not solution. The response I got form Delta Tau is that the server connection is still in beta and is not available in the Power Pmac firmware. The telnet connection however, does work and I am using it successfully. Get the latest versions of the comm library, IDE, and firmware as there are some important bug fixes in them. Notably the ability to do tru syncronous connections. The latest IDE has the addition of visual basic programming examples also. Here are the versons I have. Bradp should be able to tell you where to get them: IDE = v1.1.2.45 firmware = 1.2.1.128 PPmac Comm Lib = 1.0.3925.26557 (dated 9-30-2010) Hope this helps. And if you need code examples, send a reply and I'll do what I can. Rick
Link to comment
Share on other sites

Rick, I have been fighting with the Telnet solution and can connect but all I get back is a bunch of gibberish and I cant seem to send any commands. I've tried a number of different connection schemes but can't get anywhere with it. Could you send me an example of how you do your connection? Thanks, Scott
Link to comment
Share on other sites

Scott, Here are the declaration, connection, set variable, and get variable code I'm using. Good luck. Rick ' This object delcaration is from the latest version of the Comlib, and is different than the original beta version. Public Shared objPPMacAxes As PowerPmacComLib.ISyncGpasciiCommunicationInterface ' This specifies the object as sycronous GPascii telnet connection. objPPMacAxes = PowerPmacComLib.Connect.CreateSyncGpascii(PowerPmacComLib.deviceProperties.ConnectionTypes.Telnet, objPPMacAxes) ' If the connection is good, this will return a true value mResult = objPPMacAxes.GPAscii2Connect(.PPMac_Address, 23, .PPMac_Login, .PPMac_Passwd) If Not mResult Then Throw New Exception("Could not connect to PowerPmac.") End If ' Set a variable on the power pmac. objPPMacAxes.GetResponse(VarName & "=" & Value, mResponse) ' if it worked, will return an empty string. If mResponse.Length > 0 Then Throw New Exception("The GetResponse method returned an error.") End If ' Retrieve a variable value, or just execute a command. objPPMacAxes.GetResponse(VarName, mResponse) If InStr(mResponse.ToUpper, "ERROR") > 0 Then Throw New Exception("The GetResponse method returned an error.") End If
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.

×
×
  • Create New...