1: Simple Internet Appliance
Made by youngjol
Made by youngjol
Created: November 16th, 2021
First program: blinking LED light
int ledPin1 = D2;
int ledPin2 = D3;
void setup() {
pinMode(ledPin1, OUTPUT); // Use D2 as output pin
digitalWrite(ledPin1, LOW);
pinMode(ledPin2, OUTPUT);
digitalWrite(ledPin2, LOW);
}
void loop() {
digitalWrite(ledPin1, HIGH);
delay(1000);
digitalWrite(ledPin1, LOW);
delay(1000);
}
Click to Expand
int ledPin1 = D2;
int ledPin2 = D3;
void setup() {
pinMode(ledPin1, OUTPUT); // Use D2 as output pin
digitalWrite(ledPin1, LOW);
pinMode(ledPin2, OUTPUT);
digitalWrite(ledPin2, LOW);
}
void loop() {
digitalWrite(ledPin1, HIGH);
delay(3000);
digitalWrite(ledPin1, LOW);
delay(3000);
}
Click to Expand
int ledPin1 = D2;
int ledPin2 = D3;
void setup() {
pinMode(ledPin1, OUTPUT); // Use D2 as output pin
digitalWrite(ledPin1, LOW);
pinMode(ledPin2, OUTPUT);
digitalWrite(ledPin2, LOW);
}
void loop() {
for (int i = 1; i<6; i++){
digitalWrite(ledPin1, HIGH);
delay(500);
digitalWrite(ledPin1, LOW);
delay(500);
}
delay(3000)
}
Click to Expand
int ledPin1 = D2;
int ledPin2 = D3;
void setup() {
pinMode(ledPin1, OUTPUT); // Use D2 as output pin
digitalWrite(ledPin1, LOW);
pinMode(ledPin2, OUTPUT);
digitalWrite(ledPin2, LOW);
}
void loop() {
digitalWrite(ledPin1, HIGH);
digitalWrite(ledPin2, LOW);
delay(1000);
digitalWrite(ledPin1, LOW);
digitalWrite(ledPin2, HIGH);
delay(1000);
}
Click to Expand
The exercises were completed as instructed. There were no experiments or explorations required to complete these tasks as they required fairly simple modifications from the initial program.
In going forwards, I would like to work on the exercises for working with functions through Particle Cloud.
There isn’t much I would do differently for a similar type of assignment.