Controlled Reset of Ethernet on Arduino Ethernet

pylon:
What do you expect from the code above? Resetting the Ethernet hardware (or the SD hardware)? If so, you want get what you intended. Pin 10 is the device select line of the SPI interface for the Ethernet chip (Wiz5100), pin 4 is the same for the SD card connector. Pulling the low for 250ms won't reset the devices.

Do stuff and periodically reset the Ethernet.

Why do you want to periodically reset the Ethernet? Is your hardware defect?

Hi,

Thanks for the reply.

Essentially the sketch / device will work fine for days with no issues and then stop working, which I have tracked down to an issue with the Ethernet Chip.

I discovered that removing the Ethernet Cable , or power to the device fixes the issue. So I wanted to bring down the Ethernet chip in the code and start it again, effectively emulating a reset of the Ethernet device.