Arduino Shield Question

Discussion in 'Programmer's Corner' started by brian25, Oct 1, 2013.

  1. brian25

    Thread Starter Member

    May 13, 2013
    37
    0
    hi how to use multiple shields in Arduino?

    if i have two..
    example, GSM and Ethernet can this work simultaneously in void setup?


    Code ( (Unknown Language)):
    1.  
    2. void setup(){
    3.  
    4. Serial.begin(9600);
    5.     if (gsm.begin(2400)){
    6.         Serial.println("\nstatus=READY");
    7.         started=true;
    8.     }
    9. Ethernet.begin(mac, ip);
    10. server.begin();
    11.  
    12. }
    13.  
     
  2. sirch2

    Well-Known Member

    Jan 21, 2013
    1,008
    351
    Are they using the same pins on the Arduino? You need to check what pins each shield uses on the underlying Arduino and then check if those pins support multiple devices (e.g. TWI, SPI).

    If they are straight serial connections then I suspect they won't work reliably.
     
    brian25 likes this.
Loading...