Click to See Complete Forum and Search --> : Using RS-232 Standard


omerash
September 11th, 2002, 03:57 PM
i want to implement a communication b/w two pc's via null modem using serial ports. I really dont know how to do this. Help in terms of assembly code is also acceptable.Plz help me !:confused:

omerash
September 11th, 2002, 04:30 PM
i have learned abt the rs-232 pin structure and thier working too , the problem is the communication with the hardware and the flow control ( hardware method preferred ) .. looking forward for ur help

CodeJockey
September 12th, 2002, 11:46 AM
If your systems are using Windows, then a good description can be found by searching MSDN Help for the following article:
"Serial Communications in Win32"

It is from 1995, but discusses all sorts of RS-232 communications issues, and provides a sample VC++ project.

cup
September 12th, 2002, 01:46 PM
You didn't mention what OS/compiler you are using. Comms on Unix/DOS/Windows/QNX/VxWorks/RMX is very different.

omerash
September 13th, 2002, 05:31 PM
yes ,its Windows 98 using simple c/c++ compiler like Borlandc

Thanks for ur replies,
omerash,.

cup
September 14th, 2002, 02:05 AM
Even if it is Borland C, Serial Communications in Win32 (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnfiles/html/msdn_serial.asp) still applies. The alternative is to do it in the old DOS way using the old BIOS calls but they may not be available from your compiler.

With flow control, all you need to do is set it up and the hardware will take care of the rest for you.

omerash
September 16th, 2002, 05:19 PM
i have gone through that Article, even im not having any idea of WIn32 programming but all the stuff is windows based programming , i wanna know communication thats dos based. The command line argument will tell which terminal's programme is going to be Server...

omerash..

cup
September 16th, 2002, 06:28 PM
Which version of Borland C do you have? Is it Turbo C (TC) or Borland C++ builder (BCB)? Serial comms in BCB is the same as microsoft. See Serial Communications with Borland C++ Builder (http://www.traverse.com/people/poinsett/bcbcomm.html). Almost everything in there is mentioned in the Microsoft article. This is console based. Not quite the same as 16-bit DOS but it will work on 32-bit DOS. It includes windows.h for the prototypes but it is a console based program. It fools a lot of people: a windows header appearing in a console based program.

TC, on the other hand, is something else. You can get some examples in Programmer's Heaven (http://www.programmersheaven.com/zone3/cat409/).