Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
11 years, 4 months ago.
Half Duplex serial
Can this serial object be used to implement halfduplex serial? I will have both TX and RX pin connected to the same line. But I would need the TX pin to be open/drain - programmed as an input when the mbed is not transmitting so as to not interefere with any other device on the line that wants to transmit so they may all receive properly.
can i change the pin direction of the same pin used in the serial object?
like can i have code similar to:
Serial port(p9,p10); DigitalInOut tx(p9); tx.input(); .... some code tx.output(); port.putc('A'); tx.input();
i.e. can two objects be defined with the same pins etc.?