Hi,
I have problem with Arduino Mega and Ethernet Shield.
When I am using Arduino Mega without Ethernet Shield I can use pins from 23 to 49 as OUTPUT pins without any problem. I declare in setup HIGH state and use LOW state to control relays.
But when I connect Ethernet Shield only pins from 23 to 29 work. Pins from 30 to 49 are not.
I tried two different shilds based on W5100 and W5500 but it still does not work.
Where may be a problem?
Thanks in advance for replays.
I suggest you read the datasheets of both the Mega and the shield. Maybe even look at the schematics. I don't think I ever saw a shield that didn't use some pins of the board it was attached to.
I don't think that is the problem.
An Ethernet Shield will not even make contact with pins 23 to 49, as those pins are all on the connector that runs across the end of the Mega.
Just a question. Where does the shield in your photo connect to the SPI of the Mega? I don't see the central SPI (ICSP) header on the shield.
Just change pins, they must be reserved or something when the shield is on.
To be honest, I've never used the Ethernet Shield with a Mega - I just took it off a Uno to take a mock-up photo.
However it does have the ICSP connector - it is between the micro-SD card slot and that screw that holds the board to the baseplate.
Thank You for Your help. I solved a problem which was hidden in code. There was a bug which was changing pin numbers.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.

