You are on page 1of 5

Iron Man Arc Reactor

Ian
input.onGesture(Gesture.Shake, function () {
light.setAll(0x00ffff)
light.setBrightness(20)
light.showAnimation(light.sparkleAnimation, 2000)
light.stopAllAnimations()
light.setAll(0x007fff)
light.setBrightness(72)

Code
light.showAnimation(light.colorWipeAnimation, 2000)
light.stopAllAnimations()
light.setAll(0x0000ff)
light.setBrightness(255)
light.showRing(
`blue blue blue blue blue blue blue blue blue blue`
)
input.setLoudSoundThreshold(100)
music.setVolume(255)
Writing the code was a fun music.playTone(330, music.beat(BeatFraction.Whole))
music.rest(music.beat(BeatFraction.Quarter))

experience, and was one music.playTone(330, music.beat(BeatFraction.Whole))


music.playTone(494, music.beat(BeatFraction.Half))

that was easy after last


music.playTone(440, music.beat(BeatFraction.Double))
music.playTone(392, music.beat(BeatFraction.Whole))
music.playTone(370, music.beat(BeatFraction.Whole))

years coding classes. The music.playTone(330, music.beat(BeatFraction.Double))


music.rest(music.beat(BeatFraction.Quarter))

code itself was simple to music.playTone(330, music.beat(BeatFraction.Whole))


music.rest(music.beat(BeatFraction.Quarter))
music.playTone(330, music.beat(BeatFraction.Whole))
write, but combining the music.playTone(494, music.beat(BeatFraction.Half))
music.playTone(554, music.beat(BeatFraction.Whole))

online code with the music.playTone(440, music.beat(BeatFraction.Whole))


music.playTone(494, music.beat(BeatFraction.Double))

physical Adafruit was


music.setVolume(255)
music.playTone(330, music.beat(BeatFraction.Whole))
music.rest(music.beat(BeatFraction.Quarter))

difficult sometime. music.playTone(330, music.beat(BeatFraction.Whole))


music.playTone(494, music.beat(BeatFraction.Half))
music.playTone(440, music.beat(BeatFraction.Double))
music.playTone(392, music.beat(BeatFraction.Whole))
music.playTone(370, music.beat(BeatFraction.Whole))
music.playTone(330, music.beat(BeatFraction.Double))
music.rest(music.beat(BeatFraction.Quarter))
music.playTone(330, music.beat(BeatFraction.Whole))
music.rest(music.beat(BeatFraction.Quarter))
music.playTone(330, music.beat(BeatFraction.Whole))
music.playTone(494, music.beat(BeatFraction.Half))
music.playTone(554, music.beat(BeatFraction.Whole))
music.playTone(440, music.beat(BeatFraction.Whole))
music.playTone(494, music.beat(BeatFraction.Double))
})
TinkerCAD
Building the 3D render for the print
was easy and painless. The only
problem was scaling it so that the
circuit fit.
Final Project
The final product is able to perform a
light up sequence, and play the
avengers theme song. If I was to redo
the project, I would spend more time
building and designing the physical
toy, and less on the code.
Reflection
This whole project was fun from start
to finish. There were some setbacks,
including redoing the whole project to
Inspiration
fix some errors. TinkerCAD was easy
to use and it only took a class to
make. The only problem was the
scaling of the 3d print in order for the
circuit playground to fit. The code was
very easy to do using the blocks, and
refining it after with the written code
was simple. Overall, this was a very
fun project.

You might also like