Can anyone help me, I'm having a little trouble connecting to a host. The host in this case is a micro-controller, and it has an IP address which I know, and I want to connect to it. I've tried WinSock, but I haven't had any success with it. The micro-controller has an IP address, but no port number. I need to be able to send commands and receive a response from the micro-controller. But first, I just want to connect to it via TCP/IP. Any information you can give me would be really appreciated. Thanks.
It's funny you should mention that because it never crossed my mind. I've been looking into winsock for the past two days. To answer your question, no, there is no winsock server running on the micro-controller. The problem I'm having is that I haven't dealt with TCP/IP yet, so I'm not even sure where to start. I've done a search on the forum, but haven't found anything helpful so if anyone can point me in the right direction, I would really appreciate it. Thanks again.
Sounds like the microcontroller is "socketless". You need to find out what protocols it actually expects...time to RTFM...
TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
2008, 2009 In theory, there is no difference between theory and paractice; in practice there is.
* Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions
* How NOT to post a question here
* Of course you read this carefully before you posted
* Need homework help? Read this first
First off, I want to say thanks to everyone for their response. I just got off the phone with the manufacturer and got the port number for this micro-controller. So now I got the IP address and the port number, so I should be able to communicate with it with Winsock right? Anyone know where I can find a simple code for reference, or any tutorials? I've never worked with Winsock before.
I was in the same trouble about starting programming winsock, i can give you those links, they are very clear in connecting and accepting connections...in your case you only have to create a socket with the ip and port and if the server accept you, you can start sending and receiving data ...