drjohnsmith
Well-known member
thank you.....
where is the 1.26 beta to try please
Should I leave this RTS/CTS stuff in Serial1 for the final 1.26 release?
Anyone have any final thoughts? I want to make the release later today!
The RTS/CTS code made it into the final 1.26 release, but only for Serial1.
I'm looking for feedback.... should I replicate it to Serial2 and Serial3, or are there issues to be resolved first?
static inline void comm_send_ch(mavlink_channel_t chan, uint8_t ch)
{
if (chan == MAVLINK_COMM_0)
{
uart0_transmit(ch);
}
if (chan == MAVLINK_COMM_1)
{
uart1_transmit(ch);
}
}
#endif /* YOUR_MAVLINK_BRIDGE_HEADER_H */
I've updated the web page with RTS & CTS documentation.
http://www.pjrc.com/teensy/td_uart.html
Please remember we *still* don't have flow control on Serial2 & Serial3, due to lack of feedback. I really hope a few more people will eventually report success (or issues) with using it on Serial1.
For your Mavlink project, in theory this should work. All you have to do is call Serial1.attachRTS() and Serial1.attachCTS() after that code has as started using the serial port. Assuming your Mavlink device has proper RTS and/or CTS signals, it ought to work.
Paul (and others): I believe I might actually need to use RTS/CTS on my current project, and I'd love to use that to help you test it! I've got Serial2 on a Teensy 3.6 connected to Serial1 on a Teensy 3.2. Ideally, the way these things will (eventually) be parked on their circuit board, it'd be wonderful to use Serial5 (pins numbered 33 and 34) on the Teensy3.6 because there are lots of pins I'm not using directly adjacent to them that I could assign to RTS/CTS duty. It'd be right next to the Teensy 3.2. For that matter, I could even go into Serial3 on the Teensy 3.6 and get shorter board traces. I've been skimming your thread here (and understanding *some* of it). From what I gather, actually *using* the flow control is nothing more than declaring the functions of the pins, connecting them, and then using them? Do you have an example I could look at or modify as a starting point?