From 086d4d127d2b85d8e04c73f7f54fc90c0a2e5c57 Mon Sep 17 00:00:00 2001 From: Jared Hancock Date: Wed, 20 Mar 2024 09:04:49 -0500 Subject: [PATCH] extmod/network_wiznet5k: Properly enable interrupt signal on w5100s. According to the datasheet, the IEN bit to enable the interrupt is in the MR2 register, not the MR register. This is just cleanup as the interrupt appears to be enabled by default after resetting the chip. Tested on W5100S_EVB_PICO. --- extmod/network_wiznet5k.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extmod/network_wiznet5k.c b/extmod/network_wiznet5k.c index b550f8c1f4..b8ca075b3d 100644 --- a/extmod/network_wiznet5k.c +++ b/extmod/network_wiznet5k.c @@ -221,7 +221,7 @@ static void wiznet5k_init(void) { setSn_IMR(0, Sn_IR_RECV); #if _WIZCHIP_ == W5100S // Enable interrupt pin - setMR(MR2_G_IEN); + setMR2(getMR2() | MR2_G_IEN); #endif mp_hal_pin_input(wiznet5k_obj.pin_intn);