Home Parallel Port Serial Port Serial Info Parallel Info USB .NET Webboard I/O Today API Project Directory

 Hardware Interfacing and TCP/IP interfacing in VB programming.
Thai Page Clcik Here
Programming in Visual Basic to control through network part 1

       Nowadays, communication through Network, internet system that is popular in use, service, and convenience in routine because the fast communication and can link to many system, making application via network in many types.
This article will focus on application in control devices or programs. The topics you must know are the following;

       TCP/IP is the standard protocol in connection through network in order to connect with other computer. TCP/IP include the 2 main parts,  
TCP(Transmission Control Protocal) 
IP(Internet Protocal)
Actually, in communication, we may not see step of system's working because it is working of Software&Hardware. However, we will explain for understanding of protocol TCP/IP in the following;

- IP Address: for transferring data in the internet system will be set and reference by IP address. Actually, there are lots of computers in the internet system, using IP address will not be convenient, and so it is changed to using domain name. All are in Name Services that instead of IP address.
- Routing Configuration: The advantage of protocol TCP/IP is setting trace for transferring that is automatic. If some trace is damaged, machinery system of trace setting for transferring of protocol TCP/IP, will select the best.
- Protocol, Ports, Sockets: are the ways for direct setting of transferring except setting after IP address.

Identifying IP address of computer

You go to Windows that have program; named IP Configuration, file EXE. It is at Windows/Winipcfg.exe like the following;/Winipcfg.exe ครับโดยมีหน้าตาดังรูปด้านล่างนี้

More information - click More Info.


Server &  Client 
    The topics we mention in programming for use in Network, the main of system will be divided into 2 parts, including, Server and Client that in real use may have other component, but we will not mention because I want you clear and easily understand.

Server is the part working as administer, public relation, messenger, manager for system, client that will request from Server. Server will be the part that keep data, manage, administer data or system resource for client can use.

Server and client have IP Address, Port. Both side will can communicate in the case of the same channel that can set number of port. Program that communicates must reference the number of port every time because the system has lots of program communicating.


MS Winsock Control 6 
      All I mention are the knowledge that must understand. For people who haven't know yet what we will do, in this section we will focus on how to program on Windows to communicate on network that have Tool that help us to program via network. It's MS Winsock Control 6 that is the tool that is convenient for programming interface via network by protocol TCP/IP that we will write by Visual Basic or who are good at C/C++ , you can use Visual C++, for Pascal, using Delphi chose VB because easy explanation and didn't complex. Moreover, API that has the developers write, but Winsock can use more easily that I will focus on the next part.  

Data Reference : Visual Basic Programming Guide / http://www.vb-world.net / http://earthweb.com /

Copyright (c) 2000-2008 thaiio.com all rights reserved.  Contact webmaster :webmaster@thaiio.com