-
Notifications
You must be signed in to change notification settings - Fork 510
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
[Boron LTE] Fix external SIM getting stuck in init #2263
Conversation
hal/src/electron/no_ind.diff
Outdated
diff --git hal/src/electron/modem/mdm_hal.cpp hal/src/electron/modem/mdm_hal.cpp | ||
index cfb7959ed..f7cb88c91 100644 | ||
--- hal/src/electron/modem/mdm_hal.cpp | ||
+++ hal/src/electron/modem/mdm_hal.cpp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
extra file :D
2ebeaca
to
9fc7409
Compare
break; | ||
} | ||
} while (++imsiCount < 2); | ||
int ret = checkImsiForNetConf(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: CHECK(checkImsiForNetConf())
@@ -938,6 +940,30 @@ int SaraNcpClient::waitReady(bool powerOn) { | |||
return SYSTEM_ERROR_NONE; | |||
} | |||
|
|||
int SaraNcpClient::checkImsiForNetConf() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Probably the opposite? netconf for IMSI?
const int r = CHECK_PARSER(resp.readResult()); | ||
CHECK_TRUE(r == AtResponse::OK, SYSTEM_ERROR_AT_NOT_OK); | ||
netConf_ = networkConfigForImsi(buf, strlen(buf)); | ||
int ret = checkImsiForNetConf(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: CHECK(checkImsiForNetConf())
9fc7409
to
e78c239
Compare
Problem
Boron LTEs get stuck in initialization with third party SIMs, due to AT+CIMI (IMSI lookup) error in certain cases.
Solution
In an attempt to set credentials during init, for any SIMs whose ICCIDs are not recognized, their IMSI is checked. Checking IMSI after setting UMNOPROF (mobile network operator profile) gives a
CME ERROR: SIM failure
orCME ERROR: SIM wrong
if not added a delay. Currently when this happens, we already have a retry logic that should have worked but the impl exits with an error instead of retrying.Steps to Test
Please make sure to use an external third-party SIM that is not recognized by network config db so that it's IMSI is checked to set credentials. We should no longer get stuck.
Example App
References
ch70471
Completeness