@@ -48,15 +48,6 @@ extern recursive_mutex_t __lwipMutex;
4848class LWIPMutex {
4949public:
5050 LWIPMutex () {
51- // if (ethernet_arch_lwip_gpio_mask) {
52- // ethernet_arch_lwip_gpio_mask();
53- // }
54- // #if defined(ARDUINO_RASPBERRY_PI_PICO_W)
55- // if (rp2040.isPicoW()) {
56- // cyw43_arch_lwip_begin();
57- // return;
58- // }
59- // #endif
6051#if !defined(__FREERTOS)
6152 if (ethernet_arch_lwip_begin) {
6253 ethernet_arch_lwip_begin ();
@@ -67,24 +58,11 @@ class LWIPMutex {
6758 }
6859
6960 ~LWIPMutex () {
70- #if !defined(__FREERTOS)
71- // #if defined(ARDUINO_RASPBERRY_PI_PICO_W)
72- // if (rp2040.isPicoW()) {
73- // cyw43_arch_lwip_end();
74- // } else {
75- // #endif
7661 if (ethernet_arch_lwip_end) {
7762 ethernet_arch_lwip_end ();
7863 } else {
7964 recursive_mutex_exit (&__lwipMutex);
8065 }
81- // #if defined(ARDUINO_RASPBERRY_PI_PICO_W)
82- // }
83- // #endif
84- #endif
85- // if (ethernet_arch_lwip_gpio_unmask) {
86- // ethernet_arch_lwip_gpio_unmask();
87- // }
8866 }
8967};
9068
@@ -167,8 +145,10 @@ typedef enum {
167145
168146 __ethernet_input = 9000 ,
169147
148+ #if defined(PICO_CYW43_SUPPORTED)
170149 __cyw43_wifi_join = 9500 ,
171150 __cyw43_wifi_leave,
151+ #endif
172152
173153 __callback = 10000 ,
174154} __lwip_op;
@@ -573,6 +553,7 @@ typedef struct {
573553 err_t *ret;
574554} __ethernet_input_req;
575555
556+ #if defined(PICO_CYW43_SUPPORTED)
576557typedef struct {
577558 cyw43_t *self;
578559 size_t ssid_len;
@@ -590,6 +571,7 @@ typedef struct {
590571 int itf;
591572 int *ret;
592573} __cyw43_wifi_leave_req;
574+ #endif
593575
594576// Run a callback in the LWIP thread (i.e. for Ethernet device polling and packet reception)
595577// When in an interrupt, need to pass in a heap-allocated buffer
0 commit comments