Skip to content

net/csma : Expose configurations to Kconfig#14252

Merged
leandrolanzieri merged 6 commits intoRIOT-OS:masterfrom
akshaim:Kconfig_csma
Jun 11, 2020
Merged

net/csma : Expose configurations to Kconfig#14252
leandrolanzieri merged 6 commits intoRIOT-OS:masterfrom
akshaim:Kconfig_csma

Conversation

@akshaim
Copy link
Copy Markdown
Member

@akshaim akshaim commented Jun 10, 2020

Contribution description

This PR exposes compile configurations in net/csma to Kconfig.

Testing procedure

  1. New documentation was built using Doxygen

    The build works fine.

  2. Test files were added to tests/net_csma/

    The test file can be found here

    Compiled binaries for native

Default State:

Firmware Output
RIOT native interrupts/signals initialized.
LED_RED_OFF
LED_GREEN_ON
RIOT native board initialized.
RIOT native hardware initialization complete.

main(): This is RIOT! (Version: 2020.07-devel-969-g4323df-Kconfig_csma_tests)
CONFIG_CSMA_SENDER_MIN_BE_DEFAULT=(3U)
CONFIG_CSMA_SENDER_MAX_BE_DEFAULT=(5U)
CONFIG_CSMA_SENDER_MAX_BACKOFFS_DEFAULT=(4U)
CONFIG_CSMA_SENDER_BACKOFF_PERIOD_UNIT=(320U)

Usage with CFLAGS :

CFLAGS += -DCONFIG_CSMA_SENDER_MIN_BE_DEFAULT=2
CFLAGS += -DCONFIG_CSMA_SENDER_MAX_BE_DEFAULT=4
CFLAGS += -DCONFIG_CSMA_SENDER_MAX_BACKOFFS_DEFAULT=3
CFLAGS += -DCONFIG_CSMA_SENDER_BACKOFF_PERIOD_UNIT=160
Firmware Output
RIOT native interrupts/signals initialized.
LED_RED_OFF
LED_GREEN_ON
RIOT native board initialized.
RIOT native hardware initialization complete.

main(): This is RIOT! (Version: 2020.07-devel-969-g4323df-Kconfig_csma_tests)
CONFIG_CSMA_SENDER_MIN_BE_DEFAULT=2
CONFIG_CSMA_SENDER_MAX_BE_DEFAULT=4
CONFIG_CSMA_SENDER_MAX_BACKOFFS_DEFAULT=3
CONFIG_CSMA_SENDER_BACKOFF_PERIOD_UNIT=160

Usage with menuconfig :

make menuconfig

Firmware Output
RIOT native interrupts/signals initialized.
LED_RED_OFF
LED_GREEN_ON
RIOT native board initialized.
RIOT native hardware initialization complete.

main(): This is RIOT! (Version: 2020.07-devel-969-g888ba5-Kconfig_csma_tests)
CONFIG_CSMA_SENDER_MIN_BE_DEFAULT=4
CONFIG_CSMA_SENDER_MAX_BE_DEFAULT=6
CONFIG_CSMA_SENDER_MAX_BACKOFFS_DEFAULT=2
CONFIG_CSMA_SENDER_BACKOFF_PERIOD_UNIT=400

MACROS were successfully configured.

Issues/PRs references

#12888

akshaim added 6 commits June 10, 2020 20:37
Add compile time parameters to config group
Move CSMA_SENDER_BACKOFF_PERIOD_UNIT to 'CONFIG_' namespace
Move CSMA_SENDER_MIN_BE_DEFAULT to 'CONFIG_' namespace
Move CSMA_SENDER_MAX_BE_DEFAULT to 'CONFIG_' namespace
Move CSMA_SENDER_MAX_BACKOFFS_DEFAULT  to 'CONFIG_' namespace
@leandrolanzieri leandrolanzieri added Area: Kconfig Area: Kconfig integration Type: new feature The issue requests / The PR implemements a new feature for RIOT CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Jun 11, 2020
Copy link
Copy Markdown
Contributor

@leandrolanzieri leandrolanzieri left a comment

Choose a reason for hiding this comment

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

Changes look good. Macros are applied correctly. ACK.

@leandrolanzieri leandrolanzieri added Reviewed: 1-fundamentals The fundamentals of the PR were reviewed according to the maintainer guidelines Reviewed: 2-code-design The code design of the PR was reviewed according to the maintainer guidelines Reviewed: 3-testing The PR was tested according to the maintainer guidelines Reviewed: 4-code-style The adherence to coding conventions by the PR were reviewed according to the maintainer guidelines Reviewed: 5-documentation The documentation details of the PR were reviewed according to the maintainer guidelines labels Jun 11, 2020
@leandrolanzieri leandrolanzieri added this to the Release 2020.07 milestone Jun 11, 2020
@leandrolanzieri leandrolanzieri merged commit a3fa7e3 into RIOT-OS:master Jun 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: Kconfig Area: Kconfig integration CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Reviewed: 1-fundamentals The fundamentals of the PR were reviewed according to the maintainer guidelines Reviewed: 2-code-design The code design of the PR was reviewed according to the maintainer guidelines Reviewed: 3-testing The PR was tested according to the maintainer guidelines Reviewed: 4-code-style The adherence to coding conventions by the PR were reviewed according to the maintainer guidelines Reviewed: 5-documentation The documentation details of the PR were reviewed according to the maintainer guidelines Type: new feature The issue requests / The PR implemements a new feature for RIOT

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants