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

standard non-blocking NetworkInterface::connect #6496

Merged
merged 35 commits into from Apr 12, 2018

Conversation

Projects
None yet
8 participants
@jarvte
Contributor

jarvte commented Mar 28, 2018

Description

• the standard non-blocking NetworkInterface::connect API introduced in mbed OS 5.8, including its events
• new cellular-specific status events

Internal ref to defect: IOTCELL-526

Pull request type

[X] Fix
[ ] Refactor
[ ] New target
[ ] Feature
[ ] Breaking change

@cmonr

This comment has been minimized.

Contributor

cmonr commented Mar 29, 2018

As an FYI, this PR is being discussed in an internal email, determining if this PR needs to be considered a Feature.

@0xc0170 0xc0170 requested a review from AnttiKauppila Apr 3, 2018

uint16_t _retry_timeout_array[MAX_RETRY_ARRAY_SIZE];
int _retry_array_length;
events::EventQueue _at_queue;
char _st_string[20];
int _eventID;

This comment has been minimized.

@AnttiKauppila

AnttiKauppila Apr 4, 2018

Contributor

_event_id

This comment has been minimized.

@jarvte

jarvte Apr 4, 2018

Contributor

fixed.

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 6, 2018

Can you please rebase to resolve conflicts?

@jarvte jarvte force-pushed the jarvte:async_cellular branch from 20c7d19 to bb23b1c Apr 6, 2018

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 6, 2018

@0xc0170 , rebased master and fixed conflicts.

@jarvte jarvte closed this Apr 6, 2018

@jarvte jarvte reopened this Apr 6, 2018

@0xc0170

Just a question,

virtual void attach(mbed::Callback<void(nsapi_event_t, intptr_t)> status_cb); - a user is expected to have a state machine there in the callback? Would it be worse to attach actually a callback for a state ? so callback, state, similar to how Serial does (RX or TX).

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 6, 2018

/morph build

@0xc0170 0xc0170 added the needs: CI label Apr 6, 2018

@mbed-ci

This comment has been minimized.

mbed-ci commented Apr 6, 2018

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 6, 2018

@jarvte Please review failures, look related to the changeset

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 9, 2018

Jenkins CI failure is know github issue, haven't yet received an update from github about it.

/morph build

@mbed-ci

This comment has been minimized.

mbed-ci commented Apr 9, 2018

Build : SUCCESS

Build number : 1679
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/6496/

Triggering tests

/morph test
/morph uvisor-test
/morph export-build
/morph mbed2-build

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 9, 2018

@0xc0170
virtual void attach(mbed::Callback<void(nsapi_event_t, intptr_t)> status_cb); is declared in NetworkInterface, we are kind of proxy here, adding some callbacks. We have different callback for statemachine states: void set_callback(mbed::Callback<bool(int, int)> status_callback);

@mbed-ci

This comment has been minimized.

@mbed-ci

This comment has been minimized.

@0xc0170 0xc0170 added needs: CI and removed needs: work labels Apr 9, 2018

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 10, 2018

@0xc0170 should I try to rebase latest from master to github issue potentially working?
Or is it proceeding?

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 10, 2018

@0xc0170 should I try to rebase latest from master to github issue potentially working?
Or is it proceeding?

Lets try. I am testing jenkins CI and github but so far have not found a solution. We experienced that adding a commit sometimes help to refresh github PR

would be great to workaround this for now, the results should be visible quickly

@jarvte jarvte force-pushed the jarvte:async_cellular branch from 3e8e4e4 to 6c43dae Apr 10, 2018

@cmonr

This comment has been minimized.

Contributor

cmonr commented Apr 10, 2018

/morph build

@mbed-ci

This comment has been minimized.

mbed-ci commented Apr 10, 2018

Build : SUCCESS

Build number : 1715
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/6496/

Triggering tests

/morph test
/morph uvisor-test
/morph export-build
/morph mbed2-build

@mbed-ci

This comment has been minimized.

@jarvte jarvte force-pushed the jarvte:async_cellular branch from 19cb2ca to 9c185d9 Apr 11, 2018

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 11, 2018

@0xc0170 had to fix conflicts that appeared so let's try once again :)

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 11, 2018

Will do soon, fixing one target issue in CI

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 11, 2018

/morph build

@mbed-ci

This comment has been minimized.

mbed-ci commented Apr 11, 2018

Build : SUCCESS

Build number : 1719
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/6496/

Triggering tests

/morph test
/morph uvisor-test
/morph export-build
/morph mbed2-build

@mbed-ci

This comment has been minimized.

@mbed-ci

This comment has been minimized.

@cmonr

This comment has been minimized.

Contributor

cmonr commented Apr 11, 2018

Ignore the above (^^^) failure. This is from the first morph build command.

@mbed-ci

This comment has been minimized.

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 12, 2018

@0xc0170 please approve and merge as our development continues over this change.

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 12, 2018

As an FYI, this PR is being discussed in an internal email, determining if this PR needs to be considered a Feature.

Tagged as feature/refactor, 5.9

There's one change I would like @kjbracey-arm to check, nsapi_event_t additions in https://github.com/ARMmbed/mbed-os/pull/6496/files#diff-343c62b2c4de5626e8e2a8e0823ef74aR81

@kjbracey-arm

This comment has been minimized.

Contributor

kjbracey-arm commented Apr 12, 2018

I'm fine with the nsapi_event_t change. Just one thing I want clarified - the PR description of what this is implementing. From reading the code, I believe it's

  • the standard non-blocking NetworkInterface::connect API introduced in mbed OS 5.8, including its events
  • new cellular-specific status events
@0xc0170

This comment has been minimized.

Member

0xc0170 commented Apr 12, 2018

@jarvte CAn you please edit the title (it's used for release notes) so better be specific what this PR introduces (keep it within 50 characters)

@jarvte

This comment has been minimized.

Contributor

jarvte commented Apr 12, 2018

@0xc0170 comment updated, please merge.

@jarvte jarvte changed the title from Async cellular to standard non-blocking NetworkInterface::connect Apr 12, 2018

@0xc0170 0xc0170 merged commit a463b07 into ARMmbed:master Apr 12, 2018

12 checks passed

AWS-CI uVisor Build & Test Success
Details
ci-morph-build build completed
Details
ci-morph-exporter build completed
Details
ci-morph-mbed2-build build completed
Details
ci-morph-test test completed
Details
continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
travis-ci/docs Local docs testing has passed
Details
travis-ci/events Passed, runtime is 10061 cycles (+298 cycles)
Details
travis-ci/gitattributestest Local gitattributestest testing has passed
Details
travis-ci/littlefs Passed, code size is 10092B (+0.00%)
Details
travis-ci/tools Local tools testing has passed
Details

@jarvte jarvte deleted the jarvte:async_cellular branch Apr 12, 2018

chuanga added a commit to chuanga/wise-1570-mbed-os-example-cellular that referenced this pull request Apr 19, 2018

Update mbed-os.lib
Update Mbed OS to a pre 5.9 master branch for the PR 6494 (ARMmbed/mbed-os#6496). This is for testing with WISE-1570 NBIoT module
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment