Hi,
I'm using Sim7600 and trying to connect to my tcp server, hold connection to send messages back and forth.
This is a part of my code:
while (1) {
while (myserial.available()) {
Serial.write(myserial.read());
}
myserial.println("AT+CIPSEND=0,4");
delay(3500);
myserial.println("a ok");
delay(5000);
while (myserial.available()) {
Serial.write(myserial.read());//if Serial received data, output it via mySerial.
}
}
The problem is it only works at the first loop. The message is only send once. However, when I use serial monitor to send command. I can send AT+CIPSEND as many as I want.
Hope you guys can help me find out what's wrong.