I wanted to ask gabenix some more questions about use of HC-05 Bluetooth Modules but didn't want to hijack CSGuy's thread further. Here is gabenix's initial reply. I have a few more questions I am hoping he/she can answer but anyone please feel free to chip in.
gabenix: Hi Paul... To be honest I couldn't find any tutorials to explain how to program/upload sketches with the HC-05. In fact, the conclusion you came up with is in-line with all the information out there. But it's actually an extremely simple solution.
The only thing that keeps the HC-05 from uploading a program to arduino is that it doesn't have a DTR (Data Terminal Ready) pin which tells the arduino to reset and accept a new sketch.
The solution is to re-purpose the "state" pin (PI09) on the breakout board. It's purpose is to attach to an LED and indicate the connection status. It's default setting is to send the pin HIGH when a connection is made, but you can simply enter into command mode of the HC-05 and use an AT COMMAND to tell it to send the pin LOW when a connection is made.
Voila! In about 1 minute of time you have successfully re-purposed the LED pin to a DTR pin which will reset your arduino to accept a new sketch when you hit the upload button.
A couple things to note... This will work for a pro-mini without additional hardware by connecting to the DTR pin. If you're using an UNO or similar, you will need a capacitor in between our custom "state" pin and the reset pin on the uno. The reason is that the HC-05 will drive our custom pin LOW for the entire connection which would essentially be the same as holding the reset button the entire time. Having the cap in between solves that problem.
It a quick easy fix, takes about a minute to do. It's just a lot harder to explain the steps to do it in a couple sentences.
Here's a link to the AT COMMAND set ---> http://robopoly.epfl.ch/files/content/sites/robopoly/files/Tutoriels/bluetooth/hc-05-at_command_set.pdf
and here's a link to a tutorial, video, and sketch on how to enter the AT COMMANDS. ---> http://www.techbitar.com/modify-the-hc-05-bluetooth-module-defaults-using-at-commands.html
Hope this helps answer some questions...
Thanks again gabenix. I have more questions!
Are these settings (changed with the AT commands) saved in its non-volatile memory? So they don't have to be repeated after each power-up?
If the STATUS pin indicates that a BT connection is running, then resetting the remote Arduino will involve breaking and re-making the connection? Does the Arduino IDE do this somehow each time you hit Upload, or is some extra step needed?
Will this technique work with Pro Micro/Leonardo (I suspect not, only Uno/Pro Mini etc based on ATmega328, not Atmega32U4)?
Have you seen any long-range (class 1?) BT modules with breakout boards available at reasonable cost? I need the 100m/through-walls range for the project I have in mind. (Don't worry, I would be building a weather station or remote Chicken-house lights controller, not a bomb!)