Shop OBEX P1 Docs P2 Docs Learn Events
fdserial between two propeller 'flip' modules.; A Reopening - Page 6 — Parallax Forums

fdserial between two propeller 'flip' modules.; A Reopening

12346»

Comments

  • what is true mode serial?

  • JonnyMacJonnyMac Posts: 9,412
    edited 2025-08-11 22:34

    True mode serial has a high idle state, a low start bit, data bits match (sent LSB first), and a high stop bit.

    From your code:

      FTD.start(11, 10, %0000, 9600)
    

    The 3rd parameter designates the mode:

    '' Start serial driver (uses a cog, returns 1 to 8 if successful)
    '' -- rxp.... receive pin (0..31)
    '' -- txp.... transmit pin (0..31)
    '' -- mode... %xxx1 = invert rx
    ''            %xx1x = invert tx
    ''            %x1xx = open-drain/open-source tx
    ''            %1xxx = ignore tx echo on rx (for half-duplex on one pin)
    

    (These comments are from jm_fullduplexserial.spin which is a small modification of the original fullduplexserial.spin from Chip)

    With a mode parameter of %0000 you not going to invert either pin, and you're not counting on a pull-up to generate a "1" on the line. That said, sometimes we'll still put a pull-up on RX so that a disconnection doesn't case false RX bits.

  • @JonnyMac said:
    With a mode parameter of %0000 you not going to invert either pin, and you're not counting on a pull-up to generate a "1" on the line. That said, sometimes we'll still put a pull-up on RX so that a disconnection doesn't case false RX bits.

    Since the normal idle state is high, a pull-up will make a disconnection appear just like an idle line. So isn't a pull-down on RX more correct because it will make a physical break condition appear as a BREAK condition?

  • JonnyMacJonnyMac Posts: 9,412
    edited 2025-08-11 23:37

    Since the normal idle state is high, a pull-up will make a disconnection appear just like an idle line. So isn't a pull-down on RX more correct because it will make a physical break condition appear as a BREAK condition?

    Only if your serial driver can handle the break condition. I've not seen a version of FDS that does.

  • bbrienbbrien Posts: 595
    edited 2025-08-13 03:02

    I would assume that if I use on the hand box that I should also use on the mount side even though every thing is half duplex serial. also I don't need any pull ups on the tx pins, but still I should use on the rx pins.

  • Your setup never sends data from mount to handbox. You could cut that line.

Sign In or Register to comment.