@@ -22123,7 +22123,8 @@ bool mg_wifi_ap_stop(void) {
2212322123
2212422124#if MG_ENABLE_TCPIP && \
2212522125 (defined(MG_ENABLE_DRIVER_IMXRT10) && MG_ENABLE_DRIVER_IMXRT10) || \
22126- (defined(MG_ENABLE_DRIVER_IMXRT11) && MG_ENABLE_DRIVER_IMXRT11)
22126+ (defined(MG_ENABLE_DRIVER_IMXRT11) && MG_ENABLE_DRIVER_IMXRT11) || \
22127+ (defined(MG_ENABLE_DRIVER_MCXE) && MG_ENABLE_DRIVER_MCXE)
2212722128struct imxrt_enet {
2212822129 volatile uint32_t RESERVED0, EIR, EIMR, RESERVED1, RDAR, TDAR, RESERVED2[3],
2212922130 ECR, RESERVED3[6], MMFR, MSCR, RESERVED4[7], MIBC, RESERVED5[7], RCR,
@@ -22152,9 +22153,12 @@ struct imxrt_enet {
2215222153#if defined(MG_ENABLE_DRIVER_IMXRT11) && MG_ENABLE_DRIVER_IMXRT11
2215322154#define ENET ((struct imxrt_enet *) (uintptr_t) 0x40424000U)
2215422155#define ETH_DESC_CNT 5 // Descriptors count
22155- #else
22156+ #elif defined(MG_ENABLE_DRIVER_IMXRT10) && MG_ENABLE_DRIVER_IMXRT10
2215622157#define ENET ((struct imxrt_enet *) (uintptr_t) 0x402D8000U)
2215722158#define ETH_DESC_CNT 4 // Descriptors count
22159+ #else // MG_ENABLE_DRIVER_MCXE
22160+ #define ENET ((struct imxrt_enet *) (uintptr_t) 0x40079000U)
22161+ #define ETH_DESC_CNT 4 // Descriptor count
2215822162#endif
2215922163
2216022164#define ETH_PKT_SIZE 1536 // Max frame size, 64-bit aligned
@@ -22310,9 +22314,14 @@ static bool mg_tcpip_driver_imxrt_poll(struct mg_tcpip_if *ifp, bool s1) {
2231022314 return up;
2231122315}
2231222316
22313- void ENET_IRQHandler(void);
2231422317static uint32_t s_rxno;
22318+ #if !defined(MG_ENABLE_DRIVER_MCXE)
22319+ void ENET_IRQHandler(void);
2231522320void ENET_IRQHandler(void) {
22321+ #else
22322+ void ENET_Receive_IRQHandler(void);
22323+ void ENET_Receive_IRQHandler(void) {
22324+ #endif
2231622325 ENET->EIR = MG_BIT(25); // Ack IRQ
2231722326 // Frame received, loop
2231822327 for (uint32_t i = 0; i < 10; i++) { // read as they arrive but not forever
0 commit comments