• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 259
  • Last Modified:

Port

How can I use Serial/Parallel Port from Delphi 6 ?

Thanks,
Andrew
0
andrewyu
Asked:
andrewyu
  • 3
  • 2
1 Solution
 
Mohammed NasmanSoftware DeveloperCommented:
0
 
andrewyuAuthor Commented:
Do you mean that I cannot access the port by Delphi (e.g. port array) directly ?
0
 
JohnjcesCommented:
Yes you can access the ports both printer (LPT) and com ports as well as joystick ports etc in Delphi. Delphi 1 and Pascal had Port() commands that could read and write directly to any memory location or physical device location.

Try SmallPort for starters. It is freeware with all source and works on all versions of Windows. You need special port drivers to access ports directly in any of the NT versions of Windows, i.e. NT, 2000 and XP.

Download from:

http://www.torry.net/vcl/system/portaccess/smport.zip

Hope this helped you!
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
andrewyuAuthor Commented:
Thank you very much for you information !

But, can I access the ports by open file funciton in Delphi (rather than using 3rd component) ?
0
 
JohnjcesCommented:
Simply, no.

You must use a third party or your own component to peek and poke (BASIC) your ports.

Unless we are not fully understanding what you are wanting to do. If you want to open a com port as a file look at:

http://www.cpcug.org/user/clemenzi/technical/Languages/Delphi/Delphi_SerialIO.htm

Maybe this is what you want to do.
0
 
andrewyuAuthor Commented:
Hi Johnjces,

That's what I want to know.
Thank you very much for your help !
I will try it little bit later.

Andrew
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now