Connect with us

Read Parallel Port

Discussion in 'Electronic Design' started by Sumedha Swamy, Nov 13, 2006.

Scroll to continue with content
  1. Hi,
    I'm trying to make a system to capture digital data continuously coming
    from a device that I own. There are 3 outputs that I could map to 3
    pins of the parallel port..One of the pins is the clock. Refer the
    diagram below :

    |--- Clock
    --//--- |--- Data Out 1
    |--- Data Out 2

    Figure 1 : Pins of the Parallel Port that I would like to capture data
    from.

    How do I capture the data onto my PC at every positive edge of the
    clock input ?

    Thanks,
    Sumedha
     
  2. Guest

    Depend on how fast your data is coming in. And what budget you have.

    Other than that it's in essence just to read 0x379 (asfair) ie the parallell
    port status register.

    You might use the strobe pin to accomplish an irq for every clock. Or maybe
    some other enchanced mode to speed up things.

    Also don't forgett this port is 5V.
     
  3. J.A. Legris

    J.A. Legris Guest

    The simplest way is to read the port repeatedly until the clock state
    changes and then read in the data. The problem is, of course, that
    unless you can predict roughly when the clock pulses are going to
    arrive, your program will spend 99.999% of it's time waiting for clock
    pulses. The preferred solution is to use interrupts. The following
    links will get you started.

    http://et.nmsu.edu/~etti/fall96/computer/printer/printer.html

    http://www.lvr.com/parport.htm
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-