Ethernet Capability

Jim G.
LaVergne, TN

Jan 12, 2010
1 Post

0  |  0  

Re: Ethernet Capability

Are ehy any drivers or commands for ateay to commuicate via an ethernet connection

Arne V.
Almelo OV,

Jan 14, 2010
3 Posts

0  |  0  

Re: Ethernet Capability

Hi Jim,

Check the code example below ....

Arne


/*!

  \brief        Open telnet connection

  \description  Open telnet connection with target
                  Keep connection open until TelnetClose is called.

  \param[in]    sNameAddress        IP address of target to connect with

  \return       TRUE    Success
                  FALSE    Error. Use GetErrorMessage() to get error

  \pre          SetTelnetPort() must be called.

  \post         none
*/

/* Store telnetport for later use */
TelnetSettings.Port = lPort

/* Returns the address for a specified host name or string address */
TelnetSettings.Address = WsGetNameAddress(sNameAddress)
if ( TelnetSettings.Address = -1 ) then
    ErrorMessage("TelnetOpen: WsGetNameAddress() failed")
    return FALSE
endif

/* Open a TcpIp Socket for Client communication */
TelnetSettings.Socket = WsCreate(aWsTcpIp, 0)
if ( TelnetSettings.Socket < 0 ) then
    ErrorMessage("TelnetOpen: WsCreate() failed")
    return FALSE
endif

/* Connect to the target */
lStatus = WsConnect(TelnetSettings.Socket, TelnetSettings.Port, TelnetSettings.Address, 5000)
if ( lStatus <> 0 ) then
    ErrorMessage("TelnetOpen: WsConnect() failed")
    wsclose(TelnetSettings.Socket)
    return FALSE
endif

return TRUE

Solution Available
DrATEasy (Ron Y.)
Mission Viejo, CA

Jan 14, 2010
367 Posts

1  |  0  

Re: Ethernet Capability

Also, look at the WsChatIE.prj and the WsChatMT.prj examples that are in the examples folder. These examples show how to communicate between computers using Ethernet and the ATEasy WsXXX internal functions. You can also use IO Tables to do that.



Please Note
You need to have a M@GIC account to participate in the Forums.
Not yet registered on our website? Click here to register today!

All content, information and opinions presented on the Marvin Test Solutions User Forums are those of the authors of the posts and messages and not Marvin Test Solutions'. All attachments and files are downloaded at your own risk. [Read More]