SparkFun Forums 

Where electronics enthusiasts find answers.

For the discussion of Arduino related topics.
By DonTelescope
#189462
I have the Ardino Pro Micro connected via Serial1 to a BlueSmirf bluetooth modem.
The bluetooth modem connects to a Sky Safari application on and Andriod Tablet.
I can for diagnostics purposes send and receive with the IDE Serial Monitor via the USB Serial port.
I can manage the setting on the BlueSmirf with a pass thru program.

The Sky Safari application connects to the modem and then sends and ASCII "Q" and expects a reply. It sends six "Q" per second for two seconds and if no reply is received it disconnects from the modem.

My Serial1.read() receives no data until the modem disconnects and then I receive a batch of 12 "Q" but by
that time the modem has been disconnected.

I have tried waiting in a Serial1.available() with the same results.
The code works fine with an Arduino Uno and the same BlueSmirf.
It seem that the Serial1.read() does not complete until the modem disconnect.
The 12 "Q"'s seem stuck in a buffer somewhere, I am not sure if it is in the Micro UART or the BlueSmirf UART.
I am stumped, any suggestions?
Update:
I installed a terminal emulator on my Andriod Tablet and I can make my Arduino code work correctly with the
terminal emulator by typing "Q". So, I must investigate how the Sky Safari App is connecting. There does not
appear to be a problem with the Micro or BlueSmirf, more later

PROBLEM SOLVED

I tied CTS to RTS and everything worked as expected.

The manual said that SPP does not use flow control.
I had CTS open on my Arduino Uno proto board implementation and it worked.
Lesson learned, never leave inputs open.