I've got an Arduino V3+ and need to find the correct PIN number for its RX and TX-pin on the FTDI-connector.
How can I find out the correct number of them to use them with the SoftwareSerial-library SoftwareSerial mySerial(bluetoothTx, bluetoothRx)?
Why I need the PIN numbers:
I'm connecting a Sparkfun Bluetooth Mate/BlueSMIRF to the ArduiMUs FTDI headers and need to set a few settings in its command mode before it operates without flaws.
This is the code:
#include <SoftwareSerial.h>
int bluetoothTx = 1; // TX-O pin of bluetooth mate, Arduino D2
int bluetoothRx = 0; // RX-I pin of bluetooth mate, Arduino D3
SoftwareSerial bluetooth(bluetoothTx, bluetoothRx);
void setup()
{
Serial.begin(9600); // Begin the serial monitor at 9600bps
bluetooth.begin(115200); // The Bluetooth Mate defaults to 115200bps
bluetooth.print("$$"); // Enter command mode
delay(5000); // Short delay, wait for the Mate to send back CMD
bluetooth.println("U,9600,N"); // Temporarily Change the baudrate to 9600, no parity
// 115200 can be too fast at times for NewSoftSerial to relay the data reliably
bluetooth.begin(9600); // Start bluetooth serial at 9600
}
