-
Notifications
You must be signed in to change notification settings - Fork 3k
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
SMS: Increase timeout for send and get. Fix text SMS parsing when CRLF is contained in the text. #15477
Conversation
Please split into separate commits unrelated changes (adding new functionality vs bugfixing or similar). |
@0xc0170 Done. 3 commits now with the three different changes. |
Thanks, can you add details also to the commit messages please? Why are we increasing the timeout, updating parsing SMS? All should be answered there. |
@0xc0170 Done, can you review? |
516d0e6
to
e13a7e1
Compare
For some devices sending can be slow (as an example see SIM800, it can be up to 60s), command is being run properly but default timeout is returning an invalid error. See https://www.elecrow.com/wiki/images/2/20/SIM800_Series_AT_Command_Manual_V1.09.pdf
When SMS list is big and baudrate is not fast enough, with default timeout we can suffer from timeout error while getting a sms because method is parsing the full list and this takes long.
@0xc0170 With all these changes of splitting commits and so on it seems that I messed up at some point. I will review code and ask for approval again. |
@0xc0170 I've just fixed the build, missed variable when amending commits. I also fixed SMS test which was broken due to new list_messages implementation and new ATHandler methods. Only last commit was changed. Could you please review again? |
CI started |
Jenkins CI Test : ❌ FAILEDBuild Number: 1 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
…contained in SMS payload text When parsing SMS, it can happen that we receive CRLF in the SMS payload (happened to me when receiving provider texts). As an example, we can receive: """ Hello <CR><LF> World! """ With previous implementation, second consume_to_stop_tag was stopping in <CR><LF> and rest of the code was failing for obvious reasons. With this commit we consume the full payload as bytes.
Fixed astyle issue. Not sure what's the problem with |
CI restarted I'll check the logs once done. There are some devices that are offline unfortunately (status fail reported) |
Jenkins CI Test : ❌ FAILEDBuild Number: 2 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
@0xc0170 Please offer more details so I can fix. |
Summary of changes
With the current implementation, second
consume_to_stop_tag
was stopping in<CR><LF>
and rest of the code was failing for obvious reasons. With this patch we consume the full payload as bytes.Commit
Impact of changes
Affects all cellular targets.
Migration actions required
Documentation
None.
Pull request type
Test results
Further tests would be desirable to cover this case.
Reviewers