Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

TCP/IP handshake not happening 1

Status
Not open for further replies.

iDio

Technical User
Dec 23, 2015
13
0
0
PT
hey there!
i'm programming a device with internal scripting features ( basically it decodes some files, i just format the output content the way i want ) and i want to connect that device to another device that runs like a server application, to read the final output content.

they're connected via Ethernet cable and using tcp/ip connection. i made sure they were using the same telnet port. The thing is, the 1st device runes as master and the 2nd one as slave (by default). The master is using DHCP and the slave has static ip configuration(there's no other option). When i connect them nothing happens. not even a beep signal.. i thought that there was suppose to happen some kinda handshake connection .

I tried different configurations, like both static and with the same subnet mask. but nothing happens. can someone help me? is it wrong to use dhcp in master device?
The scripting used is JavaScript based . do i have to implement something to connect the devices? ty all
 
Ping both devices from each device and from eachother.
 
where does that help me? it's an honest question, i'm not being sarcastic!
 
Pinging each device from the other ensures that the two devices can communicate on the LAN segment.

Quick question for clarification. You say “they’re connected via Ethernet cable”. Are they directly connected to each other, or are they connect on a LAN through a switch?
 
Directly connected. That's why i don't understand the ping each other part.

The devices don't have a cmd prompt .. they are programmed to communicate between them and to decode an output value(s) .
 
Well, that helps.

#1, the IP addresses of the devices should be static. Setting to DHCP requires a DHCP server to dole out the addresses. If you only have two devices directly connected, (unless one is also a DHCP server), the master would never get an appropriate IP address.
#2, the subnet mask should be the same.
#3, you will need to use a cross-over Ethernet cable. Pins 1&2 on one end should connect to pins 3&6 on the other, and vise-versa.
 
Thank you @robertjo24 !!

I was going to ask that too. Yet, i was already using the same subnet mask. At first i thought that DHCP would be automatic.
Tommorow i'll try the way u say, like 192.168.1.10 and 192.168.1.20 . subnet mask 255.255.255.0 .

I was using normal cables though. i'll make a new one easily. I'll give proper feedback tomorrow or smth ! ty
 
If the devices are directly connected back to back with no DHCP server in the mix then you would have to assign fixed IP addresses to each device.
 
If they are direct connected with enet, and not through a hub or switch, wouldn't you have to use a crossover cable? Also as stated above, with nothing acting as a DHCP server, you will have to set static IP on both devices.
 
Indeed yes, as rclarke250
Use a crossover cable or a switch to connect both devices.
Crossover cable details at Link
 
hey there ,

i'm here just to close this thread. it works properly the way u all said it ! thank you !
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top