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: Basic driver for Quectel EC25/EC21 #10292

Merged
merged 7 commits into from Apr 9, 2019

Conversation

Projects
None yet
8 participants
@hasnainvirk
Copy link
Contributor

commented Apr 2, 2019

Description

Provides basic power up / power down sequences for Quectel EC2X series
modems. Can be used in PPP mode. For using the on-board IP stack, we
will need to add and implement classes that provide context.

Driver constructor takes power and reset control pins along with the
FileHandle. A default construction is provided which can be chosen by
the application in its mbed_app.json. Otherwise the user is free to
construct as per demand.

Pull request type

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

Reviewers

Release Notes

@hasnainvirk hasnainvirk force-pushed the hasnainvirk:ec2x_driver branch 2 times, most recently from 3db6e4f to 1c874da Apr 2, 2019

@hasnainvirk hasnainvirk changed the title Basic driver for Quectel EC25/EC21 [Cellular] Basic driver for Quectel EC25/EC21 Apr 2, 2019

@ciarmcom ciarmcom requested review from ARMmbed/mbed-os-maintainers Apr 2, 2019

@ciarmcom

This comment has been minimized.

Copy link
Member

commented Apr 2, 2019

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

@hasnainvirk

This comment has been minimized.

Copy link
Contributor Author

commented Apr 2, 2019

@hasnainvirk hasnainvirk force-pushed the hasnainvirk:ec2x_driver branch from 1c874da to 49bebb4 Apr 3, 2019

@hasnainvirk hasnainvirk force-pushed the hasnainvirk:ec2x_driver branch from cfee83c to cae857a Apr 3, 2019

@hasnainvirk

This comment has been minimized.

Copy link
Contributor Author

commented Apr 4, 2019

@kivaisan @AriParkkila Please review again.

@0xc0170 0xc0170 changed the title [Cellular] Basic driver for Quectel EC25/EC21 Cellular: Basic driver for Quectel EC25/EC21 Apr 4, 2019

@0xc0170

This comment has been minimized.

Copy link
Member

commented Apr 8, 2019

[X] New target driver

Please do not add new/remove the current PR type. This one falls into target update. I've fixed it

@0xc0170

0xc0170 approved these changes Apr 8, 2019

@0xc0170

This comment has been minimized.

Copy link
Member

commented Apr 8, 2019

Ci started

@mbed-ci

This comment has been minimized.

Copy link

commented Apr 8, 2019

Test run: FAILED

Summary: 2 of 9 test jobs failed
Build number : 1
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_build-ARMC6
  • jenkins-ci/mbed-os-ci_build-ARMC5

@0xc0170 0xc0170 added needs: work and removed needs: CI labels Apr 8, 2019

hasnainvirk added some commits Mar 29, 2019

Basic driver for Quectel EC25/EC21
Provides basic power up / power down sequences for Quectel EC2X series
modems. Can be used in PPP mode. For using the on-board IP stack, we
will need to add and implement classes that provide context.

Driver constructor takes power and reset control pins along with the
FileHandle. A default construction is provided which can be chosen by
the application in its mbed_app.json. Otherwise the user is free to
construct as per demand.
Removing left over tracing
A test trace was left lurking around. Removed in this commit.
CREG can handle lac/ci/lat
AT+CREG command can also provide information regarding lac/ci/lat etc so
we should set the mode correctly in cellular properties structure.
AT+CGSN with EC2X does not take parameter
Standard 3GPP TS27.007 states that the AT+CGSN command can optionally
have type parameter that determines the output. However Quiectel EC2X
series doesn't accept parameters. We need to reflect that in the
cellular properties setup.

hasnainvirk added some commits Apr 4, 2019

Tidying up the boiler plate code
A little tidying up was needed as there was some boiler plate code that
could be shoved into a corner and reused.
Adding pin polarity and changing the constructor
To make this driver more useful, we needed to do some changes. The
wirings for the modem can differ on the board so we also need to be
flexible in our approach.
It is now mandatory to provide the power pin and pin polarity in the
constructor alongwith the file handle. Reset pin is optional.

@hasnainvirk hasnainvirk force-pushed the hasnainvirk:ec2x_driver branch from 48fd512 to 7ebfa90 Apr 8, 2019

@hasnainvirk

This comment has been minimized.

Copy link
Contributor Author

commented Apr 8, 2019

@AnttiKauppila @AriParkkila @kivaisan Please review again.

@0xc0170 0xc0170 added needs: review and removed needs: work labels Apr 8, 2019

@AriParkkila
Copy link
Contributor

left a comment

Is it intentionally assumed that pwr and rst pin polarity are the same?

@hasnainvirk

This comment has been minimized.

Copy link
Contributor Author

commented Apr 9, 2019

Is it intentionally assumed that pwr and rst pin polarity are the same?

Yes that is right.

Marking TX and RX pins for UARTSerial as NC
For default construction of the driver, it would be necessary to define
the pins. However as we don't know the correct pins, until/unless user
sets them up for us. So it makes sense to mark the pins as NC. It would
be easier to debug if the pins are set to NC if user forgot to set them
up.

@0xc0170 0xc0170 added needs: CI and removed needs: review labels Apr 9, 2019

@0xc0170

This comment has been minimized.

Copy link
Member

commented Apr 9, 2019

CI started

@mbed-ci

This comment has been minimized.

Copy link

commented Apr 9, 2019

Test run: FAILED

Summary: 1 of 11 test jobs failed
Build number : 2
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_greentea-test
@0xc0170

This comment has been minimized.

Copy link
Member

commented Apr 9, 2019

Failed test jobs:

Test passed (second round).

@0xc0170 0xc0170 added ready for merge and removed needs: CI labels Apr 9, 2019

@cmonr cmonr merged commit 6dbc00d into ARMmbed:master Apr 9, 2019

26 checks passed

continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
jenkins-ci/build-ARM Success
Details
jenkins-ci/build-GCC_ARM Success
Details
jenkins-ci/build-IAR Success
Details
jenkins-ci/cloud-client-test Success
Details
jenkins-ci/dynamic-memory-usage RTOS ROM(+0 bytes) RAM(+0 bytes)
Details
jenkins-ci/exporter Success
Details
jenkins-ci/greentea-test Success
Details
jenkins-ci/mbed2-build-ARM Success
Details
jenkins-ci/mbed2-build-GCC_ARM Success
Details
jenkins-ci/mbed2-build-IAR Success
Details
jenkins-ci/unittests Success
Details
travis-ci/astyle Local astyle testing has passed
Details
travis-ci/docs Local docs testing has passed
Details
travis-ci/doxy-spellcheck Local doxy-spellcheck testing has passed
Details
travis-ci/events Passed, runtime is 9267 cycles (-744 cycles)
Details
travis-ci/gitattributestest Local gitattributestest testing has passed
Details
travis-ci/include_check Local include_check testing has passed
Details
travis-ci/licence_check Local licence_check testing has passed
Details
travis-ci/littlefs Passed, code size is 8408B (+0.00%)
Details
travis-ci/psa-autogen Local psa-autogen testing has passed
Details
travis-ci/tools-py2.7 Local tools-py2.7 testing has passed
Details
travis-ci/tools-py3.5 Local tools-py3.5 testing has passed
Details
travis-ci/tools-py3.6 Local tools-py3.6 testing has passed
Details
travis-ci/tools-py3.7 Local tools-py3.7 testing has passed
Details

@cmonr cmonr removed the ready for merge label Apr 9, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.