LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 07-04-2009, 02:08 AM   #1
eboy98
Member
 
Registered: Oct 2007
Distribution: RHEL5
Posts: 64

Rep: Reputation: 15
some confusion about parallel port programming.


#define port_base 0x378
#define port_status port_base + 1
#define port_control port_base + 2

hello there, i cant understand the last two line - port_status port_control.....can any one give some clear idea or show me the
way(site address) from where i can take help.

thanks.
 
Old 07-04-2009, 08:08 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,700

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
There is lots of information that can be found by googling on how a parallel port works.

If you look at a description of the original PC parallel port there are 17 I/O lines that are accessed/controlled via three 8 bit ports. The arrows show if they are inputs or outputs referenced to the computer. The second link shows the signal timing and basically how communications works.

Base port - Data bits 0-7

Status port - Input pins i.e. signals coming from the printer like paper out and printer busy

Control port - output pins i.e. strobe, autofeed.

http://www.lammertbies.nl/comm/cable/parallel.html
http://www.interfacebus.com/Design_C...l_PC_Port.html

Last edited by michaelk; 07-04-2009 at 08:12 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Parallel port programming joakim12 Programming 2 09-17-2007 10:49 AM
Parallel Port & Serial Port device identification helpmeforlinux Linux - Hardware 3 01-02-2007 01:15 AM
Parallel port programming for Linux pzydak Programming 1 12-01-2006 06:16 AM
parallel programming 2395 Programming 1 10-08-2005 06:44 PM
Programming the parallel port via /dev/lp0 Nerox Programming 3 01-09-2005 05:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:12 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration