communication through parallel port *question*

Discussion in 'OT Technology' started by Soace Munky, Apr 15, 2003.

  1. Soace Munky

    Soace Munky New Member

    Joined:
    Mar 31, 2003
    Messages:
    12,519
    Likes Received:
    0
    Location:
    philly, more or less
    I need to communicate with a device through a parallel port.
    My project involves a stepper motor, an optical gate, and an ADC with an I^2C serial interface.

    I want to hook this up to my laptop through the COM port, and I have all the necessary hardware, all I'm lacking is the software. I tried writing some code in VB a while back, in the very beginning of the project, but I ran into some stuff I couldnt understand at all, and abandoned all hope.

    Can anyone point me in the direction where I can start looking for information? VB is most favorable to me, Im more familiar with it that any other language.

    Any help will be greatly appreciated.
     
  2. SLED

    SLED build an idiot proof device and someone else will

    Joined:
    Sep 20, 2001
    Messages:
    28,118
    Likes Received:
    0
    Location:
    AZ, like a bauce!
  3. 5Gen_Prelude

    5Gen_Prelude There might not be an "I" in the word "Team", but

    Joined:
    Mar 14, 2000
    Messages:
    14,519
    Likes Received:
    1
    Location:
    Vancouver, BC, CANADA
    You can also look at a program called WinWedge for COM communications (BTW - they're serial not parallel).
     
  4. Soace Munky

    Soace Munky New Member

    Joined:
    Mar 31, 2003
    Messages:
    12,519
    Likes Received:
    0
    Location:
    philly, more or less
    COM port is parallel, Im just using two of the pins for serial communication with the ADC, from Maxim Semiconductors.
    Funny story about that, they owned me by sending a tinyass surface mountable unit as their free sample. I dropped one, I couldnt find it. The damn thing is the size of a friggin tick. :mad:
     
  5. 5Gen_Prelude

    5Gen_Prelude There might not be an "I" in the word "Team", but

    Joined:
    Mar 14, 2000
    Messages:
    14,519
    Likes Received:
    1
    Location:
    Vancouver, BC, CANADA
    Why do they call them serial ports then? Just asking...
     
  6. Soace Munky

    Soace Munky New Member

    Joined:
    Mar 31, 2003
    Messages:
    12,519
    Likes Received:
    0
    Location:
    philly, more or less
    :donno:
    i found what i was looking for, btw. www.vbcode.com and a forum on www.codeguru.com helped.
     
  7. Astro

    Astro Code Monkey

    Joined:
    Mar 18, 2000
    Messages:
    2,047
    Likes Received:
    0
    Location:
    Cleveland Ohio
    The COM port is NOT parallel. COM ports are serial devices.

    If you look at the specs, the COM port has 1 receive and 1 send wire with several additional wires for DTS, CTS, flow control, and others.

    The data sent along a serial (or COM) port is sent on one wire. Lets take 8 bits. The 8 bits are lined up in a UART and one bit sent at a time down the send wire.

    Switching to the parallel port, the parallel port has 8 wires used for communications and several additional wires used for flow control and equipment status notification. Back in the old days, these 8 wires were send only. Then bi-directional parallel ports came out and allowed send and receive to occur on these 8 pins.

    When data is sent out on a parallel port, its sent on all 8 wires (usually - its up to the coder to determine data communications over parallel ports). Typically (and for best performance), 8 bits are lined up on the 8 wires and sent all at one time.

    Notice the difference here? In one clock cycle, the serial port has sent one bit out of the port. In one clock cycle, the parallel port has sent one byte out.

    Because of this fact, its important to keep the two seperate.

    Yes, its possible to re-wire the parallel port to function just like a serial port (I built a TI parallel graph-link cable - dirt cheap and worked well - but here the TI was looking for a serial port connection and it worked because of the software).

    Saying the COM port is parallel is very inaccurate (the COM port is a serial device with one outbound and one inbound data wire). Saying the parallel port is being used as a serial port would make much more sense...
     

Share This Page