Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting ESP32 talking through Ethernet on SPI rather than WiFi for all comms #2524

Closed
codehampster opened this issue Aug 24, 2023 · 2 comments

Comments

@codehampster
Copy link

This is one request that I am struggling to find much material on and it is a bit of a niche case.

I have ESP32 that connects to IoT Central via WiFi using Azure SDK for C. All that is working fine. However, I have a circumstance where there is so much RF interference that the only reliable connection is Ethernet. I have connected W5500 via SPI and have that working (DHCP,…test site request [explicitly coded commands] etc.). However, if I try to use that interface for any other comm (like with wifi…simply connect and go)…nothing goes through.

So what I am after is:

Has anyone done such scenario where ALL traffic is redirected to Ethernet and how to go about it?
If not, what would be the best way to go about it/ideas/approaches/considerations?
Can you point me to implementations/code/what do do here or how to code this?
For reference…ESP32 Wrover-IE, PlatformIO and Arduino.

Many thanks for your time/help/suggestions/consideration!!

@CIPop
Copy link
Member

CIPop commented Aug 24, 2023

using Azure SDK for C

Is this the correct repository then? The Azure SDK for Embedded C is at https://github.com/Azure/azure-sdk-for-c
We don't recommend using the code within this repo for ESP32 or other constrained devices.

Has anyone done such scenario where ALL traffic is redirected to Ethernet and how to go about it?

We ethernet samples but, unfortunately, not with ESP.

  1. Using Azure RTOS ThreadX: https://github.com/azure-rtos/samples/ (using NXSecure's TLS and TCP/IP stack)
  2. Using FreeRTOS : https://github.com/Azure-Samples/iot-middleware-freertos-samples (using mBedTLS for TLS and LwIP for the TCP/IP stack)

In both cases, the NXP RT1060 or Renesas CK-RX64N use Ethernet using the NXSecure layer and drivers.

Similarly, for ESP you would need to use ESP32-IDF in conjunction with W5500 (looks like there is an example here).

It would be important to ensure the integration works with higher layer network stack components such as ESP-TLS and ESP-MQTT. If all that works as expected, you could start from one of our Arduino samples: https://github.com/Azure/azure-sdk-for-c-arduino

@CIPop CIPop closed this as completed Aug 24, 2023
@codehampster
Copy link
Author

Many thanks. Really appreciate your help. Great place to start

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants