TinyGSM icon indicating copy to clipboard operation
TinyGSM copied to clipboard

GSMServer possibility

Open pierreverbakel opened this issue 4 years ago • 8 comments

I have been using the TinyGSM library successfully with the SIM800C on a ESP32 using MQTT and HTTP-Client GETs (From Device to Internet). Now I want to use the Device itself as a HTTP-Server. So my device can be accessed remotely for configuration using the Web-Interface I created, which is working fine on WiFi.

In the example for the GSM Library that comes standard with Arduino written by Tom Igoe there is a object that can be created to setup a server:

GSMServer server(80); // port 80 (http default)

And then in loop()-function:

GSMClient client = server.available();
if (client) {
  while (client.connected()) {
    if (client.available()) {
      Serial.println("Receiving request!");
      bool sendResponse = false;
      while (char c = client.read()) {
        if (c == '\n') {
          sendResponse = true;
        }
      }
    }
  }
}

My question, how can I accomplish this within TinyGSM, since I do not find an example for that.

Thanks for clarification, also when you know that this is not possible. Which would surprise me since it seems like an obvious wannahave to me. Or would I have to use another GSM-library for that in parallel to Tiny-GSM?

Thanks in advance for clarification and help!

pierreverbakel avatar Nov 05 '20 14:11 pierreverbakel

Conseguiu informações? Pode compartilhar?

mabrubombas avatar Oct 02 '22 15:10 mabrubombas

Hello, No I did not get any feedback on this question yet. So at this point I cannot tell you about a solution !

pierreverbakel avatar Oct 03 '22 11:10 pierreverbakel

Any answer on this?

gotnull avatar Jan 13 '23 07:01 gotnull

any update?

roysG avatar Aug 29 '23 18:08 roysG

Anyone here about this?

bill210kouk avatar Jan 14 '24 22:01 bill210kouk

I haven't heard anything about it since the original post.

gotnull avatar Jan 14 '24 22:01 gotnull

Any other work arounnd? How can coexists timygsm and have server functionallities?

bill210kouk avatar Jan 14 '24 22:01 bill210kouk

Any other work arounnd? How can coexists timygsm and have server functionallities?

Have you tried something like this? https://github.com/vshymanskyy/TinyGSM/issues/514

gotnull avatar Jan 14 '24 22:01 gotnull