This project is a physical data visualization system that responds to real-time data from the City of Chicago’s open data portal. It tracks the number of domestic violence victims reported per quarter, stores that number in memory, and visually communicates the count using Roman numerals on a color-coded NeoPixel LED strip. The project also includes a servo motor animation and LED flashing pattern based on whether new data has been reported.
How It Works
Hardware Setup- Particle Photon 2 (or other Particle device)
- Adafruit NeoPixel Strip (WS2812B, 10 LEDs)
- Servo Motor (used to simulate a moving part representing awareness/action)
- EEPROM to store previously recorded data between restarts
- Power Supply & Breadboard/PCB
- The device subscribes to a webhook ("hook-response/domesticVictims/0") that delivers the number of victims for the most recent quarters.
- It publishes an event ("domesticVictims") to trigger the webhook and retrieve data.
- The servo begins oscillating for 15 seconds as a visual “wake-up” animation.
- It reads the new totalVictims count.
- It retrieves the previously stored value from EEPROM.
If the count has increased:
- Store new value in EEPROM
- Display the new value as Roman numerals on the LED strip
- Stop LED flashing
If the count is the same:
- Start flashing the LED strip every 2 seconds to indicate no new data
The Roman numeral representation of the count is shown using color-coded NeoPixels, where each character maps to a unique color. It helps interpret the value in a symbolic and intuitive way.
Example:
If the number is 17, the Roman numeral is XVII and the LED strip will light up with:
- Red (X)
- Yellow (V)
- Green (I)
- Green (I)
If no change is detected in victim data since the last check:
- The LED strip flashes ON/OFF every 2 seconds to symbolize stagnation, possibly implying no new attention to the issue.
On startup, a servo oscillates between 30° and 110° for 15 seconds. This is for aesthetic purposes to serve as the fire in the fireplace of our project. After the period ends, the servo returns to a rest position.
The use of EEPROM memory allows the project to:
- Persist victim count data across reboots or power-offs.
- Detect whether the victim count has increased or remained the same.
This avoids re-triggering unnecessary updates or confusion on restarts.
APIOriginal:
https://data.cityofchicago.org/resource/gj7a-742p.json?
Filtered:
This filters for:
- Only domestic incidents
- Only from Q1 and Q2 of 2025
- Returns a sum of all victims in that range
https://drive.google.com/file/d/1smy86dPupthIEGaRCbVPdxzTiKVgtnK7/view?t=7
Comments