Skip to content

LoRaWAN: Refactoring compliance test code #8074

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
Sep 20, 2018

Conversation

hasnainvirk
Copy link
Contributor

Description

While performing compliance tests with an industry tester, we realized
that there was no need for any extra handling code for the compliance
tests. The tests would run fine, if we only have a handling application.
However, in normal operation we wouldn't like the network to send us any
traffic on compliance testing port. To mitigate that, on the reception
path we filter out any traffic on compliance testing port if compliance
testing is not underway. User should define LORAWAN_COMPLIANCE_TEST macro
in mbed_app.json to enable traffic on compliance test port.

Pull request type

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

Target

5.10.1

@hasnainvirk
Copy link
Contributor Author

@AnttiKauppila @kivaisan Please review.

tr_debug("TX: Channel=%d, DR=%d", _params.channel, next_channel.current_datarate);

uint8_t dr_offset = _lora_phy->apply_DR_offset(_params.sys_params.channel_data_rate,
uint8_t rx_dr = _lora_phy->apply_DR_offset(_params.sys_params.channel_data_rate,
Copy link
Contributor

Choose a reason for hiding this comment

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

Please rename to rx1_dr because this is RX1 specific.

_params.sys_params.rx1_dr_offset);

_lora_phy->compute_rx_win_params(dr_offset, MBED_CONF_LORA_DOWNLINK_PREAMBLE_LENGTH,
tr_debug("TX: Channel=%d, TX DR=%d, RX DR=%d",
Copy link
Contributor

@kivaisan kivaisan Sep 11, 2018

Choose a reason for hiding this comment

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

Maybe RX DR should be also changed as "RX1 DR"

#if defined(LORAWAN_COMPLIANCE_TEST)

lorawan_status_t LoRaWANStack::send_compliance_test_frame_to_mac()
lorawan_status_t LoRaWANStack::fetch_current_session_info(lorawan_session_t &session)
Copy link
Contributor

Choose a reason for hiding this comment

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

This probably should not be part of this PR?

While performing compliance tests with an industry tester, we realized
that there was no need for any extra handling code for the compliance
tests. The tests would run fine, if we only have a handling application.
However, in normal operation we wouldn't like the network to send us any
traffic on compliance testing port. To mitigate that, on the reception
path we filter out any traffic on compliance testing port if compliance
testing is not underway. User should define LORAWAN_COMPLIANCE_TEST macro
in mbed_app.json to enable traffic on compliance test port.
@hasnainvirk
Copy link
Contributor Author

@kivaisan Please review again especially the method is_port_valid().

Copy link
Contributor

@kivaisan kivaisan left a comment

Choose a reason for hiding this comment

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

Looks good

@adbridge
Copy link
Contributor

@hasnainvirk Once we are into OOB for a minor release, only Critical or Blocking bugs found are generally considered for inclusion. There may be exceptions but that is the general policy. This however is a generic fix which is neither and thus can wait for 5.10.1.

@0xc0170
Copy link
Contributor

0xc0170 commented Sep 19, 2018

/morph build

@mbed-ci
Copy link

mbed-ci commented Sep 19, 2018

Build : SUCCESS

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

Triggering tests

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

@mbed-ci
Copy link

mbed-ci commented Sep 19, 2018

@mbed-ci
Copy link

mbed-ci commented Sep 20, 2018

@cmonr
Copy link
Contributor

cmonr commented Sep 20, 2018

time_start error in test runner. Retesting.

/morph test

@hasnainvirk
Copy link
Contributor Author

@cmonr Failure not related to this PR.

@0xc0170
Copy link
Contributor

0xc0170 commented Sep 20, 2018

/morph test

@mbed-ci
Copy link

mbed-ci commented Sep 20, 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