Build a “Help is on the way!” DIY location-aware appliance with Mapbox APIs, Arduino and Raspberry Pi
Featured speakers
Featured host
Overview
COVID-19 shelter-in-place orders left Mapbox Policy Lead Tom Lee, his wife, and his sister-in-law with three children to manage. Combining their households made working from home possible, but the morning minutes before sister-in-law’s arrival were often frantic. So he dusted off some hardware and re-wrote some open source software to build a hands-free in-home alert system to signal when the family car was approaching home – and childcare support was on the way!
When the family car is moving, a light turns on, and an antique electrical meter points to 30...20...10 to show the estimated minutes until the driver arrives. This DIY appliance helps his household manage childcare routines like clockwork.
Tom will discuss the ins and outs of physical computing, microcontrollers and using Mapbox APIs for ambient displays. He will not discuss whether using precious evening hours to sleep instead of code would have been better for his and his family’s sanity.
Materials:
- Arduino micro-controllers (ATMega328P & ESP8266 based)
- Raspberry Pi computers (gen 1 & 3)
- Dongle device in car (with SIM card and cellular service)
- Light device with bulb & solid state relay
- Antique electrical meter (if you’re that steampunk)
You’ll learn how to...
- Adapt existing Traccar software to track an object’s movement
- Use the Geocoding API to detect device movement
- Use the Directions API to retrieve driver ETAs
- Use the Static Images API to generate map images “Your car is parked here” mobile push notifications
Code-along resources
- Tom Lee's Traccar Event Handler repository on GitHub
- Tom Lee's Steph's Bus Meter repository on GitHub
- Documentation for Mapbox Geocoding API & Reverse-geocoding
- Documentation for Mapbox Static Images API & Marker overlay
- Documentation for Mapbox Directions API
Additional Links
- Follow Tom Lee @tjl on Twitter
- Maki icons library from Mapbox
- Mosquitto lightweight open source message broker)
- SinoTrack device
- Vintage voltmeters on eBay: Link 1 & Link 2