SIM800: SMS reading and deleting support#80
Open
tonyputi wants to merge 1 commit intovshymanskyy:masterfrom
sallemi-iot:features/sms
Open
SIM800: SMS reading and deleting support#80tonyputi wants to merge 1 commit intovshymanskyy:masterfrom sallemi-iot:features/sms
tonyputi wants to merge 1 commit intovshymanskyy:masterfrom
sallemi-iot:features/sms
Conversation
Owner
|
Thank you! that's really a valuable addition. I'll test this out and try to integrate it. |
Author
|
your welcome! I'll be here if someone need some help.
2017-09-17 21:10 GMT+02:00 Volodymyr Shymanskyy <notifications@github.com>:
… Thank you! that's really valuable addition. I'll test this out and try to
integrate it.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#80 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AH5hEdx6AbeZDAl5aiQl4VHQiSSJJ-RRks5sjW6vgaJpZM4PaLwR>
.
--
*Nomad NT*
Filippo Sallemi
Technical Director
Highland CRT FL 3
Triq Salvu Busuttil
San Gwann SGN1073 MT
mail: info@nomadnt.com
|
|
+1 |
Owner
|
Sorry, I've been quite busy - I'll try to find some time for reviewing this soon. |
aplikatika
reviewed
Nov 13, 2017
| sendAT(GF("+CMGF=1")); | ||
| if(waitResponse() != 1) return false; | ||
|
|
||
| sendAT(GF("CMGD="), i); |
aplikatika
reviewed
Nov 13, 2017
| sendAT(GF("+CMGF=1")); | ||
| if(waitResponse() != 1) return false; | ||
| sendAT(GF("+CSDH=1")); | ||
| if(waitResponse() != 1) return false; |
There was a problem hiding this comment.
Better do "+CMGF=1" and "+CSDH=1" on init() instead of everytime and each sms function.
aplikatika
reviewed
Nov 13, 2017
| if(waitResponse(GF(GSM_NL "+CMGR:"))) { | ||
| streamSkipUntil('\n'); | ||
| msg = stream.readStringUntil('\n'); | ||
| return true; |
There was a problem hiding this comment.
Need to wait for OK.
return waitResponse() == 1;
aplikatika
reviewed
Nov 13, 2017
| if(waitResponse() != 1) return false; | ||
|
|
||
| sendAT(GF("+CMGR="), i); | ||
| if(waitResponse(GF(GSM_NL "+CMGR:"))) { |
There was a problem hiding this comment.
if (waitResponse(GF(GSM_NL "+CMGR:"), GFP(GSM_OK), GFP(GSM_ERROR)) == 1) {
|
@vshymanskyy have you tested this ? :) |
| sendAT(GF("+CMGR="), i); | ||
| if(waitResponse(GF(GSM_NL "+CMGR:"))) { | ||
| streamSkipUntil('\n'); | ||
| msg = stream.readStringUntil('\n'); |
There was a problem hiding this comment.
Unfortunately, if the message has line breaks, stream.readStringUntil('\n'); will skip the rest of the message.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.