Skip to content

[IOTCELL-741] Separating public data structures #6588

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

Merged
merged 1 commit into from
Apr 17, 2018

Conversation

hasnainvirk
Copy link
Contributor

Description

Any data structure used in LoRaWANBase class should be available
in a separate header in order to make the code easy to port and
easy to read as the developer doesn't need to know about all the
internal data structures being used in Mbed LoRaWAN stack.

Pull request type

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

@hasnainvirk
Copy link
Contributor Author

@AnttiKauppila @kivaisan Please review.

@@ -19,7 +19,7 @@
#ifndef LORAWAN_BASE_H_
#define LORAWAN_BASE_H_

#include "lorawan/system/lorawan_data_structures.h"
#include "lorawan/base_structs.h"
Copy link

@AnttiKauppila AnttiKauppila Apr 10, 2018

Choose a reason for hiding this comment

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

remove lorawan/ from include

@@ -19,7 +19,7 @@
#ifndef LORAWAN_BASE_H_
#define LORAWAN_BASE_H_

#include "lorawan/system/lorawan_data_structures.h"
#include "lorawan/base_structs.h"
Copy link
Contributor

Choose a reason for hiding this comment

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

base_structs.h is not a good name as file is not just about structs but all kind of data types. Also filename should include term lora.

@hasnainvirk
Copy link
Contributor Author

@AnttiKauppila @kivaisan This needs review

RX_TIMEOUT,
RX_ERROR,
JOIN_FAILURE,
} lorawan_event_t;
Copy link
Contributor

Choose a reason for hiding this comment

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

Please move description of events from add_app_callbacks().

@hasnainvirk
Copy link
Contributor Author

@AnttiKauppila @kivaisan please review again.

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 12, 2018

/morph build

@hasnainvirk
Copy link
Contributor Author

@0xc0170 please review.

@hasnainvirk
Copy link
Contributor Author

@kjbracey-arm Please review.

@mbed-ci
Copy link

mbed-ci commented Apr 12, 2018

Build : FAILURE

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

@kjbracey
Copy link
Contributor

I think the naming is a little off - general assumption is normally that headers are public, unless they're in a /system subdirectory or something, so including "public" in the name is a bit weird.

Also, to make it a bit more generic than structures, often "types" is used, eg "nsapi_types.h". I'd suggest "lorawan_types.h"

@hasnainvirk
Copy link
Contributor Author

@kjbracey-arm Please review again. @0xc0170 Morph build needed.

kjbracey
kjbracey previously approved these changes Apr 12, 2018
0xc0170
0xc0170 previously approved these changes Apr 12, 2018
@0xc0170
Copy link
Contributor

0xc0170 commented Apr 12, 2018

/morph build

@hasnainvirk
Copy link
Contributor Author

@0xc0170 Morph build failed for some BLE test. Logs are just too much to find anything useful. Can you please help me here to figure out what is happening here ?

@mbed-ci
Copy link

mbed-ci commented Apr 12, 2018

Build : SUCCESS

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

Triggering tests

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

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 12, 2018

@0xc0170 Morph build failed for some BLE test. Logs are just too much to find anything useful. Can you please help me here to figure out what is happening here ?

The last build is fine after your latest changes. I restarted jenkins CI as well as there was failure not related tot this changeset I assume, please verify

@mbed-ci
Copy link

mbed-ci commented Apr 12, 2018

@mbed-ci
Copy link

mbed-ci commented Apr 12, 2018

Any data structure used in LoRaWANBase class should be available
in a separate header in order to make the code easy to port and
easy to read as the developer doesn't need to know about all the
internal data structures being used in Mbed LoRaWAN stack.
@hasnainvirk
Copy link
Contributor Author

@kjbracey-arm @0xc0170 Please review again. Rebased after resolving conflict.

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 13, 2018

/morph build

@mbed-ci
Copy link

mbed-ci commented Apr 13, 2018

Build : SUCCESS

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

Triggering tests

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

@hasnainvirk
Copy link
Contributor Author

@0xc0170 Seems like CI ran out of memory. pr-head for CLI app failed. Could we start the job again ?

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 13, 2018

@0xc0170 Seems like CI ran out of memory. pr-head for CLI app failed. Could we start the job again ?

This is known problem, waiting for CI infra team to fix or github. Affected few other PR. Olli can provide details

@mbed-ci
Copy link

mbed-ci commented Apr 13, 2018

@mbed-ci
Copy link

mbed-ci commented Apr 13, 2018

@hasnainvirk
Copy link
Contributor Author

@0xc0170 @cmonr Needs CI again. Hope this time CI Infra team have eventually fixed the issue.

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 16, 2018

@0xc0170 @cmonr Needs CI again. Hope this time CI Infra team have eventually fixed the issue.

In progress, yet not fixed. That is the only CI stage missing in this PR at the moment.

@hasnainvirk
Copy link
Contributor Author

@0xc0170 @cmonr Can this get CI please ?

@0xc0170
Copy link
Contributor

0xc0170 commented Apr 17, 2018

@0xc0170 @cmonr Can this get CI please ?

I scheduled one few minutes ago, waiting for the result

@hasnainvirk
Copy link
Contributor Author

@0xc0170 This can proceed with merge.

@cmonr cmonr merged commit 4522405 into ARMmbed:master Apr 17, 2018
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.

7 participants