-
Notifications
You must be signed in to change notification settings - Fork 726
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[M590] LIbrary not working on ESP32 #91
Comments
The problem seems to be related to the implementation of HardwareSerial for ESP32. With the most recent git state, things seems to be better (see also espressif/arduino-esp32#665) EDIT: Even though, some more things seem to work (i.e. sending commands from my own code), the library still does not work - it seems as if it does not receive the answers from the module. Both modules, connected to an ESP8266 with SoftwareSerial --> Working without any problems... So it seems to have something to do with the ESP32's Serial implementation... |
I'll re-check this once I get some spare time. Thanks! |
Looks like my issue was unrelated to this maybe, I am using a Adafruit Huzzah 32. I switched to using UART1 (2nd one). I had to pass the pin numbers and "false" to the begin method call. This works fine now, hope this helps someone else.
Jamie. |
@papawattu I'm facing a similar issue, and trying to understand your solution. If you switched to UART1, does that mean you can no longer use the USB port on your board to monitor the program? Thanks! |
@papawattu , @vshymanskyy , I can confirm that TinyGSM is working flawlessly on my ESP32. and in setup: Edit: I have uploaded my working code here: |
I have a problem with gprs connection in my ESP32. Don't find the modem. WIth AT command's its working. Can someone help me? @abhaysbharadwaj, how did you use? |
I can't connect SIM800L EVB version to my Espressif ESP32-WROOM-32 developer kit. I'm using UART 2 connection (SIM800L TX -> ESP32 TX2, SIM800L RX -> ESP32 RX2, GND is same picture here). I think there is no problem with power supply, I can call to SIM800L, it blinks every 3sec so it's connected to network. I'm using code as was described above:
There is no response from SIM800L. Am I doing something wrong, or is EVB version somehow different from "classic" red SIM800l? |
@vitzaoral |
Hey guys, Have a problem with my ESP32. Using DevKitC V4 with Wrower. Trying to hook up SIM800L. My unit is connected, i can type AT commands through USB-TTL. Light flashes as its connected to the network. My device is defined as serial2 on pins 16, 17. When i start my ESP it cant initialize modem. Tried example sketeches of both TinyGSM and FONA library. Works normally directly through serial on arduino (i short RST to GND) so i know the SIM module is working. #define SerialMon Serial my void setupGSM; My serial monitor output; 0 0 This is my code. Tried different baud rates, inverting RX/TX pins, different UART, ... nothing works. I'm just using the sim800 to trigger relays and send temp and humidity status. I am powering my SIM800L from a outer power supply with 3A max. My wiring is GND->GND; TX->17; RX->16; GND->GND. Tried also rreversing RX/TX. I'm using V2 of the SIM800 (EVB version). I'm a bit depressed allready :) P.S also tried with; |
Was this issue resolved? I'm having the same issue and using UART1 does not solve it. |
@CcKefa @sass00 took me some time to get this working, I'll paste the important parts for reference maybe it helps you as well. I had to instantiate my serial connection to the LTE module as a Also, my LTE module uses 115200 baud rate, so I have passed that in as well, but if you are unclear what baud rate your LTE module uses then use this AT_Debug sketch to try and find that first
Another detail is that I am supplying power to my LTE module via micro usb plugged in to the wall, so the only connection from my ESP32 to the LTE module is 1 GND connection and the TX/RX. I'm not sure about your ESP32 units, but mine does not output 5V power so I had to supply it elsewhere. |
has anyone used a7672e?is there an issue with its connection to server for both tinyGsm webClient and mqttClient examples?my connections:ES32--------->A7672EIMAGEMRX---------->G17 below is my mqttClient code`/**************************************************************
**************************************************************/ // Select your modem: // Set serial for debug console (to the Serial Monitor, default speed 115200) #include <HardwareSerial.h> HardwareSerial SerialAT(2); // Define the DTR and RI pins used for hardware flow control // See all AT commands, if wanted // Define the serial console for debug prints, if needed // Range to attempt to autobaud // Add a reception delay, if needed. // Define how you're planning to connect to the internet. // set GSM PIN, if any // Your GPRS credentials, if any // Your WiFi connection credentials, if applicable // MQTT details const char* topicLed = "GsmClientTest/led"; #include <TinyGsmClient.h> // Just in case someone defined the wrong thing.. #ifdef DUMP_AT_COMMANDS #define LED_PIN 2 uint32_t lastReconnectAttempt = 0; void mqttCallback(char* topic, byte* payload, unsigned int len) { // Only proceed if incoming message's topic matches boolean mqttConnect() { // Connect to MQTT Broker // Or, if you want to authenticate MQTT: if (status == false) { void setup() { // Set the DTR and RI pins as outputs and initialize them to HIGH // Set the DTR pin LOW to signal the SIM7672S module to start sending data SerialAT.begin(115200, SERIAL_8N1, 16, 17); delay(10000); // Set console baud rate pinMode(LED_PIN, OUTPUT); // !!!!!!!!!!! SerialMon.println("Wait..."); // Set GSM module baud rate // Restart takes quite some time String modemInfo = modem.getModemInfo(); #if TINY_GSM_USE_GPRS #if TINY_GSM_USE_WIFI #if TINY_GSM_USE_GPRS && defined TINY_GSM_MODEM_XBEE SerialMon.print("Waiting for network..."); if (modem.isNetworkConnected()) { SerialMon.println("Network connected"); } if (modem.isGprsConnected()) { SerialMon.println("GPRS connected"); } // MQTT Broker setup void loop() { #if TINY_GSM_USE_GPRS if (!mqtt.connected()) { mqtt.loop(); the output is:Wait... Manufacturer: INCORPORATED ERROR OK PB DONE +IP ERRO best regards |
As already described in issue #81, using HardwareSerial on ESP32 does not work with the library.
If transferring the data "manually" in a simple sketch, everything works fine.
With the TinyGSM library, a lot of random characters show up during the communication, rendering all results unusable.
Code used:
The text was updated successfully, but these errors were encountered: