Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drivers/xbee: disable CTS/RTS pin unless periph_uart_hw_fc is used #13224

Merged
merged 1 commit into from
Apr 24, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions drivers/xbee/xbee.c
Original file line number Diff line number Diff line change
Expand Up @@ -599,6 +599,14 @@ int xbee_init(netdev_t *dev)
_at_cmd(xbee, "ATMM2\r");
/* put XBee module in "API mode without escaped characters" */
_at_cmd(xbee, "ATAP1\r");
/* disable xbee CTS and RTS, unless hardware flow control is used */
if(!IS_USED(MODULE_PERIPH_UART_HW_FC)) {
DEBUG("[xbee] init: WARNING if using an arduino BOARD + arduino xbee " \
"shield with ICSP connector, hardware flow control can't be " \
"used since CTS pin is connected to ICSP RESET pin\n");
_at_cmd(xbee, "ATD6 0\r");
_at_cmd(xbee, "ATD7 0\r");
}
/* apply AT commands */
_at_cmd(xbee, "ATAC\r");
/* exit command mode */
Expand Down