Skip to content
Uses affordable AirBar to provide touch input to Magic Mirror
JavaScript CSS
Branch: master
Clone or download
Latest commit e9ab7a7 Nov 5, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
node_modules Initial commit Nov 5, 2019
translations Initial commit Nov 5, 2019
.eslintrc.json Initial commit Nov 5, 2019
Gruntfile.js Initial commit Nov 5, 2019
LICENSE.txt Initial commit Nov 5, 2019
MMM-AirbarHelper.js Update Nov 5, 2019
node_helper.js Initial commit Nov 5, 2019
package-lock.json Initial commit Nov 5, 2019
package.json Initial commit Nov 5, 2019
testModule.css Initial commit Nov 5, 2019


This is a module for the MagicMirror².

This allows you to use an affordable touch sensor called the AirBar to provide touch activity to a Smart Mirror.

With this you can interact with your app like this:

How to use

  1. Attach an AirBar to your Raspbery Pi. I've had luck with the with the windows version. I do not work for AirBar and in no way guarantee this step will work.
  2. In the module you would like to work with AirBar implement:
notificationReceived: function(notification, payload, sender) {
    if(notification == "AIRBARHELPER_INPUT") {
        // action you would like to have happen

I have not currently published any module that use this compatibility, but it is easy to fork an existing module or to build it into a new app. If you add the functionality to an existing app let me know and I'll link it here.

It supports the following inputs: motion = "up", "down" "right", "left", "touch", "double_touch", "hold"

Additionally the notification reports the start and end coridnates so you can interpret input yourself. The key for those fields are: "startX", "startY", "endX", "endY"

Using the module

To use this module, add the following configuration block to the modules array in the config/config.js file:

var config = {
    modules: [
	module: "MMM-AirbarHelper",
	config: {
		barPosition: 'top',
                debugMode: false

Configuration options

Option Description
barPosition Optional Describes the orientation the bar is positioned as described when facing the mirror. Options include: "bottom", "top", "left", "right"
debugMode Optional If true it displays the last input on the top left. Options include: true, false
You can’t perform that action at this time.