add testmode and cca mode option to netdev#5485
add testmode and cca mode option to netdev#5485miri64 merged 3 commits intoRIOT-OS:masterfrom jfischer-no:pr@add-opt-netdev
Conversation
sys/include/net/netopt.h
Outdated
| * @brief get/set the CCA mode for the radio transceiver | ||
| * | ||
| * Set the type corresponding to the respective PHY standard, | ||
| * e.g Std 802.15.4 |
There was a problem hiding this comment.
Please document required type of value
There was a problem hiding this comment.
No, just trigger happy auto-correction ;)
|
@miri64 ping |
sys/include/net/netopt.h
Outdated
| * @brief Test mode for the radio, e.g. for CE or FCC certification | ||
| * | ||
| * @note Setting this option should always return -ENOTSUP, | ||
| * unless it was explicitly allowed to build time, |
There was a problem hiding this comment.
"at build time", unless you really require the option to construct time ;-)
|
@miri64 updated |
|
ACK, please squash. |
|
Ooops, sorry for forgetting about this one. |
sys/include/net/netopt.h
Outdated
| * unless it was explicitly allowed at build time, | ||
| * therefore it should be secured with an additional macro in the device driver. | ||
| * For development and certification purposes only, this test modes can disturb | ||
| * normal radio communications and exceed the limits, established by |
There was a problem hiding this comment.
There is a trailing whitespace here.
|
I think |
|
@miri64 I'm just on it, what do you mean about |
You probably just have to extend the _netopt_strmap. |
@miri64 finished |
This patch adds two new options to netopt. NETOPT_CCA_MODE to set the CCA mode corresponding to the respective PHY standard and NETOPT_RF_TESTMODE to set the test mode for the radio.
|
Sorry again for forgetting >.<. Let's see what Murdock thinks. |
| */ | ||
| typedef enum { | ||
| NETDEV2_IEEE802154_CCA_MODE_1 = 1, /**< Energy above threshold */ | ||
| NETDEV2_IEEE802154_CCA_MODE_2, /**< Carrier sense only */ |
There was a problem hiding this comment.
This mode need more information if it's logical OR "or" AND mode.
There was a problem hiding this comment.
@jfischer-phytec-iot could you provide another PR for this, please?
There was a problem hiding this comment.
@alexaring you mean NETDEV2_IEEE802154_CCA_MODE_3 ?
This PR adds a Testmode option and CCA Mode option to netdev (netopt).
Picked from #5469