[riot-notifications] [RIOT-OS/RIOT] WIP: tests/ieee802154_hal: extend radio hal test (#15761)

Lars Kowoll notifications at github.com
Wed Jan 13 14:13:54 CET 2021

The RIOT community cares a lot about code quality.
Therefore, before describing what your contribution is about, we would like
you to make sure that your modifications are compliant with the RIOT
coding conventions, see https://github.com/RIOT-OS/RIOT/wiki/Coding-conventions.

### Contribution description
This PR adds multiple functions for the IEEE 802.15.4

- spam:  Sends as fast and as many packets as specified in the parameters
- reply: The receiver sends the package back as soon as possible
- enable_prints: Prints interesting stuff. e.g. received packet. May has to be disabled due to timer issues caused by the printing
- test_channel: Sends and receive on different channels
- check_last_packet: Checks if the last packet matches to the expect sender

Put here the description of your contribution:
- describe which part(s) of RIOT is (are) involved
- if it's a bug fix, describe the bug that it solves and how it is solved
- you can also give more information to reviewers about how to test your changes

### Testing procedure
There will be a automated test in riotctrl.

For manual testing you need two boards and flash it with tests/ieee802154_hal

Usage of the function spam:
Call spam on board with the parameters
spam <address_board2> <length_of_the_payload> <number_of_packets> <delay>

If you call spam with the parameters spam <address_board2> 5 3 1
The device will send a packet to device2 every 1 ms with a payload of 3 Chars in total 5 packets will be send. 

You can set device2 in reply mode, means it will sends every packet back he receives, by calling the function reply. Just make sure to be easy on the delay otherwise the radio won't be able to handle this. You may disable the printing by calling the function enable_prints.

Details steps to test your contribution:
- which test/example to compile for which board and is there a 'test' command
- how to know that it was not working/available in master
- the expected success test output

### Issues/PRs references
Examples: Fixes #1234. See also #5678. Depends on PR #9876.

Please use keywords (e.g., fixes, resolve) with the links to the issues you
resolved, this way they will be automatically closed when your pull request
is merged. See https://help.github.com/articles/closing-issues-using-keywords/.

You can view, comment on, or merge this pull request online at:


-- Commit Summary --

  * add spam function
  * add global variables for cnt request and confirm
  * add assertion read and confirm will be called in the right order
  * add readme
  * Update readme.md
  * Update readme.md
  * Update readme.md
  * Update readme.md
  * Update readme.md
  * add test for switching channels
  * test for radio hal
  * riotctrl_shell/ieee802154: add spam and reply function
  * tests/ieee802154_hal: add channel test

-- File Changes --

    M cpu/cc2538/radio/cc2538_rf_radio_ops.c (7)
    A dist/pythonlibs/riotctrl_shell/ieee802154.py (198)
    M sys/include/net/ieee802154/radio.h (3)
    M tests/ieee802154_hal/Makefile (3)
    M tests/ieee802154_hal/main.c (348)
    A tests/ieee802154_hal/readme.md (32)

-- Patch Links --


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210113/2697b01e/attachment.htm>

More information about the notifications mailing list