Shop OBEX P1 Docs P2 Docs Learn Events
FullDuplexSerial question — Parallax Forums

FullDuplexSerial question

stefstef Posts: 173
edited 2008-09-26 18:44 in Propeller 1
Hi

I'm a newbe at propeller so just answer and help me with a smile even if the question is stupid. I'm trying to use the FullDuplexSerial object. If you only want to use RX (no TX needed) how do you declare the start command.

ex: RS232.start(RS232D,??????,0,2400)

Between the brackets you need to give the rx , tx ,mode, baude rate. If you don't need the TX. What do you do.

RS232.start(RS232D,0,2400) don't work.

Thanks for the advice.



Stefan

Comments

  • Ken PetersonKen Peterson Posts: 806
    edited 2008-09-26 14:32
    I think you can put a -1 for the pin you don't need.···· <- I guess this only works for Simple Serial.

    Upon closer inspection of the code, it seems FDS assumes a valid pin for both transmit and receive (hence, "Full Duplex") and it sets the TX pin to an output.· To get the high speed of FDS without using a transmit pin, it may be necessary to revise the object to allow the option of receive only.·

    Just as a side note, for a transmit-only application, you can just assign the same pin to RX and TX and the object will work.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"I have always wished that my computer would be as easy to use as my telephone.· My wish has come true.· I no longer know how to use my telephone."

    - Bjarne Stroustrup

    Post Edited (Ken Peterson) : 9/26/2008 2:43:04 PM GMT
  • stefstef Posts: 173
    edited 2008-09-26 14:59
    Hi Ken

    So it seems I need to give the TX pin nr. Can I give for several obejects the same TX pin and use the tx pin to connect a led. I dont want to use it in the serial connection but I don't want to lose mutch pins.

    Then I van usit the led to inidate something with the outa[noparse][[/noparse]pinnr]. Has the FullDuplexSerial object problems with using the same tx pin wit outa statemends.



    stef
  • StefanL38StefanL38 Posts: 2,292
    edited 2008-09-26 18:44
    If I remebmer it right,

    it is possible to use ONE Pin for both directions
    this has to be combined with mode bit 3 = ignore tx echo on rx

    If you don't use TX it should work anyway

    best regards

    Stefan
Sign In or Register to comment.