-
Notifications
You must be signed in to change notification settings - Fork 5
Hardware control flow (RTS, CTS)
Hardware control flow allows us to use the Erika with maximum speed. Without that, we would need to wait long enough until we can be sure that the Erika is ready to receive the next character.
Moved to RaspberryPI Setup
The above approach uses the Device Tree to set the Raspi GPIO Pins 16 and 17 to ALT3 mode, which gives us the RTS/CTS lines.
In case you have a Raspi with a 26-pin header, RTS/CTS are on pins 30 and 31 of the P5 header. For this, you will need uart-ctsrts-p5
instead of uart-ctsrts
in the above step-by-step guide.
Current versions of RasPi kernels and firmware like Raspbian use a Device Tree (DT) in order to . More info: Raspberry Pi docs: Device Trees, overlays, and parameters
Discussion: RaspberryPi Forum: How to enable CTS RTS for Raspberry Pi 3 b+ UART
- use https://github.com/mholling/rpirtscts to set the serial port in the right Mode
- enable rtscts and set right speed with stty
stty -F <device> rtscts
stty -F <device> speed 1200
These steps have to be repeated after every reboot.
The USB-to-serial adapter FT232RL supports hardware control flow (using the RTS/CTS lines), however, it can take up to three characters after the Erika sends its busy signal until the adapter stops sending data.
If CTS# is logic 1 it is indicating the external device cannot accept more data. the FTxxx will stop transmitting within 0~3 characters, depending on what is in the buffer.
This potential 3 character overrun does occasionally present problems.
source: https://www.ftdichip.com/Support/FAQs.htm
For our case, this is not enough.
If it does not work,
- double check your tty settings by
stty -F <device> -a
- Check your solder joints, connections and wiring
- Use a voltmeter and/or a logic analyzer
- The Raspberry Pi UARTs from the official docs
- The Kernel Command Line (cmdline.txt) from the official docs
- https://elinux.org/RPi_cmdline.txt
- https://elinux.org/RPiconfig