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

Cellular: Add API to clear CellularDevice #11414

Merged
merged 1 commit into from
Sep 10, 2019

Conversation

AriParkkila
Copy link

A new API CellularDevice::clear() to clean-up the modem to a default initial state.
Function is virtual so it can be overridden. The default implementation clears all PDP contexts,
but the the first one if that has APN defined as nsapi.default-cellular-apn.

CellularStateMachine calls clear() to clean-up the modem on initial connect(),
if the flag cellular.clear-on-connect: true is defined.

Description

Pull request type

[ ] Fix
[ ] Refactor
[ ] Target update
[x] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

Reviewers

@mirelachirica @jarvte

Release Notes

CellularStateMachine calls CellularDevice::clear() to clean-up the modem on initial connect().
The previous functionality can be restored by defining the flag cellular.clear-on-connect: false.

@ciarmcom ciarmcom requested review from jarvte, mirelachirica and a team September 5, 2019 09:00
@ciarmcom
Copy link
Member

ciarmcom commented Sep 5, 2019

@AriParkkila, thank you for your changes.
@mirelachirica @jarvte @ARMmbed/mbed-os-wan @ARMmbed/mbed-os-maintainers please review.

@trowbridgec
Copy link

This will be a nice addition as I've sometimes run into situations where I needed to clear the PDP contexts (e.g. sometimes when switching between APNs).

@kimlep01
Copy link

kimlep01 commented Sep 6, 2019

We have seen connectivity issues with this PR when running internal cellular tests against our network simulator. We are currently investigating the issue.

A new API `CellularDevice::clear()` to clean-up the modem to a default initial state.
Function is virtual so it can be overridden. The default implementation clears all PDP contexts,
but the the first one if that has APN defined as `nsapi.default-cellular-apn`.

CellularStateMachine calls `clear()` to clean-up the modem on initial `connect()`,
if the flag `cellular.clear-on-connect: true` is defined.
@AriParkkila
Copy link
Author

@kimlep01 Please re-test with the latest changes, @jarvte please re-review state-machine changes.

Copy link
Contributor

@jarvte jarvte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

STM changes LGTM

@kimlep01
Copy link

Internal tests working again without issues with the latest commit.

@0xc0170
Copy link
Contributor

0xc0170 commented Sep 10, 2019

CI started

@mbed-ci
Copy link

mbed-ci commented Sep 10, 2019

Test run: SUCCESS

Summary: 11 of 11 test jobs passed
Build number : 1
Build artifacts

@adbridge adbridge added the release-version: 6.0.0-alpha-1 First pre-release version of 6.0.0 label Oct 3, 2019
@0xc0170 0xc0170 added release-version: 5.15.0-rc1 and removed release-version: 6.0.0-alpha-1 First pre-release version of 6.0.0 labels Nov 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants