Halloween Safety Tracking Basket
Every Halloween my street fills with hundreds of kids in masks and dark costumes, and every year some parent ends up yelling a name down the block. We wanted a better way to keep track of a trick-or-treater without giving a young kid a phone.
TrickTrack has three parts:
- The pumpkin basket. A 3D-printed candy pumpkin with an ESP32-S3, a GPS module, a compass and a ring of orange LEDs hidden in the rim. The LEDs point back toward the parent, so the kid can find their way back too. A HELP button on the side lets them notify you (Please explain to your kid that ‘I want more candy’ is not an emergency).
- The belt unit. A small box clipped to the parent's belt. It measures the distance to the basket with Wi-Fi time of flight and GPS, and it beeps if the basket goes too far, the signal is lost, or the kid presses HELP.
- A phone web app. It connects to the belt unit over Bluetooth and shows how far away the basket is, an arrow pointing at it, and a map. Under about 30 m it switches to a "warmer / colder" circle, because GPS isn't accurate enough up close.
No cellular plan, no subscription, and no app store (unless you have an iphone): the two boards talk directly to each other over long-range Wi-Fi. The parts cost about $40 per unit, and all the code and 3D files are free.
Below are videos of the device in action
Supplies
Tools Required
- Computer with up to date Arduino IDE
- a 3d printer with at least 12"x12" print bed (we used a X1C)
- soldering tools
- screwdriver + 1/4 inch screws (8-32)
- hot glue gun
- a great mindset (the most important)
- wire cutters
- Data transfer USB-C cable
Electronics: pumpkin basket
- 1 x ESP32-S3-DevKitC-1 (N16R8) board
- 1 x GPS module with patch antenna, (ATGM336H or u-blox NEO-6M)
- 1 x GY-271 compass module (QMC5883L)
- WS2812B LED strip, 60 LEDs/m, abou t 50 cm (~28 LEDs)
- 1 x SFM-27-11 active buzzer (3-24 V)
- 1 x keyboard mechanical switch (the HELP button)
- 1 x 330 ohm resistor (optional)
- 1 x small USB power bank (about 5000 mAh) + a USB-C cable
- 1 x 8 inch basket handle
Electronics: parent belt unit
- 1 x ESP32-S3-DevKitC-1 (N16R8) board
- 1 x SFM-27 active buzzer
- 1 x 6 mm push button (optional; the board's BOOT button does the same job)
- 1 x 18650 battery
- 1 x 18650 shield
Important
- Make sure the ESP has an antenna. Models like the ESP-32-C3 will not work due to their microscopic onboard antenna.
Other
- Hookup wire (26-28 AWG) and Dupont jumper wires
- Heat-shrink tubing, hot glue, double-sided foam tape
- VEX 8-32 screws and nuts
- PLA in orange, white, and clear tangerine PETG for the LED diffuser
- Android Phone or iPhone with bluefy browser
How It Works
- Distance:
- the belt unit measures how long a Wi-Fi signal takes to reach the basket and come back (Wi-Fi "time of flight", called FTM). The basket also sends its GPS position, and the phone app uses the phone's own GPS to work out the distance. GPS wins whenever both have a fix. Within ~20m, the GPS and Wi-Fi distance is ±5m. Note: our first C3 boards lost signal at 15 m, so we switched to S3s; Wi-Fi distance overread when the signal was weak, so the alarm now trusts GPS first.
- Direction:
- the phone app compares the basket's GPS position with the phone's GPS and compass and draws an arrow. Under about 30 m GPS isn't accurate enough, so the app switches to a "warmer / colder" circle. On the app, there is also a map (similar to google maps) to see where the child is located.
- Pointing home:
- the basket knows where the parent is (the phone sends its position through the belt unit), so its LED ring lights the LEDs that face the parent. It uses math and the GPS position of the parent (phone compass) and bucket (GPS) to determine the appropriate heading between the basket and parent.
- Alarms:
- if the basket goes past the distance limit, the signal is lost for 10 s, or the child presses HELP, the belt unit beeps and the phone shows an alert. One press of the belt button silences it (or the phone app).
Print the Pumpkin and the Belt Box
- Print the bowl and base in orange PLA, the stem and handle in any color, and the LED diffuser ring in clear tangerine PETG so the light glows evenly.
- Settings we used: 0.2 mm layers, 15% gyroid infill, 3 walls, supports only where the slicer asks for them.
- The parts are held together with VEX 8-32 screws, so you can open the basket to charge it.
All files are below, and can be instantly printed
Set Up the Arduino IDE
- Install Arduino IDE 2.x from arduino.cc.
- In File > Preferences, add this to Additional boards manager URLs: https://espressif.github.io/arduino-esp32/package_esp32_index.json
- In Boards Manager, install esp32 by Espressif Systems version 3.3.12.
- In the Tools menu pick: Board ESP32S3 Dev Module, USB CDC On Boot Enabled, Flash Size 16MB, PSRAM OPI PSRAM, Partition Scheme Huge APP.
- Plug the USB cable into the board's port labelled USB (not UART).
No extra libraries are needed: each sketch is a single file.
If your board keeps rebooting with "XMC flash startup fail": some S3 boards ship with a flash chip that the stock bootloader rejects. We fixed it with a patched bootloader; put the bootloader.bin from our repo next to the .ino file in the sketch folder before uploading.
Upload the Code
- Download the code from Supplies and unzip it.
- Plug in the first board, open firmware/basket/basket.ino and click Upload. Put a piece of tape on it that says BASKET. (it will take about 10-20 minutes to upload)
- Plug in the second board, open firmware/parent/parent.ino and upload it. Label it PARENT. (it too... will take a long time to upload)
- Open Tools > Serial Monitor at 115200 baud with Newline. Type status. Within a few seconds the parent should report the basket and a distance.
If an upload fails, hold BOOT, tap RESET, let go of BOOT, and upload again.
Perfect time to eat some of the candy you’re supposedly saving for trick-or-treaters.
Wire the Pumpkin Basket
GPS module
- VCC → 3V3
- GND → GND
- TX → GPIO18
Compass (GY-271)
- VCC → 3V3
- GND → GND
- SDA → GPIO6
- SCL → GPIO7
LED strip (WS2812B, 28 LEDs)
- 5V → 5V
- GND → GND
- DIN → GPIO5 (through a 330 Ω resistor)
Buzzer (SFM-27)
- Red → GPIO21
- Black → GND
HELP button
- One leg → GPIO4
- Other leg → GND
Power bank
- Plug into the board’s port marked USB (or use the 5V pin, never 3V3)
Wire the Belt Unit
- Buzzer red wire to GPIO21, black to GND.
- Optional outside button from GPIO10 to GND. It does the same as the board's BOOT button.
- 18650 shield connecting to the 5v and GND pin
One button press while an alarm is sounding silences it. With no alarm, a press lets a new phone pair for 60 s.
Assemble the Basket
- Stick the LED strip into the rim channel with LED 0 at the front, arrows running clockwise seen from above.
- Snap the tangerine diffuser over it.
- Mount the compass flat, the GPS face-up, and the HELP button through its hole.
- Put the board and power bank in the base, run the wires up the channel, and close it with the screws.
Setting Up the Phone App
- go to the website "edd-gamma-gamma.netlify.app"
- on an android, click the three buttons on the top right, and click add to home screen
- Click on the app (on the homescreen) and it works!
Calibrate
- ring leds 28: tells the basket how many LEDs your strip has. (replace 28 with how many numbers of leds you have)
- cal compass (basket): slowly turn the basket through every direction for 25 s, outdoors, away from metal. And yes, you will be looking weird for spinning a pumpkin around in your driveway.
- ring north (basket): the ring should point north; check with a phone compass.
- ring shift 3: shifts the "north" 3 leds clock wise, negative number shifts it CCW
- cal ftm 10 (belt unit): with the two units exactly 10 m apart outdoors.
- limit 30 (belt unit): the "too far" distance in meters. We recommend 20 m or more.
Go Trick-or-Treating!
Switch on the basket first, then the belt unit, then open the app. Set your limit, hand over the pumpkin, and let them go.
This is a helper, not a safety device: keep the "signal lost" alarm on and keep an eye on your kids.
If you build one, please post a photo in the comments. Happy Halloween! (We’re a few days late. Consider this a head start on 2027.))