1

Do they have specific pins that is best to be use as Rx/Tx pins (aside from D0 and D1)? If so, what makes them special?

edit: What pin feature i should look out for when choosing the rx/tx pin? Is there any specific pins that will make it a better rx/tx pin?

slifer
  • 11
  • 1
  • 3
  • 1
    https://arduino.stackexchange.com/questions/34126/whats-the-difference-between-all-the-software-serial-libraries-which-one-is-ar – Juraj Nov 08 '18 at 06:24

2 Answers2

2

Pins D0 and D1 are used for hardware serial, see Serial library reference.

You can use any other pins for virtual Rx/Tx lines employing a software serial mode, for example by using the SoftwareSerial library, see Software Serial example, or by implementing your own custom code, or custom library.

Greenonline
  • 2,844
  • 7
  • 31
  • 46
1

The Arduino SoftwareSerial library can use any pair of pins.

AltSoftSerial uses special pins. AltSoftSerial uses a 16 bit hardware timer to generate the transmit output and measure the receive input waveforms. The timer works on pins 8 and 9 on Uno and Atmega 328p boards.

Juraj
  • 17,050
  • 4
  • 27
  • 43
  • thanks. So this is alternative library to software serial is it. i will read about it first. – slifer Nov 12 '18 at 01:39