COM Port Access

How do I send and receive data to and from COM Ports?
LVL 1
kiphughesAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

chensuCommented:
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
kiphughesAuthor Commented:
The first 2 links are invalid.
0
kiphughesAuthor Commented:
Nevermind my first comment.
0
Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

superekkeCommented:
You find the TComThread Component for Borland Builder to use asynchronous serial I/O ports. It is easy to use.

http://www.protogene.com/people/giles/builder.html

If you use the Borland Builder, ask me for examples
0
kiphughesAuthor Commented:
I should have explained myself better in the first place. I'm more into electronics than I am into programming, although I do have some programming background. However, C++ is a new thing to me.

I'm trying to get either the printer port or mouse port to send some kind of signal to an electronic device which I will connect to it. This electronic device is something I will design myself.

I need to be able to send signals to it, know what kind of signals they are, and how to control and manipulate them. All I really need is to send 1s and 0s to the port and know which pins to look for these signals.

I'm using Borland C++ v 4.52. If someone can give me a sample program, it would be greatly appreciated. Thank you.
0
superekkeCommented:
What kind of operating system you are using?
The using of ports is different for Win 95 / 98 or NT. It is more easy to access the ports directly in 95/98. On NT you need to use a devicedriver to access the ports
0
kiphughesAuthor Commented:
I'm using Win 98. How difficult is this going to be?

I'm also new to this experts-exchange thing. I do realize that there seems to be a point system here. I posted this exact same question titled "Serial or Parallel" -- or something like that. That's worth some 100+ points to whoever is interested.
0
superekkeCommented:
I'm also new in the experts-exchange system. If you ask a question you have to spend points for it. You choose the best answer to your question. The one who gives the best answer will get points.
So, under 98 you can simply access the port. For parallel port write the value to the portadress of the printer port LPT1.
e.g.
outp(0x378,0xeb); writes the value 0xeb to the printerport.
The serial port must be configurated befor using.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Software

From novice to tech pro — start learning today.