Electrical – Teensy 3.2 receives garbage values from HM-11 BLE module

arduinobaudratebluetoothbluetooth low energyteensy

Recently purchased an Hm-11 BLE module, and connected it to a Teensy 3.2.

I can see the BLE module (AnyFlite) on my phone using the MSMBle app.

The following code was used to initialize it:

#include <SoftwareSerial.h>
SoftwareSerial mySerial(7, 8); // RX, TX
void setup()  
  // Open serial communications and wait for port to open:
  while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only
  Serial.println("Goodnight moon!");
  // set the data rate for the SoftwareSerial port
  mySerial.println("Hello, world?");
void loop() // run over and over
  if (mySerial.available()) {
  if (Serial.available())

When opening the Serial monitor, I see the "Good Morning" text, however when sending AT commands there is no response. There is nothing received on the phone app either. (when connecting all I see is received text: 00

Upon sending commands from my phone to the module, I see garbage values in the serial monitor.

My understanding is that this is caused by a baud rate mismatch.. I have cycled through all the Baud rates and still face the same issue.

I checked the voltage between ground and vcc of the module and it is at 3.3v, which is what is required.

Exhausted all troubleshooting options.


Changed to the following code when I was told about UARTS:

#define HWSERIAL Serial3

void setup() {

void loop() {
        int incomingByte;

  if (Serial.available() > 0) {
    incomingByte = Serial.read();
    Serial.print("USB received: ");
    Serial.println(incomingByte, DEC);
                HWSERIAL.print("USB received:");
                HWSERIAL.println(incomingByte, DEC);
  if (HWSERIAL.available() > 0) {
    incomingByte = HWSERIAL.read();
    Serial.print("UART received: ");
    Serial.println(incomingByte, DEC);
                HWSERIAL.print("UART received:");
                HWSERIAL.println(incomingByte, DEC);

When I send an AT command from the Serial Monitor, I get the following:

USB received: 65
USB received: 10

When I send a command from my phone (in this case AT+ADDR?), I get the following:

UART received: 12
ÿUART received: 8
ÿUART received: 13

Still, garbage is being output.

Best Answer

Bad Soldering was the culprit.