Hackster is hosting Hackster Holidays, Ep. 4: Livestream & Giveaway Drawing. Watch previous episodes or stream live on Wednesday!Stream Hackster Holidays, Ep. 4 on Wednesday!
Smart Creativity
Published © CC BY

Make a Music Reactive Light box || #smartcreativity

Very cool and creative LED glowing project....

BeginnerFull instructions provided1 hour446
Make a Music Reactive Light box || #smartcreativity

Things used in this project

Hardware components

Circuit Playground Express
Adafruit Circuit Playground Express
×1
USB-A to Mini-USB Cable
USB-A to Mini-USB Cable
×1

Software apps and online services

MakeCode
Microsoft MakeCode

Story

Read more

Schematics

Project

Code

Code

Scratch
 input.onLoudSound(function () {
    light.setBrightness(148)
    music.setVolume(50)
    music.siren.loop()
    light.setBrightness(152)
    light.setAll(0x00ff00)
    pause(500)
    light.setAll(0x0000ff)
    pause(1000)
    light.setAll(0x00ffff)
    pause(500)
    light.setAll(0xff0080)
    pause(2000)
    light.setAll(0xffff00)
    pause(1000)
    light.setAll(0xff9da5)
    pause(500)
    light.setAll(0xff0000)
    pause(2000)
    light.setAll(0x7f00ff)
    light.showAnimation(light.rainbowAnimation, 2400)
    pause(500)
    light.showRing(
        `green black black black red red black black black green`
    )
    pause(500)
    light.showRing(
        `green black black blue red red blue green black black`
    )
    pause(500)
    light.showRing(
        `black black green blue red red blue green black black`
    )
    pause(500)
    light.showRing(
        `black green pink blue red red blue pink green black`
    )
    pause(500)
    light.showRing(
        `yellow green pink blue red red blue pink green yellow`
    )
    light.showAnimation(light.colorWipeAnimation, 500)
    pause(500)
    light.showAnimation(light.rainbowAnimation, 2000)
})
forever(function () {

})

Credits

Smart Creativity

Smart Creativity

25 projects β€’ 36 followers
A creative student....πŸ§’πŸ§’πŸ§‘

Comments