net: l2: Add symbols for custom IEEE802154 L2
Define a custom IEEE802154 based L2. The user can then use those symbols to implement their own 802.15.4 based L2, based on those symbols, w/o a need to modify the Zephyr tree. Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
This commit is contained in:
parent
5cf235e601
commit
f3a9b8c83d
3 changed files with 26 additions and 1 deletions
|
@ -132,6 +132,14 @@ NET_L2_DECLARE_PUBLIC(CANBUS_RAW_L2);
|
|||
NET_L2_DECLARE_PUBLIC(CANBUS_L2);
|
||||
#endif /* CONFIG_NET_L2_CANBUS */
|
||||
|
||||
#ifdef CONFIG_NET_L2_CUSTOM_IEEE802154
|
||||
#ifndef CUSTOM_IEEE802154_L2
|
||||
#define CUSTOM_IEEE802154_L2 CUSTOM_IEEE802154
|
||||
#endif
|
||||
#define CUSTOM_IEEE802154_L2_CTX_TYPE void*
|
||||
NET_L2_DECLARE_PUBLIC(CUSTOM_IEEE802154_L2);
|
||||
#endif /* CONFIG_NET_L2_CUSTOM_IEEE802154 */
|
||||
|
||||
#define NET_L2_INIT(_name, _recv_fn, _send_fn, _enable_fn, _get_flags_fn) \
|
||||
const STRUCT_SECTION_ITERABLE(net_l2, \
|
||||
NET_L2_GET_NAME(_name)) = { \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue