Introduction: Special Halloween Decoration -- Magic Mirror

I did a magic mirror as a special Halloween decoration. It is very interesting. You can speak anything to the mirror, any question or any small secret. After a while, the answer will show up in the mirror. It is a magic. hahah.....Children like it so much.

It is not complicated. I made it with Raspberry Pi and ReSpeaker 4 Mic Linear Array to add voice interface to a Magic Mirror. It is really a good sensor to do voice related projects. The link is as below.


Raspberry Pi wiki

I am happy to share my experience to you for some more fun in your halloween party.

Step 1: Materials Preparation


Raspberry Pi 3B

ReSpeaker 4 Mic Linear Array(sound card)

HDMI display

two way mirror


SD card

Ready to Go!!!

Step 2: Hand-made Frame

1) Choose your screen. It can be an older monitor. You may have noticed I said screen and monitor. That’s because you will be taking apart the monitor to just get the screen and electronics out.

2) Measure the screen and the electronics, including length, width, and height.

3) Create your frame. You may need some wood and machine to do it by yourself. Believe me. It is not difficult and you will enjoy the work.

Step 3: Hardware and PCB Connection and Assembly

How to make a general mirror become a magic one? Now the key comes. You need some hardware and PCBs. Don't worry. There are many shops we can buy them.

I use Raspberry Pi 3B and a ReSpeaker 4 Mic Linear Array to add voice interface. As using a 4 Mic Linear Array, we are able to detect sound Direction of Arrial (DOA) which can be used to provide some creative functions. We can use beamforming to enhance a specific direction’s sound. It is really a good sensor to do voice related projects.

Now you need to connect them together following the official guidance. The wiki includes a stepbystep guide. You can just download it and follow it. The link is as below.


Step 4: Software Modules

Yes, it is true you may need some software work to get the magic. This work may be some kind of technical and you need some knowledge. But don't give up. You need some efforts to get the magic. :)

I give more detailed steps. It can help you always in the right direction.

1)Setup Raspberry Pi

Download a customized pi image, which includes the sound card’s driver and some voice related packages (Do not use the lite version for we need desktop environment to show GUI). We can write the image to a SD card with rufus (very tiny but only for windows) or ether. If you don’t have any extra keyboard to access and configure the Raspberry Pi, you can setup WiFi configuration and enable SSH before first time boot. To do that, Juse add a file named ssh to the boot partition of the SD card, which enables SSH, and then create a file named wpa_supplicant.conf with the following content, replace ssid and psk with yours
country=GB<br>ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev 
ssid="WiFi SSID" 
psk="password" } 

Power on your Pi, use Pi’s IP or raspberry.local(requires mDNS support, need to install Bonjour on Windows) to login via ssh (On Windows, putty is a handy ssh client).

2)Install Magic Mirror

To install Magic Mirror software package, just run:

This command will clone MagicMirror repository from github to ~/MagicMirror, install node, npm and other dependencies.
Note: Do not use apt install to install node and npm, node and npm in the deb repository is kind of outdated. Remove them if already installed.

3)Install Magic Mirror modules: MMM-Remote-Control and MMM-kalliope

cd ~/MagicMirror/modules<br>git clone
git clone
cd MMM-Remote-Control
npm install

and then add the configuration of MMM-Remote-Control and MMM-kalliope to moddules of ~/MagicMirror/config/config.js

{<br>    module: "MMM-kalliope",
    position: "upper_third",
    config: {
        title: "",
        max: 1
    module: 'MMM-Remote-Control'
    // uncomment the following line to show the URL of the remote control on the mirror
    // , position: 'bottom_left'
    // you can hide this module afterwards from the remote control itself

restart MagicMirror to enable the new configuration. Use the following command to test if we can send a message to MagicMirror
curl -H "Content-Type: application/json" -X POST -d '{"notification":"KALLIOPE", "payload": "my message"}' http://localhost:8080/kalliope

4)Configure Weather module

By default, a weather module using OpenWeatherMap is included, we need sign up OpenWeatherMap to get a API key and fill the key to ~/MagicMirror/config/config.js

5)Set Google Assistant

Go to Introduction to the Google Assistant Library to install and setup Google Assistant Library After authorization, we can just run to start the Google Assistant for the Mirror.

Step 5: Ready! Speak to Your Mirror

OK! If you have completed all steps above, you have get a magic mirror as a very cool decoration in your halloween party. Now, you can speak to your mirror. Any question you want to know or any small secret? If you want to share your interesting work with me. I will be very happy.

Any more question, just reply and let me know.

Halloween Contest 2018

Participated in the
Halloween Contest 2018