I recently got a WiFi shield and I want to switch it with my Ethernet shield which I used in a project. The problem I have is that the pins the WiFi shield is using somehow conflicts with the pins the lcd is using. When using the Ethernet shield, I needed to bend pin nr 10 on the lcd for it to work. Then I set up the lcd as follows:
LiquidCrystal lcd( 8, 9, 4, 5, 6, 7 );
That worked without problems, but if I do the same thing with the WiFi shield, it prints lots of strange characters instead of what I want. Some of the chars are correct, but most of them aren't. The WiFi shield uses pins 4, 10, 11, 12, 13 as far as I know and the Ethernet shield uses the same.
The LCD keypad that I'm using is one form DfRobot
And as it says on the site, the shield uses pins 4-9 (10 is not of interest), so the pin conflicting would be pin 4 which is used for the SD card on the WiFi shield which I'm currently not using.
Quite often you can’t stack one shield on top of another because they use the same pins, or the total number of pins required by both Shields is more than are available on the Arduino.
This is just a limitation with using Shields
If you can use wires to reconnect the shields to the Arduino, you may be able to get around your problem by re-assigning the pins that the Shields use, but this isn’t always possible.
BTW. You’d not stated which wifi shield you are using
so the pin conflicting would be pin 4 which is used for the SD card on the WiFi shield which I’m currently not using
Its not possible for anyone to give you a exact answer if you don’t provide all the information.
I'm sorry, I got the Arduino WiFi shield.
The WiFi shield uses pins 4, 10, 11, 12, 13 as far as I know and the Ethernet shield uses the same.
Add D7 to that list for the WiFi shield. That is the handshake pin.
I don't think it matters what WiFi shield you have, the LCD shield is the problem and you would be very unlucky if it can't be fixed there. Those shields have a full complement of pins and a lot of them are spares. You can see pins D1>7 and A1>5 all have solder points beside them thereby enabling you to run jumpers for this very purpose.
A typical example is that D4 is chipselect for SD on an Ethernet shield - no options - while you are calling it for LCD. Your option on this board is to clip D4 and run a wire from D4 to D2, or even A2, and alter the code accordingly.
I have yet see a situation where you can't stack shields, and the above is about as difficult as it gets.
Another option is to do the jumping on an intermediate proto shield, clip the relevant pin thereon, and leave the LCD shield virgo intacto.
I still haven't figured out how to solve this, can someone help?