ESP32 with SIMCOM A7670C GSM Module – Not receiving AT command responses

Hello everyone,

I am trying to interface an ESP32 with a SIMCOM A7670C GSM/4G module, but I am not receiving proper responses to AT commands. Sometimes I only see ATREADY: 1, but after that no reply comes. In Some time It's Showing Continuously ATREADY: 1 Response.

Here are my details:
Hardware Setup: -

  • GSM Module: SIMCOM A7670C (LTE module, version E)
  • MCU: ESP32 Devkit
  • Power Supply:
  • DC-DC Buck Converter set to 4.0V output
  • Multimeter readings: 1.6A current consumption when module is ON
  • Voltage remains stable at ~4.0V during operation
  • Connections:
  • VCC → 4.0V from buck converter
  • GND → Common ground with ESP32
  • TX (A7670) → RX (GPIO16 of ESP32)
  • RX (A7670) → TX (GPIO17 of ESP32)
  • PEN → 3.3V
  • NETLIGHT → LED (blinks continuously)
  • PWRKEY → GPIO4 of ESP32 (pulled LOW to turn ON)

Software Setup: -
Arduino IDE, Code 1 Serial configured at 115200 baud:

#include <SoftwareSerial.h>

SoftwareSerial sim(21,22);

void setup() {
  Serial.begin(115200);                          // USB Serial Monitor

  Serial.println("=== GSM AT Command Test Start ===");
  delay(2000);

  sim.println("AT");          // Basic Test
  delay(1000);
  sim.println("ATI");         // Module Info
  delay(1000);
  sim.println("AT+CPIN?");    // SIM Status
  delay(1000);
  sim.println("AT+CREG?");    // Network Status
}

void loop() {
  if (sim.available()) {
    Serial.write(sim.read());
  }
  if (Serial.available()) {
    sim.write(Serial.read());
  }
}

Arduino IDE, Code 2 Serial configured at 115200 baud:

#include <HardwareSerial.h>

HardwareSerial modem(1);

#define PWRKEY 4

void setup() {
  // put your setup code here, to run once:
  pinMode(PWRKEY, OUTPUT);
  digitalWrite(PWRKEY, HIGH);
  delay(100);
  digitalWrite(PWRKEY, LOW);
  delay(1500);
  digitalWrite(PWRKEY, HIGH);

  Serial.begin(115200);
  modem.begin(115200, SERIAL_8N1, 21,22);
  Serial.print("Sending AT... ");
  delay(3000); 
  modem.println("AT");

}

void loop() {
  // put your main code here, to run repeatedly:
  if(modem.available()){
    Serial.write(modem.read());
  }
  if(Serial.available()){
    modem.write(Serial.read());
  }

}

Arduino IDE, Code 3 Manual AT Command Sending From Serial Monitor Serial configured at 115200 baud:


#include <HardwareSerial.h>
HardwareSerial testSerial(1);

void setup() {
  Serial.begin(115200);
  testSerial.begin(115200, SERIAL_8N1, 21,22); // RX=16, TX=17
  Serial.println("Type something below:");
}

void loop() {
  while (Serial.available()) {
    char c = Serial.read();
    testSerial.write(c);   // USB → TX
  }
  while (testSerial.available()) {
    char c = testSerial.read();
    Serial.write(c);       // RX → USB
  }
}

I am Trying These 3 Code One By One To Check Module is Working or not

Problem Observed

  • When powered, the NETLIGHT LED keeps blinking continuously (does not stabilize).
  • Sometimes I see ATREADY: 1 message, but when I send AT, no OK response comes.
  • Without breadboard, the module powers ON once, then LED stops blinking and never comes back ON.
  • With breadboard + buck converter, LED blinks continuously but still no AT responses.
  • Power seems enough (4.0V, 1.6A measured).

My Questions

  • Any Power Supply Issue the Module Is Continue Reset or not Connecting to Network.
  • Is my wiring correct (specially PWRKEY and PEN pins)?
  • Do I need a different sequence to power ON A7670?
  • Why is the module only sending ATREADY: 1 but not responding to AT commands?
  • Is my buck converter sufficient, or should I use a Li-Ion battery for better current stability?

Any help, guidance, or working example code for ESP32 + A7670 would be greatly appreciated :folded_hands:

:high_voltage: Thanks in advance!

Good day sir, Please I am facing very similar challange, I dont know if you have found the solution, I will really appreciate your sir :folded_hands:

can you enter AT commands using a simple program such as

// ESP32  Serial1 test - for loopback test connect pins RXD1 and TXD1

#define RXD1 16 // can map Serial1 and Serial2 to many ESP32 GPIO pins
#define TXD1 17 // check pin usage https://randomnerdtutorials.com/esp32-pinout-reference-gpios/

// for RS232 shield connect
// ESP32 RXD1 to TTL/RS232 Rx
// ESP32 TXD1 to TTL/RS232 Tx
// connect GND pins together and VCC to 3.3V on ESP32 5V on UNO ect
// for loopback test connect 9-pin D_type connector pins 2 Tx to 3 Rx (pin 5 is GND)

void setup() {
  // initialize both serial ports:
  Serial.begin(115200);
  Serial1.begin(115200, SERIAL_8N1, RXD1, TXD1);
  Serial.printf("\n\nESP32 serial1  test RXD1 pin %d TXD1 pin %d\n", RXD1, TXD1);
  Serial.printf(" loopback test connect pin %d to pin %d\n", RXD1, TXD1);
  Serial.printf("RS232: ESP32 pin %d RXD1 to TTL/RS232 Rx and pin %d TXD1 to TTL/RS232 Tx\n", RXD1, TXD1);
  Serial.printf("RS232 - loopback connect 9-pin D-type pin 2 Tx to pin 3 Rx\n");
}

void loop() {
  // read from Serial1, send to Serial
  if (Serial1.available()) {
    int inByte = Serial1.read();
    Serial.write(inByte);
  }
  // read from Serial, send to Serial1
  if (Serial.available()) {
    int inByte = Serial.read();
    //Serial.write(inByte);     // local echo if required
    Serial1.write(inByte);
  }
}

e.g. entering AT commands using serial monitor

*ATREADY: 1

+CPIN: SIM REMOVED
AT
OK
AT+CGMI
SIMCOM INCORPORATED
OK
AT+CGMR
+CGMR: A131B03A7670M6C
OK
AT+CGMM
A7670E-LASA
OK
AT+CSQ
+CSQ: 16,99
OK

photo

EDIT: although the above photo shows modem is powered from ESP32 VIN (5V) for AT tests for real operation an external 2amp 5V power supply is required

That does not appear correct to me.

Sorry I cannot follow your word salad for connections, posting an annotated schematic would help us help you.

Hi @kaustubh102938
In your first code it seems to forget to call a begin() method to SoftwareSerial object.

Next, let looks how the code works.
In the Setup you send some AT commands with pause after each sendings. But you do not read any response.
Finally, you begin listening the modem in the loop(). But at this moment all it's responces already gones.

@kaustubh102938 i am facing the same issue, any luck?

what specific A7670C module and ESP32 dev board do you have? give links?
how have you connected the A7670C it to the ESP32?
upload code? what did you expect it to do? what does it do?

IF you get the solution please help.