Arduino HC-05 Bluetooth after several connections it crashes - bluetooth

So I use a Arduino Nano and a HC-05 Bluetooth module.
The problem is that after several connections made one after another the module stops connecting to the device.
The android application is not the problem because I try to connect with other applications and same problem.
I did try to add a watch dog on the arduino nano but seem that it does not crash in the loop .
Got any suggestions what I could do ?
Edit: So I've seen if I use watchdog with the original bootloader doesn't work , got other solutions how to reset or why my Bluetooth module does not allow connections after it crashes?

Related

Bluetooth Firmware Update

I have a BLE module that i'm trying to update the firmware in, but having a lot of problems connecting the recommended update software (ISupdater). All I get is 'connect failed' message. There seems to be no troubleshooting information available, so I hope that someone has run into the same issues and solved it.
For the hardware setup, I'm connecting to a PC via a USB-USART serial adapter board. I have the 3.3V, GND, reset switch, mode switch, USART connection from the RN4870 BLE module connected as per the microchip connection diagrams (https://microchipdeveloper.com/ble:rn4870-app-example-fw-upgrade). I have verified many many many times that my connections are correct.
Connection Diagram
To test the BLE connection and data transfer I have mobile devices (iOS and Android) with the recommended apps (SmartData, mBIoT). I can see the BLE broadcast in the bluetooth lists, and I can connect to it to use the apps.
For the RN4870 module, I'm able to connect to CoolTerm software to test that I'm getting communication between the terminal and a mobile device. I'm able to send and receive data on the CoolTerm terminal, and on the mobile device apps, so that suggests to me that the USART adaptor is working correctly, and so is the BLE module.
In CoolTerm, I'm able to enter the CMD mode for the RN4870 module to set and read settings of the module, so I can check and set the baudrate to the default 115200.
If I use a BM70 module (which is the same hardware as RN4870 but different firmware), i can't enter any CMD mode, or do any sort of reset. The data is still able to be sent and received, so that confirms the baud rate is correct.
When I attempt to connect to either BLE module using the ISUpdate software that is recommended in the update steps to use as the firmware updater, I'm not able to connect to the module to update the firmware. I've tried many times to get the software to connect, many different ways, without success, and it's frustrating to no end.
I've updated the MCP2200 drivers to the latest ones from the microchip website, as well as using the latest versions of the CoolTerm and ISupdater. I've also tried previous versions, but still they all have 'connect failed'
ISupdater Image
has anyone got any solutions to the issue?
PC: Windows 10, 64-bit
BLE Modules: RN4870, BM70
CoolTerm Version: v1.8.0 (build 861)
ISUpdater Version: v4.0.0.207
IS187x_102_BLEDK3v1.11_UIv1.01 for Windows 10
Mobile Apps: SmartData, LightBlue for iOS, LightBlue for Android, mBIoT
Hmm, well it turns out that the USB-USART serial adaptor (although confirmed to be working correctly) seemed to be the problem.
At first, I only had the 1 adaptor, and I had to borrow a different adaptor. After swapping this FTDI232 USB-USART Serial adaptor, the connection was made first try, and I was able to update the firmware. I have now purchased a new adaptor.
So, if you are having the same trouble, try using a different adaptor.

Arduino HC-05 Master/Slave

I am trying to be able to click a button on a tablet i have, and it sends a message to a master Arduino. The master Arduino then sends a message of to 4 slave devices, which switches on a relay. So far I have already been able to connect a HC-05 to an android and switch a relay on from that same Arduino but, now i need to expand it. I have about 10 HC-05 modules and i would like to use just them. Any help will be appreciated. I currently have pinched parts of the code from this website.
http://www.instructables.com/id/Remotely-Control-LED-using-HC-05-Bluetooth-Arduino/?ALLSTEPS
Thanks
Ben
I recommend looking into AT commands for the HC-05. They will allow you to set the connected device and send information to that specific device (which would permit the switching between slaves). I also go through basic switching with the HC-05, a relay, and an Arduino Uno on my blog.
https://engineersportal.com/blog/2017/11/15/bluetooth-home-automation-light-bulb-switch-using-an-hc-05-a-relay-and-arduino

Bluetooth SPP module SPP-C SPP-CA BK3211 chip - entering AT mode?

I have Bluetooth SPP module SPP-C / SPP-CA , it is cheap module that should work the same way as well known HC-06 / HC-05 modules.
I have got one problem, everything works, module is communicating over serial interface pairing etc... but i can not enter the AT mode to change device name pin or baud rate. Does anyone had the same problem and how to solve it ? there is a very small data published and sellers are not responding.
So I assume that someone may help with that situation. http://www.ebay.com/itm/Bluetooth-Module-UART-Serial-Interface-SPP-CA-works-with-YZXstudio-USB-Monitors-/201414967094 that's the module. it is based on Beken BK3211 chip.
It seems that nothing special is needed to enter command mode on the SPP-CA module I have.
Whenever you connect or disconnect by bluetooth, the module will print:
CONNECTED
.. serial data is transferred ..
+DISC:SUCCESS
When the module is disconnected, you can execute AT commands such as AT+BAUD just like with HC05 modules.
3 years later and I've looked everywhere for an answer to this question and finally stumbled upon the solution by fiddling away.
I am connecting via an FTDI module using Teraterm software to enter commands.
You need to power up the FTDI and BT modules by plugging into PC USB. open Teraterm and set up to see the COM port.
Now you have to momentarily connect GND to port 11 on the BT module to 'reset' the module. The module will power down and back up again and in doing so will enter AT mode and you should be able to communicate with the module.
Good luck
Old question however still relevant, I found the solution! It is pretty simple, you can use an breadboard and some jumper wires however you can also create an adapter like I did. Like explained in this document with AT-commands, you need another UART (serial connection) to program the SPP. The SPP must not connected to anything (discovery mode) to be able to program it.
You can do this, like I did, with another SPP or you can use serial programmer or an Arduino. Notice that the serial connection is 3V, so when using an Arduino you need some resistors (1K and 2K) to create a voltage divider (google it).
The schematic is pretty simple (when not using an Arduino), I designed this adapter:
You need these components to create the adapter (and maybe some wires):
Connect everything like in the schematic above (STATE and EN are not connected), insert the modules (take care of pin orientation!), insert an USB cable and connect it to some power source.
In Arduino IDE, select the com-port you want to configure and launch the Serial monitor, you can now enter AT-commands to configure the one that is not connected:
Done! That is pretty easy right? When you want to configure the other, disconnect the one that is connect and connect the other one. An overview of AT-commands can be found in the document in provided link above.
Hopes it helps ;-)

Bluetooth module(HC05) works with Arduino Uno but not with breadboard (Atmega8)

I am currently working on a project that requires communication between an android phone(galaxy s4) and an Atmega8 microprocessor. To connect these devices wirelessly I'm using an HC05 bluetooth module and to understand the connection I'm using pre-built arduino codes(turn LEDs on and off) and an android app called blueterm. This connection is established and able to transmit data when connected to the Arduino uno, but as soon as this chip is removed and connected to a standalone breadboard the connection fails. The standalone breadboard works fine and has been tested with many other projects and I have attached the breadboard connection below. The HC05 when connected to the breadboard changes the blinking pattern to notify the user it is connected but the serial connection is never made. Any help would be greatly appreciated, if any other information is needed feel free to ask.
http://postimg.org/image/itulapqxj/
Thanks,
Brett

why arduino mega with bluetooth works only when it connect to the pc

i use arduino mega 2560 and BT JY- MCU.
i connect to the BT with my android divece but the arduino not response unless it connect to the PC.
the code is really simple one -
maybe it becouse i use:
"char input = Serial.read();"
please help...
Please post your Arduino sketch code. The problem might be related to Serial.read(). Hard to tell without seeing some of the sketch code. One note is that a PC USB connection can force resets that might not happen running on batteries. This can be very important (and helpful).

Resources