Размер видео: 1280 X 720853 X 480640 X 360
Показать панель управления
Автовоспроизведение
Автоповтор
Pure genius.
hilarious :)
þetta er án efa eitt uppáhalds íslenska comedy mómentinu mínu.
const int buzzer = 9;void setup() { pinMode(buzzer, OUTPUT);}void loop() { tone(buzzer, 1000); delay(1000); noTone(buzzer); delay(1000); }
😅😅
const int PIN_TO_SENSOR = 2; int pinStateCurrent = LOW;int pinStatePrevious = LOW;void setup() { Serial.begin(9600); pinMode(PIN_TO_SENSOR, INPUT);}void loop() { pinStatePrevious = pinStateCurrent; pinStateCurrent = digitalRead(PIN_TO_SENSOR); if (pinStatePrevious == LOW && pinStateCurrent == HIGH) { Serial.println("Motion detected!"); // TODO: turn on alarm, light or activate a device ... here } else if (pinStatePrevious == HIGH && pinStateCurrent == LOW) { Serial.println("Motion stopped!"); // TODO: turn off alarm, light or deactivate a device ... here }}
Hverslags furðustrandatunga er þetta eiginlega?
Er þetta fyrir Arduino eða?
Pure genius.
hilarious :)
þetta er án efa eitt uppáhalds íslenska comedy mómentinu mínu.
const int buzzer = 9;
void setup() {
pinMode(buzzer, OUTPUT);
}
void loop() {
tone(buzzer, 1000);
delay(1000);
noTone(buzzer);
delay(1000);
}
😅😅
const int PIN_TO_SENSOR = 2;
int pinStateCurrent = LOW;
int pinStatePrevious = LOW;
void setup() {
Serial.begin(9600);
pinMode(PIN_TO_SENSOR, INPUT);
}
void loop() {
pinStatePrevious = pinStateCurrent;
pinStateCurrent = digitalRead(PIN_TO_SENSOR);
if (pinStatePrevious == LOW && pinStateCurrent == HIGH) {
Serial.println("Motion detected!");
// TODO: turn on alarm, light or activate a device ... here
}
else if (pinStatePrevious == HIGH && pinStateCurrent == LOW) {
Serial.println("Motion stopped!");
// TODO: turn off alarm, light or deactivate a device ... here
}
}
Hverslags furðustrandatunga er þetta eiginlega?
Er þetta fyrir Arduino eða?