Introduction: Slipper Shining With LED Strip & Xadow

Picture of Slipper Shining With LED Strip & Xadow


Led strips are amazing! Firewalker-led-sneakers( by Adafruit inspired me.

I wanna change a way to control it, instead of "pressure-sensitive", I use a accelerometer sensor judging the motion of slipper.

It's simple, I complete this version only calculating the acceleration on "z" axis, weather i'm speed up or slow down. Led will "flow" if I'm moving, and stop as I stop.

Step 1: Materials & Tools

Xadow main board
Xadow 3-axis
Xadow breakout
W2828 programmable RGB Led Strips(with integrated driver)
shoe and model!

There is already a 3.7V lipo battery shipped with Xadow, due  to my experience this voltage can light up a short segment of RGB Led strip, if necessary you can calculate the max length it can support based on your specific one. For me, this is a W2818 programmable RGB Led strip with integrated driver.

If you wanna a more "blink" experience, please use an external 5V DC power or make a 5V booster  by yourself.

Step 2: Connect

Picture of Connect

How to:

Xadow main board <- I2C -> Xadow 3-axis <-> Strip

There is already breakout on accelerometer sensor, so you don't have to add "Xadow breakout".

Xadow use FFC between two modules, this 12Pin cable just fix the Xadow compatible interface.

For more info, please checkout wiki

Some solder works should be done: you have to connect pins to the breakout on Xadow.

Step 3: Blink Test

Picture of Blink Test

Since this is the same as NeoPixel Digital RGB LED by adafruit, if you wanna a quick implementation of beautiful animation with it, I highly recommend the code example  by Adafruit

Deploy their library, have a try on "example"

Also deploy, try the demos related with 3-axis. I made some modification and use it on Xadow.

Step 4: Software

#include <Adafruit_NeoPixel.h>
#include <Wire.h>
#include "xadow.h"

#define ADDRACC         0x53

#define Register_ID     0
#define Register_2D     0x2D
#define Register_X0     0x32
#define Register_X1     0x33
#define Register_Y0     0x34
#define Register_Y1     0x35
#define Register_Z0     0x36
#define Register_Z1     0x37

#define PIN 15

double az1;

// Parameter 1 = number of pixels in strip
// Parameter 2 = pin number (most are valid)
// Parameter 3 = pixel type flags, add together as needed:
//   NEO_KHZ800  800 KHz bitstream (most NeoPixel products w/WS2812 LEDs)
//   NEO_KHZ400  400 KHz (classic 'v1' (not v2) FLORA pixels, WS2811 drivers)
//   NEO_GRB     Pixels are wired for GRB bitstream (most NeoPixel products)
//   NEO_RGB     Pixels are wired for RGB bitstream (v1 FLORA pixels, not v2)
Adafruit_NeoPixel strip = Adafruit_NeoPixel(14, PIN, NEO_GRB + NEO_KHZ800);

void setup() {
  cout << "init accelermeter over!" << endl;

  strip.begin();; // Initialize all pixels to 'off'

void loop() {
  double ax, ay, az2, diff, delaytime;
  readAcc(&ax, &ay, &az2);                   // get acc
  diff = abs(az1 - az2);
  az1 = az2;
  //cout << "az2 = " << az2 << '\t';
  //cout << "az1 = " << az1 << '\t';
  cout << "diff = " << diff << endl;

  // Some example procedures showing how to display to the pixels:
  //colorWipe(strip.Color(255, 0, 0), 50); // Red
  //colorWipe(strip.Color(0, 255, 0), 50); // Green
  //colorWipe(strip.Color(0, 0, 255), 50); // Blue
  diff = diff * 100;
  cout << "diff = " << diff << endl;
  delaytime = double(map(diff, 1, 250, 1000, 1))/1000;
  cout << "delay = " << delaytime << endl;

void adxl_init()
    Wire.write(8);                          //measuring enable
    Wire.endTransmission();                 // stop transmitting

unsigned char readAcc(double *Xg, double *Yg, double *Zg)
    int X_out;
    int Y_out;
    int Z_out;
    Wire.beginTransmission(ADDRACC);        // transmit to device
        int X0 =;
        int X1 =;
    Wire.beginTransmission(ADDRACC);        // transmit to device
        int Y0 =;
        int Y1 =;
    Wire.beginTransmission(ADDRACC);        // transmit to device
        int Z0 =;
        int Z1 =;

// Fill the dots one after the other with a color
void colorWipe(uint32_t c, uint8_t wait) {
  for(uint16_t i=0; i<strip.numPixels(); i++) {
      strip.setPixelColor(i, c);;

void rainbow(uint8_t wait) {
  uint16_t i, j;

  for(j=0; j<256; j++) {
    for(i=0; i<strip.numPixels(); i++) {
      strip.setPixelColor(i, Wheel((i+j) & 255));

// Slightly different, this makes the rainbow equally distributed throughout
void rainbowCycle(uint8_t wait) {
  uint16_t i, j;

  for(j=0; j<256; j+=1) { // 5 cycles of all colors on wheel
    for(i=0; i< strip.numPixels(); i++) {
      strip.setPixelColor(i, Wheel(((i * 256 / strip.numPixels()) + j) & 255));

// Input a value 0 to 255 to get a color value.
// The colours are a transition r - g - b - back to r.
uint32_t Wheel(byte WheelPos) {
  if(WheelPos < 85) {
   return strip.Color(WheelPos * 3, 255 - WheelPos * 3, 0);
  } else if(WheelPos < 170) {
   WheelPos -= 85;
   return strip.Color(255 - WheelPos * 3, 0, WheelPos * 3);
  } else {
   WheelPos -= 170;
   return strip.Color(0, WheelPos * 3, 255 - WheelPos * 3);

Step 5: Final

Picture of Final

It's simple, using double-sided adhesive to fix the strip on the slipper~.
Since is so small Xadow, you don't need extra sewing works. Just put the Xadow on your feet, sorry for the brutal idea.


zquan (author)2015-12-08

Hi, what battery beside the xadow 3.7v lipo battery are you using>?

samalert (author)2013-10-16

video would be nice !

Gabse (author)2013-10-16

A ne555 would be a lot easyer.

Izzy4302 (author)2013-10-15

That's awesome!

Saeed Nazarian (author)2013-10-15

Hi xadow, that's very nice.

About This Instructable




Bio: This is creator of Xadow modules
More by xadow:Color-Changing CatThe not so smart Xadow smartwatchSlipper Shining with LED strip & Xadow
Add instructable to: