Skip to content
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

SIM800 CMUX #2

Open
Arto1994 opened this issue May 22, 2021 · 8 comments
Open

SIM800 CMUX #2

Arto1994 opened this issue May 22, 2021 · 8 comments

Comments

@Arto1994
Copy link

Hello everyone , I was testing the ppp from the original ESP IDF example and it works for SIM800L , but when I try to test the CMUX with this repository it didn't work.I get the same errors in the logs refered in the .md , due to modem initialization (+RDY , CPIN READY , etc).The commands AT like a RSSI , and the other works , but the ppp never get and IP :( . I want to know if this was tested for sim800L.

PD: My IDF is 4.2.1

Thanks in advance !

@olliiiver
Copy link
Owner

Hi. I only have one SIM7600 modem around here.

Have you tried to enable debug?

Are there any CMUX frames coming from the modem (see esp_dte_handle_cmux_frame in esp_modem.c)?

@Arto1994
Copy link
Author

Thanks for the reply .Yes , I can see it detects some CMUX frames , but I think something is corrupting the ppp part.Do you know how to select the correct AT command reference version , there is a lot of versions for SIM800.Today I'm going to do more testing and show the logs.

@Arto1994
Copy link
Author

This is what the console show
image

@olliiiver
Copy link
Owner

Hi, looks like the response from the modem is somehow different.

... Unknow line received: cmux ...

@Artiom9
Copy link

Artiom9 commented Apr 4, 2022

@Arto1994 Hello, did you manage to solve this problem? I'm also prone to this problem and don't understand how to solve it. Thanks for the answer!

@Artiom9
Copy link

Artiom9 commented Apr 5, 2022

Hello, @olliiiver! For my project, I need to run the SIM868 modem in CMUX mode to transmit data and read GNSS at the same time. I'm facing the same problem as the @Arto1994 but can't figure out what the problem is. Judging by the official documentation (I'll attach it to the comment), everything is working more or less normally (section 4.1). As far as I understood, "unknown strings" should come after the TE request, but they come by themselves. I do not know how critical this is, but it seems that the channels do not collapse because of this, but then the PPP connection is not established due to an incomprehensible reason. If you could help me figure out what's wrong, I would be very grateful! Thanks!
Here's a screenshot of what's going on:
Снимок экрана 2022-04-05 121135
Снимок экрана 2022-04-05 121103

SIM800 Series_Multiplexer_Application Note_V1.04.pdf

@olliiiver
Copy link
Owner

hi @Artiom9. Can't say about the errors you get. Seems SIM868 works differently.

Have you tried the official repo? Looks like it supports CMUX also now:

https://github.com/espressif/esp-protocols/blob/master/components/esp_modem/src/esp_modem_cmux.cpp

@Artiom9
Copy link

Artiom9 commented Apr 12, 2022

Hello, @olliiiver. I found a solution, I apologize for not writing a solution. I still don't understand why it works this way, but you need to replace the line in the file "sim800.c:318" DCE_CHECK(dte->send_cmd(dte, "ATD*99#\r", MODEM_COMMAND_TIMEOUT_MODE_CHANGE) == ESP_OK, "send command failed", err); to DCE_CHECK(dte->send_cmd(dte, "ATD*99***1#\r", MODEM_COMMAND_TIMEOUT_MODE_CHANGE) == ESP_OK, "send command failed", err); But this only fixes the connection to GSM, and when setting up CMUX, "Unknow line received" remain, because the SIM800 sends additional messages, but they do not affect anything, so they can be ignored.
As for the official repository, I initially tried to do it on it, but nothing worked for me, and I already found your repository and tried to do it on it.
At the moment I have solved the problem with the official repository and will prepare a commit to fix the problem)
Thank you for your answer!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants