GithubHelp home page GithubHelp logo

iot-embed-engeneering-labs / arduino-ledsaber Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jedijeremy/arduino-ledsaber

0.0 0.0 0.0 21 KB

LED Saber Code - AndiG release

Arduino 14.25% C 32.95% C++ 52.80%

arduino-ledsaber's Introduction

arduino-ledsaber

LED Saber Code - AndiG release

This is the latest firmware for my LED Saber project, documented here:

https://www.allaboutcircuits.com/projects/how-to-build-the-brightest-led-saber-in-the-world/

AndiG version features:

This version is greatly improved from the original code:

  • Button "click" to ignite.
  • Long-press to retract blade.
  • Settings stored to flash, so the saber remembers it's configuration. (rather than resetting on power-cycle)
  • Added "echo" to the swing audio effect, and a new tunable option
  • Added a brightness option
  • rearranged the blade menu and made it more visible.
  • Decreased "screesaver" idle timeout to 30 seconds.

Blade Menu:

Counting from the hilt, the following options can be changed on the fly. Options are saved to flash when the blade is retracted.

  • White : extension speed (also ignite and retract)
  • White : sound volume
  • Purple : presets (eight pre-programmed sets of options)
  • Green : blade brightness
  • Blue : blade hue
  • Blue : blade saturation
  • Yellow : buzz frequency
  • Orange : hum1 frequency
  • Orange : hum2 frequency
  • Red : hum doppler shift
  • Red : hum echo decay
  • Black : no action (so accidentally bumping the knob does nothing)

Bugfixes:

I found a major bug in the original code; the accellerometer wasn't being initialized correctly (just the gyro) and on SOME boards that was leading to a strange-sounding "bouncing" noise if the sensitivity was randomly set at maximum. (also, this was preventing the "screensaver" from activating)

The following code was added to the MPU6050_start() routine in mpu6050.h:

  write_packet(I2C_MPU6050, 0x1C, 0b11101000); // Accel Configuration AFS_SEL = 1
  delay(20);

Why is it called the "AndiG" version? This version was shipped in a specific set of sabers. To be revealed later, perhaps.

arduino-ledsaber's People

Contributors

jedijeremy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.