Raspberry Pi 5-Powered Magic Mirror Can Play Retro Games Too

Running on a 65" touchscreen, this magic mirror shows the weather, calendar events, and more while allowing for the occasional video game.

Mirror, mirror on the wall

Mirrors are an integral part of our daily routines, as we stare at them in the morning to get ready and also throughout the day. And with the advent of inexpensive, yet high resolution, displays, turning them digital has never been easier. Magic mirrors are typically meant to be read-only with limited options for interactivity, but element14 Presents host David Edwards wanted his version to support not just a touchscreen, but also be able to play retro video game titles on a whim.

Driving the screen

Due to the screen's large resolution, Edwards needed a computer that was both small enough to hide behind the display while simultaneously providing the maximum possible performance in both gaming and mirror modes. So in addition to a Raspberry Pi 5, he had to include an external 27W power supply and an RS232 cable/logic-level converter for sending commands to the screen. Controllers for playing games can be connected directly to the Pi through either USB or Bluetooth Low-Energy.

Saving power

With everything powered on, the entire system draws about 200W, which is much more than desired, especially when considering that the mirror will remain unused throughout most of the day. Therefore, Edwards connected a passive infrared (PIR) sensor to one of the Pi's digital IO pins and created a small Python script which reads its value. If the sensor hasn't detected anyone in its field-of-view within a set amount of time, the Pi sends a signal over RS232 to the screen to make it enter a lower-power mode. Otherwise, a detection will send another command to quickly switch the display back on. Going beyond just the sensor, there is a cron job running in the background that automatically turns off the display overnight to save even more power.

Smart mirror features

Edwards was able to transform his 65" touchscreen into a mirror-like surface with a simple adhesive-backed film that allows light to pass through it in one direction. After this was done and the screen had been mounted to the wall, he installed the Magic Mirror application within Raspberry Pi OS which gave him many configurable options for what gets shown. Among other widgets, there is a clock, calendar feed, news feed, weather, and several more alterable modules.

Gaming

On the gaming side of things, Edwards installed PINN to handle the switch between booting into Raspberry Pi OS that runs Magic Mirror and RetroPie that emulates game ROMs for a wide variety of consoles. Although he was unable to get the correct orientation for his screen, RetroPie still ran great and could read inputs from the arcade controller.

Evan Rust
IoT, web, and embedded systems enthusiast. Contact me for product reviews or custom project requests.
Latest articles
Sponsored articles
Related articles
Get our weekly newsletter when you join Hackster.
Latest articles
Read more
Related articles