I am about to use a Micro where I only use the Rx on Serial 1, so TX/D1 is not used, and only send on SPI, so CIPO/D14 is not used.
My question is, can I use D1 and D14 as digital I/O pins?
I am about to use a Micro where I only use the Rx on Serial 1, so TX/D1 is not used, and only send on SPI, so CIPO/D14 is not used.
My question is, can I use D1 and D14 as digital I/O pins?
I don't sure about UART but on SPI every sending is accompanied by receiving and vice versa, so the answer is NO - you can't use a 'free' SPI pins for anything else than SPI
I'd doubt it with serial, as you're awaking the UART as a whole when you call Serial.begin(). So likely a no- go. But only the core code would reveal for sure, mine is just a semi-educated guess.
You could try this (untested):
Serial1.begin(9600);
UCSR1B &= ~(1<<TXEN1); // disable transmit on Serial1
Maybe, it depends on which processor you are using.
There aren't that many options with a Micro.
Thanks for all the answers. It looks as though the answer is no, but I have now worked out how to multiplex the 7 links I need to read, so I only need 3 O/Ps and 1 I/P instead of 7 I/Ps. So all sorted thanks.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.