0
\$\begingroup\$

I have an LTE module (quectel bg95) that gets AT commands from a host esp32 (esp32-wroom-32ue) via a UART connection. And in the ESP documentation AT manual to send AT commands I should connect: RXD, TXD, CTS, RTS. But in the module's hardware integration manual it shows many more connections shown below. Which lines do I need to connect to send AT commands?

Edit... Datasheet info that may help decide which connections are necessary. The the only other info in the datasheet I could find regarding the main UART connection (for AT commands) is as follows:

The module provides three UART interfaces: the main UART, debug UART and the GNSS UART interfaces. The main UART interface supports 9600, 19200, 38400, 57600, 115200, 230400, 460800 and 921600 bps baud rates, and the default is 115200 bps. It is used for data transmission and AT command communication, and supports RTS and CTS hardware flow control. The default frame format is 8N1 (8 data bits, no parity, 1 stop bit). The debug UART interface supports a fixed baud rate of 115200 bps, and is used for software debugging and log output. The GNSS UART interface supports 115200 bps baud rate by default, and is used for GNSS data and NMEA sentences output.

So the datasheet specifically mentions functions of RXD, TXD, CTS, RTS but I am not seeing anything for DTR, DCD, or RI. What are these? datasheet

description diagram

\$\endgroup\$
8
  • 1
    \$\begingroup\$ The linked document for the esp32 at commands has nothing to do with sending at commands to the bg95. You’ll need specific code on the esp32 to talk to the bg95. Apart from rxd and txd, the other signals go to esp32 port pins. There’s also control signals to power up/down the bg95. \$\endgroup\$
    – Kartman
    Commented Apr 20, 2021 at 22:09
  • \$\begingroup\$ @Kartman the BG95 has an AT command manual. I guess I'll be using that. \$\endgroup\$
    – Feynman137
    Commented Apr 20, 2021 at 23:18
  • 1
    \$\begingroup\$ Ah, not all SBCs nd MCUs UART cct has extra signals eg CTS, RTS (Clear To Send, Request To Send). For example my Rpi has no such signals. So the trick, or to cheat the other side, is to short CTS to RTS. However, this is for low speed cases, because data might loss at high speed, because the I/O are not synchronized. And we can also build RTS, CTS etc by software bit banging. \$\endgroup\$
    – tlfong01
    Commented Apr 21, 2021 at 0:55
  • 1
    \$\begingroup\$ it also includes DTR/DSR which may be used to just show the cable is connected and RTS/CTS for flow control. If both ends use TXD & CTS as outputs, then you need to make a crossover cable. You can make it bare bones but sometimes you might want to use high speed with flow control and parity for integrity so that you never get a buffer overflow or occasional glitch causing errors, which implies you read status with data i.e. error detection and retry else alert user \$\endgroup\$ Commented Apr 21, 2021 at 1:16
  • 1
    \$\begingroup\$ Normally a 16 byte buffer almost filled disables CTS until room to add more bytes., but I don’t know what each has. \$\endgroup\$ Commented Apr 21, 2021 at 2:25

2 Answers 2

3
+50
\$\begingroup\$

CASE 1

Send and receive data and SMS.

Use TXD and RXD


CASE 2

Send and receive data and SMS + Microcontroller goes to sleep and needs to be awaken up by the LTE module.

Use TXD, RXD, CTS

The CTS signal goes down when and SMS arrived or when a phone call is arriving. It's called network PAGING.


CASE 3

Send and receive data and SMS + hardware flow control during LTE/3G/GPRS/2G data transmissions.

Use TXD, RXD, RTS, CTS


CASE 4

Send and receive data and SMS + simultaneous phone calls.

Use TXD, RXD of the first UART (data + SMS)

Use TXD, RXD of the second UART (phone call answer and hang-up)

The second UART is needed if you want to send or receive SMS messages during a phone call.


CASE 5

Send and receive data and SMS + simultaneous phone calls.

Use TXD, RXD of the first UART (data + SMS + phone call answer and hang-up)

Write a piece of C code that implements the client side of the 3GPP mux protocol.

This is tough if you are a newbie.

The 3GPP mux protocol will allow you, using just one UART interface, to send and receive SMS messages while a phone call is in progress, which is usually not possible with just one UART.


DTR and DSR are supported by the LTE module.

They are useful only if you want to connect your LTE module to a PC that runs a very old telephony software.


I've never used the RING signal because I always waited for the +CLIP unsolicited indication, arriving from the UART, that contained the actual caller's ID.


I've never used the DCD signal because I always waited for the +CONNECT unsolicited indication, arriving from the UART, that contained the connection speed expressed in bits per second.

\$\endgroup\$
1
\$\begingroup\$

Depends on your bit mask or setup. Normally DTR (& DSR) , RI and DCD are used only for modems and DTR is just pulled high in HW unless you want to detect a cable connected.

Flow control may be in s/w Xon/off or H/W using RTS and CTS. Multiple inputs need to be MUX’d otherwise contention might occur. Outputs are limited by cable capacitance, and Bit rate x cable length product.

\$\endgroup\$
5
  • \$\begingroup\$ "Normally DTR (& DSR) , RI and DCD are used only for modems" this is my set-up correct? I am using BG95 as an LTE module \$\endgroup\$
    – Feynman137
    Commented Apr 20, 2021 at 23:17
  • 1
    \$\begingroup\$ The LTE module is a modem! Read the datasheet to understand what those control lines are used for and decide if you need to use them. \$\endgroup\$
    – Kartman
    Commented Apr 21, 2021 at 0:31
  • \$\begingroup\$ @Kartman see edit, I added some info from datasheet that may help. It doesn't specifically say what connections are required for the main UART connection though. \$\endgroup\$
    – Feynman137
    Commented Apr 21, 2021 at 0:54
  • 1
    \$\begingroup\$ No link to the datasheet? Or do we need a login at Quectel to get one? If you’re planning on doing a pcb first, I’d suggest otherwise. Get yourself an existing board with the module and sort out the low level details first. The bg95 module is tricky to solder and near impossible to rework - i have a few that were tried. \$\endgroup\$
    – Kartman
    Commented Apr 21, 2021 at 6:14
  • \$\begingroup\$ @Kartman my apologies. I included a link to the hardware integration sheet. Quectel protects their datasheets so it is a little more difficult than usual. You are right about these things being difficult to solder though. I am having to buy a reflow oven just to work with them. \$\endgroup\$
    – Feynman137
    Commented Apr 21, 2021 at 13:47

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