thijs.gg
← Home

Topographic Transit

Topographic SF map displaying live positions of the K-line Muni train.

It's one thing to see busses and trains out on the street, or bus lines on a map. But another to see every bus or train that's out on the road. It's difficult to grasp the utility and reach of public transit, and this project hopes to show how useful public transit can be.

This project was a collaborative effort. I worked on the electronics and code behind the map, integrating them into parts done by the rest of our team! It's a proof of concept for a larger map, where every single public transit vehicle in SF would be displayed.

This map displays the live positions of the K-line (previously KT-line) train!

Timelapse of the map, with train lights moving

Transit in SF

There's often over 1,500 busses on the road in the bay area. Here's some images from the Pantograph app displaying these live positions.

Screenshot of entire SF's vehiclesScreenshot of the embarcadero's vehicles

Topographical Map

We exported topographic STL files of San Francisco from TouchTerrain, and printed them with Prusa 3D-printers. We had to split the file into four pieces to fit on the printing bed, and then glue them together with hot glue.

Small topographic test printsPrinting one quarter of the map
Side view of the topographic 3D-printed map

Adding the Lights

We messily dremmled channels for the Neopixel strip into the back of the map, allowing the lights to shine through the plastic. The lights are controlled by a Raspberry Pi, and powered by an external supply.

The circuitry connected to the raspberry piThe final electronic setup behind the map

To map lights on the strip to the transit line, I assigned an estimated latitude and longitude coordinate to each pixel. This was difficult and was definitley not precise, but worked.

Live position data is fetched from the API used to display maps on SFMTA's route pages, which I found on the Network tab of inspect element. It returns latitude and longitude coordinates of each vehicle, which which I found the nearest LED.

Blue lights are inbound, red lights are outbound. Purple lights are where both overlap.

Top view of the map lit up
Side view of the map glowing and lit up
© 2024 Thijs Simonian