I have ATSAME MCU and ESP32.
I used ready to use esp-idf examples to create http_request in eclipse with ESP32(standalone).
Now, I want to make a tcp_client using ESP32 module together with ATSAME53. ATSAME will be acting as the main MCU and I want to create a client using netconn APIs in lwip which will be in ATSAME. ESP32 uart pins connected to uart pins in ATSAME. I want ESP32 to be just bridge and give data from the router(internet) to ATSAME which will use lwip to process it and create a netconn client.
(ESP-->ATSAME)
I changed inside wlanif_input(struct netif *netif, void *buffer, u16_t len, void* eb) function in ESPlwip and send the buffer(packet) to ATSAME using uart(instead of tcpip_thread to process). I want packets to be processed in ATSAMElwip. When I received packets from ESP32 in ATSAME side, I called tcpip_input(p, &TCPIP_STACK_INTERFACE_0_desc) to send it to tcpip_thread to be processed.
(ATSAME-->ESP)
Coming packets from ATSAMElwip were sent to esp using tcpip_output_raw (I created it and called from TCPIP_STACK_INTERFACE_0_stack_init fn) and received in ESP using low_level_output function and sent using esp_wifi_internal_tx(wifi_if, q->payload, q->len);
*But I have problems with creating netif. Shall I have two separate netifs(one in ESP and one in ATSAME)?
*Is it possible to realize whats in my mind?
************ ***************
| ESP32 tx|---->|rx ATSAME|
| rx|<----|tx |
************* **************
connect to internet(create a tcpip client using netconn) using ESP32 and ATSAME(main MCU)
Re: connect to internet(create a tcpip client using netconn) using ESP32 and ATSAME(main MCU)
So, I have interfaced ethernet and GPRS module with ATSAME MCU and its working. I have also used ready to use ESP32 examples and created tcpip_client.
Now I need to connect ESP32 to ATSAME through UART and create netconn(LWIP) connection in ATSAME side.
Can you tell me how to proceed?
Now I need to connect ESP32 to ATSAME through UART and create netconn(LWIP) connection in ATSAME side.
Can you tell me how to proceed?
Who is online
Users browsing this forum: Baidu [Spider], Google [Bot] and 82 guests