Home Creators Posts Import Register Favorites Logout

Content

With Hallow'een only a couple of weeks away, I thought I'd do a tutorial on how to make this "haunted magic mirror" prop, which shows dripping blood and a spooky message over the normal reflection when activated. 

The mirror is actually a monitor with a partially-reflective mirror film (80% used in this case) placed on top of the glass, which is showing a full-screen animation from a Unity application running on a PC. When the monitor display is black, the screen behaves like a mirror. When an image is displayed on the monitor, it appears combined with the reflected image. 

The application is controlled by the keyboard keys 'A' and 'Z', which start and stop the animation. However, the most interesting thing about this project is that those keyboard strokes can be initiated by an Arduino, which is triggered by, say a PIR sensor or pressure pad when someone stands close to the mirror. The characters 'A' and 'Z' are sent using Arduino's Serial.PrintLn() command. However, instead of being displayed on the Arduino IDE Serial Monitor, they are intercepted by a custom Serial Keyboard Mapper application, which sends the characters received as keystrokes to any active Windows application - so, by sending the appropriate hotkeys from your Arduino sketch, you could control a media player, a powerpoint slideshow, or any other application from a sensor input.

I'll be putting the Serial Keystroke Mapper application and the Unity application itself up in a separate resources post for Patrons-only shortly.

Hope you guys like this project, and please let me know if you have any comments or questions!

Files

Make a Spooky Haunted Mirror

With Hallow'een only a couple of weeks away, I thought I'd do a tutorial on how to make this haunted magic mirror which, when activated, shows dripping blood and a spooky message overlaid on the normal reflection. The mirror is actually a monitor with a partially-reflective mirror film (80% used in this case) placed on top of the glass, which is showing a full-screen animation from a Unity application running on a PC. When the monitor display is black, the screen behaves like a mirror. When an image is displayed on the monitor, it is superimposed on top of the reflected image. The application is controlled by the keyboard keys 'A' and 'Z' to start and stop the animation. However, the most interesting thing about this project is that those keyboard strokes can be initiated by an Arduino, which is triggered by, say a PIR sensor or pressure pad when someone stands close to the mirror. The characters 'A' and 'Z' are sent using Arduino's Serial.PrintLn() command. However, instead of being displayed on the Arduino IDE Serial Monitor, they are intercepted by a custom Serial Keyboard Mapper application, which sends the characters received as keystrokes to any active Windows application - so, by sending the appropriate hotkeys from your Arduino sketch, you could control a media player, a powerpoint slideshow, or any other application. More details on my Patreon page: https://www.patreon.com/playfultech

Comments

Danielle Jackson

Have you thought about using a Raspberry Pi to do thins instead of needing a PC to run the application?

Abraham Ivie

Hi Alastair, I was wondering if there is an easy way to send an "enter" command instead of an "a" or a "z" and have your Serial Mapper implement the actual "enter" command (as opposed to typing the word "enter"). Thanks!