0

I run an Arduino Pro Mini on ATMega328 3.3V 8MHz, and I am unable to send data over HC-05 breakout board on this frequency, and on 5V 16Mhz, it has no issues.

The Arduino code is down below:

#include <SoftwareSerial.h>
#include <Wire.h>
SoftwareSerial BT(10, 11);
byte value;
unsigned long pmillis_bt = 0;

void setup() {
  Serial.begin(19200);
  BT.begin(9600);
}
///////////////////main///////////////////

void loop () {
  if (millis() - pmillis_bt >= 100) {
    byte Data[3];
    byte cmmd[20];
    int insize;
    char str[256];
    int i = analogRead(A0);
    value = BT.read();
    Data[0] = 'a';
    Data[1] = i / 256;
    Data[2] = i % 256;
    sprintf(str, "%d", i, Data[0], Data[1], Data[2]);
    Serial.println(str);
    if (value == 49) {
      for (int j = 0; j < 3; j++)
        BT.write(Data[j]);
      value = 0;
    }
    pmillis_bt = millis();
  }
}

2 Answers 2

1

Basically Arduino Uno Is working On 5v Voltage Level so you can Directly connect the HC-05 Bluetooth module to it using it 4 lines VCC,TX,RX,GND.

But in Pro mini 3.3 V level due to you need to Generic 3.3V To 5V 2 Channel Logic Level Converter Bi-Directional Module

using this you can easily convert the vlotage level.

if you have to make using simple component also using

SparkFun Logic Level Converter - Bi-Directional

0

You are probably using the HC-05 Module with a power regulator and levelshifter designed for use with Arduinos that typically run with 5V. What you need is the plain HC-05 as can be found on AliExpress. Those run with 3.3V but it can be tricky to use them in prototypes.

1
  • I do use the breakout board though, not the ones with the pins.
    – Jakers
    Jan 18, 2017 at 11:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.