diff --git a/sys/include/net/netopt.h b/sys/include/net/netopt.h index 505240f4a0a96ca4946b86631d8b11feedc15b32..16d2a6975f8c9eb128eca506ceaca6b5da4bc3a3 100644 --- a/sys/include/net/netopt.h +++ b/sys/include/net/netopt.h @@ -260,6 +260,15 @@ typedef enum { */ NETOPT_L2FILTER_RM, + /** + * @brief Energy level during the last performed CCA or RX frame + * + * Get the last ED level available as an int8_t. The source of the + * measurement is unspecified and may come from the latest CCA + * measurement (CCA mode 1), or from the last received frame. + */ + NETOPT_LAST_ED_LEVEL, + /* add more options if needed */ /** diff --git a/sys/net/crosslayer/netopt/netopt.c b/sys/net/crosslayer/netopt/netopt.c index 77f1ab57ac38a12a20080fadc1615ae29702d475..63d89f0279ddce36c591087cb22d8972244f52f4 100644 --- a/sys/net/crosslayer/netopt/netopt.c +++ b/sys/net/crosslayer/netopt/netopt.c @@ -60,6 +60,7 @@ static const char *_netopt_strmap[] = { [NETOPT_RF_TESTMODE] = "NETOPT_RF_TESTMODE", [NETOPT_L2FILTER] = "NETOPT_L2FILTER", [NETOPT_L2FILTER_RM] = "NETOPT_L2FILTER_RM", + [NETOPT_LAST_ED_LEVEL] = "NETOPT_LAST_ED_LEVEL", [NETOPT_NUMOF] = "NETOPT_NUMOF", };