arduino ethernet lib2 winthout SD/how to use pin 4?

hi,

i use an ethernet shield on a DUE but like to use pin 4 for something else.
i understand that pin 4 is used (as chip select) by the sd card on the ethernet shields

can i turn that off some how? (so i can use pin 4 for myself)
or is there another library that i can use?

for the record, i only use UDP messages.
had a quick look in the ethernet2 library/sources but couldn't find pin assignments (in the 10 minutes i looked).

regarding pin 4
https://forum.arduino.cc/index.php?topic=347658.0

all help appreciated,

by the way does anybody konw the difference between these 2 etherenet2 shields?
both are called A000024 and "ethernet shield 2"
but there are small differences

and

both have the W5500 chip
the top one doesn't have the poe headers, and next to the sd card holder are some different parts.

it seems that the top one doesn't work for me (it needs pin 4 high)
the bottom one does work, i can use pin 4

bhot55:
hi,

i use an ethernet shield on a DUE but like to use pin 4 for something else.
i understand that pin 4 is used (as chip select) by the sd card on the ethernet shields

can i turn that off some how? (so i can use pin 4 for myself)
or is there another library that i can use?

for the record, i only use UDP messages.
had a quick look in the ethernet2 library/sources but couldn't find pin assignments (in the 10 minutes i looked).

regarding pin 4
Beginners guide to Arduino Ethernet Shield 2 - Networking, Protocols, and Devices - Arduino Forum
Ethernet - Arduino Reference

all help appreciated,

if SD card is not inserted the pin is free. the SPI device is the card, not the adapter

bhot55:
by the way does anybody konw the difference between these 2 etherenet2 shields?
both are called A000024 and "ethernet shield 2"
but there are small differences

Arduino Ethernet Shield 2 — Arduino Official Store

and

https://media.digikey.com/Photos/Arduino/MFG_A000024.jpg

both have the W5500 chip
the top one doesn't have the poe headers, and next to the sd card holder are some different parts.

it seems that the top one doesn't work for me (it needs pin 4 high)
the bottom one does work, i can use pin 4

it is the same schematics, only Arduino now makes it in blue color. the turquoise one was manufactured by arduino.org

Juraj:
if SD card is not inserted the pin is free. the SPI device is the card, not the adapter

You are saying that if there is no SD card in the holder i should be able to use pin 4?
that is not the case for the blue pcb.

Juraj:
It is the same schematics, only Arduino now makes it in blue color. the turquoise one was manufactured by arduino.org

no its not.

look between the sd card holder and the connectors, one has 4 leds the other not.
near sd card holder & poe header, some parts are different
there are more differences.
its very confusing, 2 products who respond differently with same product code.

The question is, how can i use pin 4? (don't use it as chip select pin, but be free to use it as i like)

bhot55:
You are saying that if there is no SD card in the holder i should be able to use pin 4?
that is not the case for the blue pcb.

no its not.

look between the sd card holder and the connectors, one has 4 leds the other not.
near sd card holder & poe header, some parts are different
there are more differences.
its very confusing, 2 products who respond differently with same product code.

The question is, how can i use pin 4? (don't use it as chip select pin, but be free to use it as i like)

the published schematics is the same. pcb design has differences

how do you know, you can't use pin 4?

Juraj:
how do you know, you can't use pin 4?

because i tested it.

in the due code make pin 4 output and set to 0
use pc to send udp data.
With same due, only swap the ethernet shields.

one ethernet shield works fine, udp package are received and it keeps working.
with the other ethernet shield it doesn't work.
same code, same due, same pc, same udp data. only difference is the ethernet shield.

bhot55:
because i tested it.

in the due code make pin 4 output and set to 0
use pc to send udp data.
With same due, only swap the ethernet shields.

one ethernet shield works fine, udp package are received and it keeps working.
with the other ethernet shield it doesn't work.
same code, same due, same pc, same udp data. only difference is the ethernet shield.

are you sure there isn't a card in the holder?

Hi,

i made a video on what i do...

https://vimeo.com/334673332/ea471a9482

Hope somebody can point me in the right direction...

I had some code with LCD-display and old Ethernet shield without using SD card, everything worked fine, now i had original Ethernet2 shield from arduino, nothing worked - after finding this post it was clear, the lcd shield needs PIN4 for data exchange, the hardware solution is really easy - just bend pin4 out or remove it on Ethernet2 shield and everything works fine. A software solution would be better, but i didn't find one.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.