Skip to content

Details

In this fun, beginner-friendly project, you’ll build a system that uses your laptop’s webcam to detect motion and trigger a hilarious “Dino Alert!” on screen. When movement is detected, a T-Rex appears, opens its mouth, waves its tiny arms, and warns everyone nearby with a roar.
No prior experience is required. By the end, you’ll have a working Dino Alert system—and a solid foundation for building more advanced projects that combine software and electronics.

If you have a laptop, please bring it — but come anyway if you don’t!

https://phptuts.github.io/CHM/2026/April/20/index.html

code
https://duino.app/#/code

CODE:

#include
Servo myServo;
String command = "";
void setup() {
Serial.begin(115200);
myServo.attach(7);
myServo.write(90);
Serial.println("Ready. Type move");
}
void loop() {
if (Serial.available() > 0) {
command = Serial.readStringUntil('\n');
command.trim();
Serial.print("I received: [");
Serial.print(command);
Serial.println("]");
if (command == "move") {
Serial.println("Command matched. Moving servo.");
myServo.write(0);
delay(800);
myServo.write(180);
delay(800);
myServo.write(90);
} else {
Serial.println("Command did not match.");
}
}
}

Related topics

You may also like