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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RS232 communication in Pascal

Status
Not open for further replies.

Hebbe

Programmer
Jun 14, 2003
17
NO
I would like to send and receive data via the RS232 COM port on the computer.

I know one can use the port array for simple tasks, but I've seen simple implementations of programming the UART-chip of the computer in DOS/Pascal environment. This code was posted at this forum about 2 years ago.

This program included initialization of the UART chip and an array type variable in pascal to use indepent from the interrupt-driven process in the UART.

So problem is I cannot find the example code, and would like if You know of similar examples.

 
Hi Hebbe,

I would do it with inline assembler (or asm function) in TP/BP.

You need to know the details of INT 14h (that's a BIOS interrupt service for com ports).

Here's a reference link I found:


I did write a unit for this once in the past but cannot find it right now.

My response is only valid if you know ASM and interrupt services. Are you familiar with ASM programming in Pascal? If not -get back with a comment.

If you need to look at some examples, then try looking at SWAG :
Again, SWAG is only valid if you're an experienced programmer because some of the code snips are complex and not too good commented for novice programmers.

Hope you find my response helpfull §:O)

Good Luck


Jakob
 
Although I never really understood the whole rs-232 thing, I do have a unit (bunch of files actually) that do zmodem. I was able to use a fair amount of procs from that unit, even tho I never really had a need for zmodem in that way. If you're interested, let me know where I can email it to.



Cheers,

Realm174
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top