Hey,
Am not that stupid....
I know the algorithm about how the programming should work...
At the server side (PDA) that will serve the client (computer) requests:
1. A socket is opened and the machine listens for all clients at a particular port number.
2. Simultaneously the serial port of the device is also opened.
3. The data input stream created by the socket is connected all the way to the serial port. So any data stream that the socket receives is immediately sent out of the serial port. This is done a string at a time.
4. Once the data string is sent out of the serial port the machine is ready to receive another string of data from the client.
5. The steps 3 and 4 are repeated till the connection is closed by the client.
6. Once the connection is closed, the machine stops listening on the port number and
Simultaneously closes the serial port.
To start a new connection the server program will have to execute again
Programming the client –the desktop computer in order to send commands for the motor over the network involved the following steps:
1. Open a socket by creating a socket object
2. Create an output stream consisting of the commands for the control board.
3. Send the input stream over the network.
4. Close the socket when the application is completed.
The client program has the IP address of the handheld device. This program runs on the desktop computer. . To make a connection request, the client tries to rendezvous with the server on the handheld device and port.
Did you just answer your own question?
If you are a total '''''newb''''' like you said you were, then take a year to learn what you need to do first.
Reputation Points: 113
Solved Threads: 19
Postaholic
Offline 2,108 posts
since Jun 2004