Shop OBEX P1 Docs P2 Docs Learn Events
Serial Data over Parallel Port — Parallax Forums

Serial Data over Parallel Port

kingnebkingneb Posts: 65
edited 2005-10-14 03:34 in General Discussion
Is it possible to send serial data over·via the LPT1 port?· It is designed for parallel transmission, however with the right coding I think you can·send serial data via one of its bits.· If so, how do you set up the serin command to work with it?· I am trying to use an SX as a shift register.· My laptop has no serial port so I am out of luck there.·

Thanks

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
A friend of mine was a street bum for halloween.

Post Edited (kingneb) : 10/14/2005 2:04:13 AM GMT

Comments

  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-10-14 01:39
    What do you mean "parallel port"? Specifics, please....

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • kingnebkingneb Posts: 65
    edited 2005-10-14 02:01
    I modifed my original post, better?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    All my exes live in Texas


    Oh yeah, all my exes are six feet under the ground!!!

    Post Edited (kingneb) : 10/14/2005 2:09:16 AM GMT
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-10-14 02:38
    If you're using the parallel port to bit-bang serial (not a question that belongs in the SX forum) then you can use a direct connection between the port pin and the SX (you need to connect ground as well). The mode used (true or inverted) depends on how the data is being transmitted.

    If you have a free USB port then our USB2SER adapter can be used; we created it for ourselves to connect USB ports directly to microcontrollers.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • kingnebkingneb Posts: 65
    edited 2005-10-14 03:00
    How do I know what baud rate I need for bit banging (you can move this if it does not belong on SX)?· What is an ideal technique to indicate the microcontroller to begin sending?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    All my exes live in Texas


    Oh yeah, all my exes are six feet under the ground!!!

    One was a lineman who violated the one hand rule.

    The·second put his tongue on 10 car batteries wired in series.

    The third was involved in a tesla coil experiment gone bad.

    Post Edited (kingneb) : 10/14/2005 3:11:42 AM GMT
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-10-14 03:28
    You seem not to have grasp on serial communications. While I don't think it covers bit-banging the parallel port, Jan Axelson's book "Serial Port Complete" will fill you in on all the details of serial communications between microcontrollers. Also, our SX books by Guenther Daubach and Al Williams cover serial comms (from the SX) side and explain how it all works.

    The quick answer is that both sides have to agree on the baud rate, and the start bit signals the receiver to start sampling the serial line (at the baud rate) for serial bits.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-10-14 03:34
    This article might help too: http://www.parallax.com/dl/docs/cols/nv/vol6/col/nv117.pdf

    It explains serial with the SX and receiving serial data using an interrupt-driven UART in SX/B.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
Sign In or Register to comment.