Using Arduino, Python, and AWS
The year is ~2018. I take a class at my local hackerspace, NYC Resistor. They give a little presentation about the history of IoT devices. They guide us through breadboarding our own little MTA train time arrival clocks, which behave like the ones on the ceilings at Subway stations—except it sits on your desk, or whatever. Neat!
The kit they prepare for us consists mainly of an ESP32 Arduino module (which has WiFi), a tiny OLED screen, and a bunch of great C++ code to parse the MTA’s nasty protobuf feed with the esp32's limited memory. I think Trammell Hudson had something to do with the original design.
Fast forward to 2021: The MTA’s protobuf feed spec has changed a bit, so my tiny countdown clock goes into disrepair. I’m unable to debug the Arduino GTFS parsing code on my own—not even with online support from more experienced C devs. I am still simply not a terrific C programmer, and the GTFS spec boggles my mind.
My friend, the magnificent cinematographer and general brainiac Zach Kuperstein, then points me to Jon Thornton’s repo for MTAPI, a flask app: It handles the hard parts of querying the MTA’s hard-to-use API and spits it out again as a nice new RESTful API. A gamechanger! Now our Arduino/C++ code can be really simple.
So I spin up an ec2 instance to run this Thornton-style MTAPI Flask app, and Zach writes the Arduino to query the new server and render arrival times on the little monitor. Zach even designs CAD models for 3d-printable enclosures with AutoDesk Fusion. Thanks Zach!