4G modem project

Hi,
I'm thinking about doing a DIY 4G modem. I already have a module sim4G, esp32, arduino uno...
how can I do that? help me plsss
(sorry for my bad english =)))))))))))

Hello linalnal

Welcome to the world's best Arduino forum ever.

Follow the example code that comes with the library or
run some tutorials for the hardware selected.
If you are happy with the results of the tutorials you can merge these to your project.

Have a nice day and enjoy coding in C++.

try this code which I used to test a SIM900 with an ESP32 usinf srial hardware port

text entered on keyboard is transmitted to SIM900
characters from SIM900 appear on serial monitor

// // SIM900 ESP32 test using Serial2 (pins 16 Rx  and 17 Tx)

// connect so
// SIM900 TXD to ESP32 pin 16 Rx
// SIM900 RXD to ESP32 pin 17 tx

// AT+CGMI  returns the manufacturer's name
// AT+CGMM returns the MODEM model number
// AT+CGMR returns details of the software and model revision level
// AT+CGSN returns the MODEM's serial number

#include <Arduino.h>

// ESP32 example using HardwareSerial library to access Serial port 2 (pins 16 and 17)
// from https://programming.vip/docs/esp32-use-of-hardwareserial-library.html

#define SERIAL_BAUD 9600//115200

//HardwareSerial Serial2(2);//Serial port 2

int distance = 0;

void setup() {
  //Initialize serial port 0
  Serial.begin(115200);
  //Initialize serial port 2
  Serial2.begin(SERIAL_BAUD, SERIAL_8N1);
  Serial.println("\nSIM900 to ESP32 Serial port 2 test pins 16 Rx  and 17 Tx");
  Serial.println("\nSerial monitor line ending BOTH NL & CR");
}

void loop() {
  while (Serial2.available() > 0) {
    uint8_t byteFromSerial = Serial2.read();
    Serial.write(byteFromSerial);
  }
  while (Serial.available() > 0) {
    uint8_t byteFromSerial1 = Serial.read();
    Serial2.write(byteFromSerial1);
  }
}

serial monitor output in response to AT commands

RDY
+CPIN: NOT INSERTED

+CFUN: 1
AT
OK
AT+CGMI
SIMCOM_Ltd
OK
AT+CGMM
SIMCOM_SIM900
OK
AT+CGMR
Revision:1137B06SIM900M64_ST_ENHANCE
OK

at+csq
+CSQ: 11,0
OK
at+creg?
+CREG: 0,1
OK
at+cops?
+COPS: 0,0,"O2 - UK"
OK

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.