I am currently trying to communicate between my Arduino Nano and my Bluetooth serial terminal aplicatpion on my laptop.
What I am trying to do and have done before:
I upload my code into my Arduino Nano through the USB cable, cross-connect the transmit(Tx) and receive(Rx) pins between my Nano and the HC-05. Then I can type into the serial send row in the Bluetooth serial terminal application and I can send my data in and receive my data lines in the Bluetooth serial terminal application like this image below.
After that, without making any changes to the code, I unplug my USB connector and plug in a 9V battery positive end to the Vin and negative end to the GND pin of my Nano. I then connect my Bluetooth serial terminal application with my Nano through the HC-05 module and the sending and receiving of serial data is the same as when I power up the Arduino Nano with a USB cable to the Arduino.
The issue now I am facing is:
The HC-05 Bluetooth module serial communicates between the Nano and the Bluetooth serial terminal application on my laptop fine like above mentioned but only when the Nano is connected and powered by the USB cable.
However, when I repeat the steps of using the 9V battery, I am able to establish a connection between the Nano and the Bluetooth serial terminal application but when I send my command to the Arduino Nano, I no longer receive any output from the Arduino Nano through the HC-05 module.
I have tried replacing the Nano with another Nano, with UNO and tried replacing the HC-05 module. All gave the same result of only working when they are USB cable connected and not when they are 9V battery powered.
The only change I made between the time it was working and now when it was not working was adjusting the COM settings (Now they are correctly selected) and the processor selection to old bootloader and programmer to ArduinoISP. I am not too sure whether the changes in the settings caused some sort of failure to communicate or is it a hardware issue.
I apologise for the long post, but I really need help with this as I can't device cannot rely on being cable connected. Please feel free to ask more questions if there are things unclear.