I want to send a simple AT-Command like: AT\r\n
from the ESP32 to the Fanstel BC805M (nRF52805M) breakout board. My goal is to get an answer.
Problem: The Esp32 does not get an answer from the BC805M.
The ESP32 is connected by usb cable to my Mac.
The ESP32 connects to the BC805M by five cables -> 3V3->VDD, GND->GND, Rx->Tx, Tx->Rx, GPIO32(high)->GPIO04(P004). Rx and Tx from ESP32 are Serial2 (not the Serial0 of the programmer). The P004 pin from BC805M is set to high to enable "command-mode".
The BC805M came already preloaded with The AT commands code.
The ESP32 is flashed by a simple Serial2 write/read arduino code:
#include <HardwareSerial.h>
#define RXD2 16
#define TXD2 17
#define CMD_MODE 32
void setup() {
Serial.begin(115200);
Serial2.begin(115200, SERIAL_8N1, RXD2, TXD2);
pinMode(CMD_MODE, OUTPUT);
digitalWrite(CMD_MODE, HIGH);
delay(1000);
Serial.println("start");
}
void loop() {
Serial2.write("AT\r\n");
delay(500);
if(Serial2.available()){
Serial.write(Serial2.read());
}
}
On Monitor, I received nothing: Terminal Output
I connected the two ESP32 Rx and Tx Serial2 Pins with each other and the monitor prints AT AT AT ... (so this works)
I connected the ESP32 with the BC805M not by crossing Tx and Rx but like: Rx->Rx, Tx->Tx; I received the message
BlueNor 200622 started
on my monitor. This means I read the values of the Rx pin of the BC805M and wrote them to my monitor. Shouldn't this message be sent on on the Tx pin of the BC805M?
I connected to the BC805M per Android App, which connects to it via Bluetooth Low Energy. I sent commands from the app to the BC805M. But I got no response. I could read the commands I sent on the Rx Pin of the BC805M.
I connected solely the BC805M per usb to my mac and ran Arduino-IDE's monitor, the monitor prints absolutely nothing and writing AT-Commands also results into nothing.
The Fanstel support just wrote me that the BC805M Evaluation Board is NOT preloaded with the AT-Command firmware.
Only the BC805M module has it preloaded.
That explains why the AT-Commands did not work.