From aafe6d435b9f2ea7c0d4242dc47715ac86fcd9d1 Mon Sep 17 00:00:00 2001 From: Mohamed AYED <81168645+ayedm1@users.noreply.github.com> Date: Tue, 4 Feb 2025 22:02:06 +0100 Subject: [PATCH] add device state check define to avoid use of internal struct fileds in app level --- common/core/inc/ux_api.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common/core/inc/ux_api.h b/common/core/inc/ux_api.h index 6689eb0..8ab0ea4 100644 --- a/common/core/inc/ux_api.h +++ b/common/core/inc/ux_api.h @@ -2685,6 +2685,10 @@ typedef struct UX_SYSTEM_SLAVE_STRUCT #define UX_SYSTEM_DEVICE_MAX_CLASS_GET() (1) #endif +#define UX_SLAVE_DEVICE_CHECK_STATE(state) \ + (_ux_system_slave->ux_system_slave_device.ux_slave_device_state & (state)) ? UX_TRUE : UX_FALSE \ + + typedef struct UX_SYSTEM_OTG_STRUCT {