In this interactive Arduino project, we simulate a bouncing green ball on a full-color ST7789 170×320 LCD screen, controlled entirely by the motion of an MPU6050 gyroscope. As you tilt the sensor, the ball moves with realistic physics, including velocity, damping, bouncing, and spin effects.
This is a perfect mini-game or user interface element for embedded systems, handheld devices, or motion-based controls.
PCBWay offers high-quality PCB prototyping and assembly at an affordable price, starting at just $5 for 5 PCBs. With fast turnaround, great customer support, and easy online ordering, it’s a top choice for hobbyists and professionals alike.
The project reads gyroscope data from the MPU6050 and uses it to move a virtual ball on the ST7789 display. The ball responds to tilt with acceleration and velocity, bounces off screen edges, and spins.
Key Features:
Realistic physics: damping, bouncing, velocity
Gyro-based control: intuitive movement with tilting
Efficient screen updates: erase old position, then draw new.
delay(16);
Aims for 60 FPS animation (1000ms / 60 ≈ 16.6ms per frame).
Conclusion
This project combines physics, sensor data, and graphics into a fun, responsive animation. Perfect for learning about real-time input-output systems, game loops, and embedded UI!
You May Also Like
Introduction We live in a modern era where we use mobile devices as music players, news sources, podcast listeners, etc. But, in the past, everyone listened to their local FM radio station for the latest ... Read moreRead more
Introduction An RGB LED is a light-emitting diode that can produce a range of colors by combining the outputs of red, green, and blue LEDs. Using an Arduino UNO, you can control the intensity of ... Read moreRead more
Introduction The integration of a DHT11 temperature and humidity sensor with a 16×2 LCD display presents a unique opportunity to explore the realm of IoT and home automation. This project brings together the functionality of ... Read moreRead more
In this project, we will build a compact and accurate laser distance meter using an Arduino Uno, a VL53L0X Time-of-Flight (ToF) laser ranging sensor, and a 0.96″ OLED SSD1306 display. The device will measure and ... Read moreRead more
Dark dark-activated LED circuit using SCR is a simple and interesting project, it will turn on the LED when there’s darkness around the LDR, and SCR is used here for switching purposes. SCR (Silicon Controlled ... Read moreRead more
Introduction These days, there are so many gases around us, some of which are quite dangerous. Hence, it is, therefore, absolutely necessary to identify or monitor certain gases. and, here comes the gas sensor. There ... Read moreRead more
Introduction Lights that switch on and off automatically serve several purposes, including convenience. The automatic off-switching circuit can be created in a variety of methods, but it can be a little difficult to make it ... Read moreRead more
Introduction An HC-SR04 analog thresholds controlled SG51R servo motor using an Arduino UNO is an electronic system that uses a combination of an HC-SR04 ultrasonic distance sensor, an SG51R servo motor, and an Arduino UNO ... Read moreRead more