<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[MMM-transitfeed - upcoming departure board for most transit agencies]]></title><description><![CDATA[<h1>Description:</h1>
<p dir="auto">MMM-transitfeed uses GTFS (General Transit Feed Specification) sources to generate a live departures board that works for most public transit agencies. Agencies decide whether to publish GTFS data, so YMMV. For instance, SEPTA publishes one file with regional rail routes, and a second with everything else. As long as both are imported in the <code>config</code>, queries for bus, regional rail, trolley, and subway lines all work.</p>
<p dir="auto">Using the configuration, you can specify which routes, stations, and directions to monitor. By default, the next three departures are shown, but that’s configurable too. The <code>README</code> has more detail on configuration options.</p>
<p dir="auto">GTFS is used by Google/Apple/etc to generate transit directions, and you can usually find download URLs on the transit agencies website. <a href="http://transitfeeds.com" target="_blank" rel="noopener noreferrer nofollow ugc">transitfeeds.com</a> has an index with a ton of GTFS files, though warns they may be out of date.</p>
<p dir="auto">This is my first module with MagicMirror. I wanted a reference for when transit options were near me, and figured it’d be useful to other people. As far as I can tell, the other transit modules here are specialized to an agency; this one works with any GTFS source. (It is a little harder to find the source and get setup, though.)</p>
<h1>Screenshots:</h1>
<p dir="auto"><img src="https://raw.githubusercontent.com/bnitkin/MMM-transitfeed/main/res/screenshot.png" alt="Screenshot of normal usage" class=" img-fluid img-markdown" /><br />
<img src="https://raw.githubusercontent.com/bnitkin/MMM-transitfeed/main/res/30th.png" alt="Screenshot of a station with many departures" class=" img-fluid img-markdown" /></p>
<h1>Download:</h1>
<p dir="auto">[card:bnitkin/MMM-transitfeed]</p>
<hr />
<h2>Version 1.0.0</h2>
<ul>
<li>Initial release</li>
<li>Search &amp; display any number of stations, with filtering by route &amp; direction</li>
<li>Highlights departures in the next 5 minutes (configurable)</li>
<li>Can either consolidate or show all terminii for multi-head routes</li>
<li>Display departures as wall time or in-X-minutes</li>
<li>Doesn’t currently support
<ul>
<li>Realtime updates</li>
<li>Holiday schedules</li>
</ul>
</li>
</ul>
]]></description><link>https://forum.magicmirror.builders/topic/17479/mmm-transitfeed-upcoming-departure-board-for-most-transit-agencies</link><generator>RSS for Node</generator><lastBuildDate>Thu, 18 Jun 2026 17:49:15 GMT</lastBuildDate><atom:link href="https://forum.magicmirror.builders/topic/17479.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 28 Dec 2022 14:58:28 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Thu, 15 Jun 2023 20:20:49 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bnitkin" aria-label="Profile: bnitkin">@<bdi>bnitkin</bdi></a> Thank you, I’ll do as you instructed and will be pruning the GTFS in order to lighten it.<br />
You’re right, except for road work, timetable don’t change a week to another.</p>
<p dir="auto">Sadly individual GTFS source don’t exist anymore as the autority that manage transport in Paris has decided to centralize everything (for the best and the worst).</p>
<p dir="auto">Thank you again :)</p>
]]></description><link>https://forum.magicmirror.builders/post/109816</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/109816</guid><dc:creator><![CDATA[Nisnis39]]></dc:creator><pubDate>Thu, 15 Jun 2023 20:20:49 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Thu, 15 Jun 2023 18:43:40 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/nisnis39" aria-label="Profile: Nisnis39">@<bdi>Nisnis39</bdi></a> I don’t have a great answer, but might have a solution.</p>
<p dir="auto"><a href="https://stackoverflow.com/questions/26892634/splitting-gtfs-transit-data-into-smaller-ones" target="_blank" rel="noopener noreferrer nofollow ugc">These folks</a> talk about the same issue of pruning, and that GTFS isn’t really organized by month. Internally, it assigns services to weekly calendars, and gives each calendar an effective time.</p>
<p dir="auto">For instance, a train might depart Trenton at 2:00 and arrive in Philly at 3:00 on the <code>Weekday</code> calendar. And that calendar’s effective Monday-Friday from 3/3/2022-8/8/2023. So the next month of service is the same amount of data as the next 3 since it’s just the same trip over and over (unless Paris schedules change absolutely all the time).</p>
<p dir="auto">I think prefiltering will work for you. The Stackoverflow question mentions using <a href="https://github.com/interline-io/transitland-lib/releases" target="_blank" rel="noopener noreferrer nofollow ugc">Transitland</a> to manipulate GTFS files.</p>
<p dir="auto">If you extract <code>IDFM-gtfs.zip</code> and look at <code>agency.txt</code>, it calls out a bunch of different Paris transit providers:</p>
<pre><code>agency_id,agency_name,agency_url,agency_timezone,agency_lang,agency_phone,agency_fare_url,agency_email
IDFM:71,RER,http://www.navitia.io/,Europe/Paris,,,,
IDFM:55,Noctilien,http://www.navitia.io/,Europe/Paris,,,,
IDFM:93,TER,http://www.navitia.io/,Europe/Paris,,,,
IDFM:1046,Transilien,http://www.navitia.io/,Europe/Paris,,,,
IDFM:1069,Terres d'Envol,http://www.navitia.io/,Europe/Paris,,,,
IDFM:1051,Poissy - Les Mureaux,http://www.navitia.io/,Europe/Paris,,,,
IDFM:65,Phébus,http://www.navitia.io/,Europe/Paris,,,,
...
</code></pre>
<p dir="auto">Transitland can prune the routes down to the agencies (or routes) you’re interested in. Since it’s written in Go it’s much faster than the <code>npm</code> <code>gtfs</code> library. The releases link above has compiled downloads for Windows &amp; Linux.</p>
<p dir="auto">This will extract all routes served by <code>IDFM:71</code> (RER) and <code>IDFM:65</code> (Phébus). Replace with whichever agencies you’re actually interested in. It might work on the Pi or you might need a real computer:</p>
<pre><code>./transitland-linux extract -extract-agency IDFM:71 -extract-agency IDFM:65 IDFM-gtfs.zip pruned.zip
</code></pre>
<p dir="auto">Once you have a pruned GTFS file, swap that into the MagicMirror config (note <code>path</code> instead of <code>url</code>):</p>
<pre><code>      gtfs_config: {
         agencies: [
            {
               "path": "/path/to/pruned.zip",
               // Excluding shapes makes loading faster.
               exclude: ['shapes']
            },
            ...
</code></pre>
<p dir="auto">There are some shortcomings. The pruned file is a snapshot and won’t update if schedules change, and it’s obviously extra work.</p>
<p dir="auto">If you can find individual GTFS sources for the agencies that operate your routes, that’d be much easier. Merging ~100 agencies in the region together is a ton of data.</p>
<p dir="auto">You could also try fishing in the <a href="https://www.npmjs.com/package/gtfs/v/2.4.4#configuration" target="_blank" rel="noopener noreferrer nofollow ugc">GTFS library</a> for exclusions and optimizations. It supports excluding individual files (like shapes), but doesn’t seem to have filtering on route/agency/calendar at import-time. If you find something promising, let me know - I’m happy to take pull requests or try things out!</p>
]]></description><link>https://forum.magicmirror.builders/post/109815</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/109815</guid><dc:creator><![CDATA[bnitkin]]></dc:creator><pubDate>Thu, 15 Jun 2023 18:43:40 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Tue, 13 Jun 2023 22:14:10 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bnitkin" aria-label="Profile: bnitkin">@<bdi>bnitkin</bdi></a> Hello,</p>
<p dir="auto">This is an awesome project and it’s pretty much what i’m looking for for my MagicMirror (we don’t have dedicated module for Paris :( ).</p>
<p dir="auto">I have an issue though, as Paris is a very large city and as all our transport are regrouped into one GTFS (for the 3 next month) we get a stop_time.txt with 9 millions lines which is too much too handle for my Raspberry.</p>
<p dir="auto">Would it be possible to add a limit to the line that are extracted as we don’t need the timetable for the next 3 month but at most for the next week.</p>
<p dir="auto">Here the link to the GTFS if you want to take a peak : <a href="https://data.iledefrance-mobilites.fr/explore/dataset/offre-horaires-tc-gtfs-idfm/files/a925e164271e4bca93433756d6a340d1/download/" target="_blank" rel="noopener noreferrer nofollow ugc">https://data.iledefrance-mobilites.fr/explore/dataset/offre-horaires-tc-gtfs-idfm/files/a925e164271e4bca93433756d6a340d1/download/</a></p>
<p dir="auto">I’d be delighted if you could help me with this issue.</p>
<p dir="auto">Best regards</p>
]]></description><link>https://forum.magicmirror.builders/post/109808</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/109808</guid><dc:creator><![CDATA[Nisnis39]]></dc:creator><pubDate>Tue, 13 Jun 2023 22:14:10 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Sun, 26 Mar 2023 16:57:08 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bnitkin" aria-label="Profile: bnitkin">@<bdi>bnitkin</bdi></a> said in <a href="/post/108409">MMM-transitfeed - upcoming departure board for most transit agencies</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/rnieto18" aria-label="Profile: rnieto18">@<bdi>rnieto18</bdi></a> Thanks for reporting that! You’re doing everything right; there was a parsing disagreement between my script and Virginia Railway. You should be able to pull from <code>main</code> (or just restart magicmirror; I think it auto-updates?) and be back in business.</p>
<p dir="auto">GTFS supports calendars so transit agencies can report different service on weekdays vs weekends or special holiday service. That means a single GTFS trip usually corresponds to M-F service under the same trip ID. <code>MMM-transitfeed</code> looks up the calendar for each trip to generate daily schedules. Virginia Rail has a single calendar called <code>Regular</code>, but the trips reference other calendars like <code>Summer</code> and <code>Day After Thanksgiving</code>.</p>
<p dir="auto">My script was looking up those nonexistent calendars and crashing when it tried to extract service from them. I’ve fixed it to not examine calendars that don’t exist.</p>
<p dir="auto">Let me know if it works, or if you’re still having trouble!</p>
<p dir="auto">– Ben</p>
</blockquote>
<p dir="auto">Thank You!! works great now</p>
]]></description><link>https://forum.magicmirror.builders/post/108411</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/108411</guid><dc:creator><![CDATA[rnieto18]]></dc:creator><pubDate>Sun, 26 Mar 2023 16:57:08 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Sun, 26 Mar 2023 14:22:31 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/rnieto18" aria-label="Profile: rnieto18">@<bdi>rnieto18</bdi></a> Thanks for reporting that! You’re doing everything right; there was a parsing disagreement between my script and Virginia Railway. You should be able to pull from <code>main</code> (or just restart magicmirror; I think it auto-updates?) and be back in business.</p>
<p dir="auto">GTFS supports calendars so transit agencies can report different service on weekdays vs weekends or special holiday service. That means a single GTFS trip usually corresponds to M-F service under the same trip ID. <code>MMM-transitfeed</code> looks up the calendar for each trip to generate daily schedules. Virginia Rail has a single calendar called <code>Regular</code>, but the trips reference other calendars like <code>Summer</code> and <code>Day After Thanksgiving</code>.</p>
<p dir="auto">My script was looking up those nonexistent calendars and crashing when it tried to extract service from them. I’ve fixed it to not examine calendars that don’t exist.</p>
<p dir="auto">Let me know if it works, or if you’re still having trouble!</p>
<p dir="auto">– Ben</p>
]]></description><link>https://forum.magicmirror.builders/post/108409</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/108409</guid><dc:creator><![CDATA[bnitkin]]></dc:creator><pubDate>Sun, 26 Mar 2023 14:22:31 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Fri, 24 Mar 2023 16:43:36 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bnitkin" aria-label="Profile: bnitkin">@<bdi>bnitkin</bdi></a> I am beating my head trying to get the Virginia Railway into this module.</p>
<p dir="auto">I went <a href="https://transitfeeds.com/p/virginia-railway-express/250" target="_blank" rel="noopener noreferrer nofollow ugc">https://transitfeeds.com/p/virginia-railway-express/250</a> and pulled the link to the latest download.  I added it to my config</p>
<pre><code>		   config: {
				gtfs_config: {
				agencies: [
					{
					"url": "https://transitfeeds.com/p/virginia-railway-express/250/latest/download",
					exclude: ['shapes']
					},
				],	
			},

			// Route + station pairs to monitor for departures
			queries: [
				{route_name: "Fredericksburg Line", stop_name: "Lorton"},
			],
			showStationNames: false,
			}
</code></pre>
<p dir="auto">I get no trips found yet.  Check queries in the config if this persists.    I can get this to work with your config in the readme.</p>
<p dir="auto">I have even looked at <a href="https://www.vre.org/sites/vre/assets/File/pdfs/MobileDevelopersGuideweb.pdf" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.vre.org/sites/vre/assets/File/pdfs/MobileDevelopersGuideweb.pdf</a><br />
and tried <a href="http://www.vre.org/gtfs/google_transit.zip" target="_blank" rel="noopener noreferrer nofollow ugc">http://www.vre.org/gtfs/google_transit.zip</a></p>
<p dir="auto">Any help would be appreciated!</p>
]]></description><link>https://forum.magicmirror.builders/post/108382</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/108382</guid><dc:creator><![CDATA[rnieto18]]></dc:creator><pubDate>Fri, 24 Mar 2023 16:43:36 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Thu, 29 Dec 2022 23:15:47 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/0livia" aria-label="Profile: 0livia">@<bdi>0livia</bdi></a> Thanks! I’d like to add realtime support, but the format’s a little harder to work with. It’d also be cool to add little bus/train icons, but I wanted to make sure the base thing worked first.</p>
]]></description><link>https://forum.magicmirror.builders/post/106759</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/106759</guid><dc:creator><![CDATA[bnitkin]]></dc:creator><pubDate>Thu, 29 Dec 2022 23:15:47 GMT</pubDate></item><item><title><![CDATA[Reply to MMM-transitfeed - upcoming departure board for most transit agencies on Thu, 29 Dec 2022 17:49:53 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/bnitkin" aria-label="Profile: bnitkin">@<bdi>bnitkin</bdi></a> cool module thank you. when i was building my mirror i wanted to ad another bus company schedule which uses  GTFS.</p>
]]></description><link>https://forum.magicmirror.builders/post/106757</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/106757</guid><dc:creator><![CDATA[0livia]]></dc:creator><pubDate>Thu, 29 Dec 2022 17:49:53 GMT</pubDate></item></channel></rss>