In this project, we’re making a 3D printed LED hockey puck.

This was inspired by the DIY indoor hockey project by Yuksel Timez.

This hockey puck lights up and makes chips tunes based on motion!

You get a light show each time you hit the hockey puck, so it's still super fun even when you miss a goal.

 

Either the Circuit Playground Express or the Circuit Playground Bluefruit make this a fun and easy project that uses the built-in motion sensor and NeoPixel LEDs.

The case was 3D printed in NinjaFlex filament which lets you use the buttons to switch between different animations.

With MakeCode for the Circuit Playground Express or MakeCode Maker, we were able to quickly make this demo.

MakeCode an easy to use block based code editor that's great if you're just getting started.

Parts

Select either the Circuit Playground Express or the Circuit Playground Bluefruit.

Circuit Playground Express
Circuit Playground Express is the next step towards a perfect introduction to electronics and programming. We've taken the original Circuit Playground Classic and...
$24.95
In Stock
Circuit Playground Bluefruit - Bluetooth Low Energy
Circuit Playground Bluefruit is our third board in the Circuit Playground series, another step towards a perfect introduction to electronics and programming. We've...
$24.95
In Stock
Adafruit Micro-Lipo Charger for LiPoly Batt with USB Type C Jack
Oh so handy, this little lipo charger is so small and easy to use you can keep it on your desk or mount it easily into any project! Simply plug it via any USB C cable into a USB port...
$5.95
In Stock
Lithium Ion Polymer Battery with Short Cable - 3.7V 420mAh
Lithium ion polymer (also known as 'lipo' or 'lipoly') batteries are thin, light and powerful. The output ranges from 4.2V when completely charged to 3.7V. This battery...
$6.95
In Stock
Fully Reversible Pink/Purple USB A to micro B Cable - 1m long
This cable is not only super-fashionable, with a woven pink and purple Blinka-like pattern, it's also fully reversible! That's right, you will save seconds a day by...
Out of Stock

  

4 x M3 x 12mm
M3-0.50 x 12M
1 x 7/8 Dowel
7/8 Dowel

Parts List

STL files for 3D printing are oriented to print "as-is" on FDM style machines. Parts are designed to 3D print without any support material. Original design source may be downloaded using the links below.

  • puck-cover.stl
  • puck-btm.stl
  • hockey-blade.stl

Slicing Parts

Hockey Blade
Slice the Blade part with settings for PETG material. The parts were sliced using CURA using the slice settings below.

PETG filament
230c extruder
0.2 layer height
30% gyroid infill
70c heated bed

Circuit Playground Puck Case
Slice the Case parts with settings for TPU 98a material. The parts were sliced using CURA using the slice settings below.

TPU 98a filament
230c extruder
0.2 layer height
30% gyroid infill
50c heated bed

MakeCode for Adafruit Boards


MakeCode is an easy-to-use block-based programming editor that runs in the Google Chrome web browser. It’s has an intuitive interface and features lots of examples and demos.

LED Hockey Puck Code

If you are using the Circuit Playground Express, which uses https://makecode.adafruit.com, click the button below.

If you are using the Circuit Playground Bluefruit, which uses https://maker.makecode.com/, click the button below.

Pair Device and Upload

Once you have the MakeCode program open, click the edit button on the top right to open it in a new MakeCode project.

The code blocks and simulator will be ready to modify. Let's get the device paired with WebUSB.

  1. Click on the Gear icon, at the top right.
  2. Select Pair Device from the dropdown.
  3. For the Circuit Playground Express, Click on CPlay Express and Connect. For the Circuit Playground Bluefruit, click your device and click Pair Device.
  4. Click the big blue Download button to upload the code.

MakeCode Blocks

on start

if true then

  • while true do show animation (rainbow)

if button B is pressed then

while true do

  • show animation (purple fireball) for 2ms

else if

  • button A is pressed then
    • stop all animations 
    • while button A is press do
      • show animation (blue chase) for 5000ms

on button A click

  • stop all animations
  • While button A was pressed do
    • show animation (blue chase color) for 5000 ms

on face down

stop all animations

  • run in parallel
    • show animation (red orange color) for 5000 ms
    • play melody (falling)

on 2g (step)

  • play sound (pew pew)
  • stop all animation
  • show animation (sparkle)

on button A+B click

  • reset

Place Lipo Battery


Orient the battery so the wire connections are facing down.


Align Circuit Playground


The battery port aligns with the flaps on the case.

Attach screws


Align the flaps on both parts of the case and fasten four M3x12mm screws to each standoff.

 

Plug in Battery


Pull the lid flaps back to plug in and to disconnect the battery to the Circuit Playground.

To close the port opening, push the larger flap behind the shorter flap.

Charging the Battery

The battery connector can reach out of case and plug into a USB lipo charger to recharge the battery.

Hockey Blade

 

The hockey blade press fits into a 7/8 diameter dowel.

Use an M3 screw to further secure the blade.

This guide was first published on Dec 23, 2020. It was last updated on Dec 23, 2020.