Commit 6793cb30 authored by Guido Casati's avatar Guido Casati

Refactor NR_UE_L2_STATE_t enum definition using X-Macro

- this change simplifies the enum definition and makes it easier
  to add, remove, or modify states in the future
- the states are now defined in the NR_UE_L2_STATES macro,
  and the enum members are generated automatically from this macro
parent 4062d3dc
......@@ -163,12 +163,18 @@
#define PRACH_MASK_INDEX 54
#define RESERVED_NR_DCI 55
// Define the UE L2 states with X-Macro
#define NR_UE_L2_STATES \
UE_STATE(UE_NOT_SYNC) \
UE_STATE(UE_SYNC) \
UE_STATE(UE_PERFORMING_RA) \
UE_STATE(UE_CONNECTED)
/*!\brief UE layer 2 status */
typedef enum {
UE_NOT_SYNC = 0,
UE_SYNC,
UE_PERFORMING_RA,
UE_CONNECTED
#define UE_STATE(state) state,
NR_UE_L2_STATES
#undef UE_STATE
} NR_UE_L2_STATE_t;
typedef enum {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment