A widget for MARTA riders
This generates a short script for your stop. It runs inside the free Scriptable app, so there's nothing else to install.
Three steps, about two minutes.
Install Scriptable
It's free, from the App Store. This is what runs your widget.
Paste your script
Open Scriptable, tap the +, and paste the script you copied above. Give it any name you'll recognize.
Add the widget
From your home screen, touch and hold an empty area, tap the +, find Scriptable, and choose the small size. Set it to run the script you just saved.
Set "When Interacting" to Run Script
Long-press the widget, tap Edit Widget, and set When Interacting to Run Script. This lets you tap the widget on your home screen to refresh the arrival time on demand, instead of waiting for the automatic refresh.
A few things to know so you know when the time on your home screen was last updated.
Widgets don't refresh continuously
iPhone widgets are not designed to fetch new data every few seconds. This widget asks iOS to refresh about every 15 minutes, but the exact timing is controlled by iOS and can vary.
Tap the widget when you want a fresh update
If the displayed time looks old, tap the widget. With When Interacting set to Run Script, Scriptable can run the script when you interact with the widget instead of waiting for the next automatic refresh.
"Last refreshed" tells you when the data was fetched
The Last refreshed time is the most recent time this widget successfully fetched arrival data from the service. It helps you judge how old the displayed arrival times might be.
Arrival times are not countdowns
The widget displays the arrival time MARTA provides rather than continuously counting down to the train. The displayed time can therefore become stale until the widget refreshes again.
Building a native iPhone widget requires a Mac and Apple's developer tools, and distributing an app means an Apple Developer account and App Store review. I built this as a side project without those, so I used Scriptable, a free app that lets small scripts run as home screen widgets. The tradeoff is a few extra setup steps for you. The upside is that the whole thing is a short script you can read before you run it.
No. Scriptable is only available for iPhone and iPad, and the script it runs is written for it, so this widget is iOS only.
Just MARTA rail: the Red, Gold, Blue, and Green lines. Buses and the streetcar are not included.
Yes. Each widget shows one station, line, and direction, so generate a script for each one you want. Save each as its own script in Scriptable, then add another Scriptable widget to your home screen and point it at that script.
The widget reached MARTA's data fine, but there are no upcoming arrivals listed for that station, line, and direction right now. That's common late at night or when service has ended for the day. It's different from “Can't load data”, which means the widget couldn't reach the service at all. In that case, tap the widget to try again.
The widget uses MARTA's public real-time data, which can run a few minutes behind what the station signs show. The widget also only updates when it refreshes, so the time on your home screen is as of the “Last refreshed” time shown on it. If it looks old, tap the widget to update it. When in doubt, trust the station signs. See How the widget works for more.
No accounts, no names, no email addresses, and no location. Each widget sends a random ID that's generated on your phone and isn't tied to you. When a widget requests arrivals, my server logs that ID, the station, line, and direction requested, the time, and whether the request worked. If someone sends too many requests too quickly, the server also logs their IP address and the request path. I use this to see how the service is running and to fix problems.
I got tired of opening the MARTA app and clicking around just to see when the next train was coming. So I made this widget for myself: one glance at my home screen and I know when to leave.
After using it for a while, I figured other riders might feel the same way, so I put it online for anyone who wants it. It runs through the free Scriptable app instead of a native app, and the FAQ explains why.
Arrival data comes from MARTA's public real-time data service. There are no accounts and no sign-up, and the project is an independent side project run by one person.