You are on page 1of 1

https://www.theengineeringprojects.com/2016/04/send-sms-sim900d-proteus-isis.

html

https://www.theengineeringprojects.com/2014/06/send-sms-with-arduino-uno-and-
sim900d-using-at-commands.html

https://www.theengineeringprojects.com/product/home-automation-project-using-
arduino

int LED = 13;


void setup() {
Serial.begin(9600);
pinMode(LED,OUTPUT);
}

char rx_byte = 0;

void loop() {
if (Serial.available() > 0)
{ // is a character available?
rx_byte = Serial.read(); // get the character

// chek if a number was received


if (rx_byte == '1') {
Serial.print("LED is ON \n");
//Serial.println((rx_byte);
digitalWrite(LED,HIGH);
}
else {
Serial.println("LED is OFF ");
digitalWrite(LED,LOW);
}
} // end: if (Serial.available() > 0)
}

You might also like