我想问一下SIM800L EVB模块如何使用Arduino UNO R3 DIP/SMD CH340发送消息。我改变引脚tx/rx从2,3反之亦然,7,8结果要么不显示任何东西或任何文本,串行监视器只是显示从SIM800L EVB模块没有响应。请给我一点启发。谢谢
这两种情况的原理图如下:
SIM800L EVB:

R3 DIP/SMD CH340:

在命令处不显示任何/任意文本:

来自这里的代码我修改了引脚如下所示
#include "SoftwareSerial.h"
SoftwareSerial SMS_Gateway(0, 1); // Rx | Tx
char tempChar = "";
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
Serial.println("Testing the SIM800 Module");
SMS_Gateway.begin(115200);
for (int i = 0; i < 10; i++) {
Serial.print("=====");
delay(500);
}
Serial.println();
Serial.println("Starting Connection");
}
void loop() {
// put your main code here, to run repeatedly:
if (SMS_Gateway.available()) {
tempChar = SMS_Gateway.read();
Serial.write(tempChar);
}
if (Serial.available()) {
tempChar = Serial.read();
SMS_Gateway.write(tempChar);
}
}发布于 2018-06-21 08:32:32
从您的图像中,我看到您将Arduino Rx连接到SIM800 Rx,对于Tx则是相同的,但是颜色很难看到。您需要将Arduino Rx连接到Sim800 Tx,将Arduino Tx连接到Sim800 Rx。这意味着Arduino接收到命令发送(Tx) (由SIM800接收Rx),而visa相反。
此外,连接您的Arduino Gnd和SIM800 Gnd,除非你确信他们通过电源共享他们的土地。
SIM800自动匹配波德率,所以请继续发送AT命令,直到得到OK返回为止。
发布于 2022-10-13 07:11:14
试着把你的波德率改为9600
https://stackoverflow.com/questions/50961118
复制相似问题