Öffimonitor: Unterschied zwischen den Versionen

aus Metalab Wiki, dem offenen Zentrum für meta-disziplinäre Magier und technisch-kreative Enthusiasten.
Zur Navigation springenZur Suche springen
K (Metadata)
(this changes everything)
Zeile 2: Zeile 2:
 
{{Projekt
 
{{Projekt
 
|image=No-Logo.png
 
|image=No-Logo.png
|involved=[[User:Name]]
+
|involved=[[User:ente]], [[User:nioram]], [[User:Burnoutberni]]
 
|startdate=21.01.2013
 
|startdate=21.01.2013
|status=active|in progress|on hold|suspended|completed|canceled
+
|status=in progress
 
|wtf=Display departure times of nearby public transport.
 
|wtf=Display departure times of nearby public transport.
|lastupdate=21.01.2013 <!-- if lastupdate is not set manually, the date will be set automatically to the date of the latest wikiapage -->
+
|lastupdate=03.10.2015
 
|hidden=false
 
|hidden=false
 
}}
 
}}
Zeile 14: Zeile 14:
 
Abfahrtszeiten-Anzeige der umliegenden Öffis
 
Abfahrtszeiten-Anzeige der umliegenden Öffis
  
siehe [https://metalab.at/issues/ticket/50 Ticket #50]
+
* Selbstgehackter VESA Wall-Mount und Raspberry Pi von [[User:nioram]]
 +
* Linux-Setup und Teile des Codes von [[User:ente]]
 +
* Rest des Codes und supertolles CSS von [[User:Burnoutberni]]
  
Kopiert von dort:
+
Code gibts auf [https://github.com/Metalab/oeffimonitor Github]
  
Schnittstelle Wiener Linen Key Anforderung und Doku: <br />
+
Eingesetzte Technik:
https://open.wien.at/site/datensatz/?id=add66f20-d033-4eee-b9a0-47019828e698<br />
+
* Raspberry Pi
(Key kommt innerhalb von 24 Stunden (Test und Production Key).)
+
* X11
 +
* Midori
 +
* HTML/CSS/Javascript
 +
* PHP/httpd für JSON Proxy um CORS zu erlauben (WIP)
 +
* [https://www.data.gv.at/katalog/dataset/add66f20-d033-4eee-b9a0-47019828e698 Wiener Linien API]
  
PDF Schnittstellenbeschreibung: <br />
+
Anzeige gibts im Hauptraum oberhalb der Webstation zu bestaunen
http://data.wien.gv.at/pdf/wienerlinien-echtzeitdaten-dokumentation.pdf
 
 
 
Anfordern kann man via simplen HTTP Get:<br />
 
Bsp: Station Rathaus U2 (rbl 4205, 4210) und Tram 2 (rbl 252, 269) je ein Key für eine Linienrichtung <br />
 
http://www.wienerlinien.at/ogd_realtime/monitor?rbl=4205&rbl=4210&rbl=252&rbl=269&sender=<API KEY>
 
 
 
Alternativ mit Störungsinfos:<br />
 
http://www.wienerlinien.at/ogd_realtime/monitor?rbl=4205&rbl=4210&rbl=252&rbl=269&activateTrafficInfo=stoerungkurz&activateTrafficInfo=stoerunglang&activateTrafficInfo=aufzugsinfo&sender=<API KEY>
 
 
 
Zurück kommt ein JSON (Bsp. ohne Störungsinfos), Datenfelder siehe Doku!
 
 
 
<code>
 
{"data":{"monitors":[{"locationStop":{"type":"Feature","geometry":{"type":"Point","coordinates":[16.3547918762926,48.2091726073155]},"properties":{"name":"60201072","title":"Rathaus","municipality":"Wien","municipalityId":90000,"type":"stop","coordName":"WGS84","attributes":{"rbl":252}}},"lines":[{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"departures":{"departure":[{"departureTime":{"timePlanned":"2014-05-13T10:11:00.000+0200","timeReal":"2014-05-13T10:13:59.000+0200","countdown":0}},{"departureTime":{"timePlanned":"2014-05-13T10:13:00.000+0200","timeReal":"2014-05-13T10:15:16.000+0200","countdown":2},"vehicle":{"name":"2","towards":"Karlsplatz U, Bösendorfer Straße","direction":"H","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:17:00.000+0200","timeReal":"2014-05-13T10:18:20.000+0200","countdown":5},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:24:00.000+0200","timeReal":"2014-05-13T10:23:23.000+0200","countdown":10},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:31:00.000+0200","timeReal":"2014-05-13T10:31:00.000+0200","countdown":17},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:37:00.000+0200","timeReal":"2014-05-13T10:37:30.000+0200","countdown":24}},{"departureTime":{"timePlanned":"2014-05-13T10:44:00.000+0200","timeReal":"2014-05-13T10:44:30.000+0200","countdown":31},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:51:00.000+0200","timeReal":"2014-05-13T10:51:00.000+0200","countdown":37},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:57:00.000+0200","timeReal":"2014-05-13T10:57:30.000+0200","countdown":44},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T11:04:00.000+0200","timeReal":"2014-05-13T11:04:30.000+0200","countdown":51}},{"departureTime":{"timePlanned":"2014-05-13T11:11:00.000+0200","timeReal":"2014-05-13T11:11:00.000+0200","countdown":57},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T11:17:00.000+0200","countdown":63},"vehicle":{"name":"2","towards":"Friedrich-Engels-Platz","direction":"H","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram"}}]},"type":"ptTram","lineId":102}],"attributes":{}},{"locationStop":{"type":"Feature","geometry":{"type":"Point","coordinates":[16.3555722993094,48.2093073762738]},"properties":{"name":"60201072","title":"Rathaus","municipality":"Wien","municipalityId":90000,"type":"stop","coordName":"WGS84","attributes":{"rbl":269}}},"lines":[{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"departures":{"departure":[{"departureTime":{"timePlanned":"2014-05-13T10:19:00.000+0200","timeReal":"2014-05-13T10:19:15.000+0200","countdown":6}},{"departureTime":{"timePlanned":"2014-05-13T10:25:00.000+0200","timeReal":"2014-05-13T10:27:32.000+0200","countdown":14},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:32:00.000+0200","timeReal":"2014-05-13T10:30:39.000+0200","countdown":17},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:38:00.000+0200","timeReal":"2014-05-13T10:38:30.000+0200","countdown":25}},{"departureTime":{"timePlanned":"2014-05-13T10:45:00.000+0200","timeReal":"2014-05-13T10:42:16.000+0200","countdown":29},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:52:00.000+0200","timeReal":"2014-05-13T10:43:55.000+0200","countdown":30},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T10:59:00.000+0200","timeReal":"2014-05-13T10:59:00.000+0200","countdown":45}},{"departureTime":{"timePlanned":"2014-05-13T11:05:00.000+0200","timeReal":"2014-05-13T11:05:30.000+0200","countdown":52},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T11:12:00.000+0200","timeReal":"2014-05-13T11:12:00.000+0200","countdown":58},"vehicle":{"name":"2","towards":"Ottakringer Str., Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram","linienId":102}},{"departureTime":{"timePlanned":"2014-05-13T11:19:00.000+0200","countdown":65},"vehicle":{"name":"2","towards":"Ottakringer Straße, Erdbrustgasse","direction":"R","richtungsId":"1","barrierFree":false,"realtimeSupported":true,"trafficjam":false,"type":"ptTram"}}]},"type":"ptTram","lineId":102}],"attributes":{}},{"locationStop":{"type":"Feature","geometry":{"type":"Point","coordinates":[16.3555190235363,48.2107463000071]},"properties":{"name":"60201072","title":"Rathaus","municipality":"Wien","municipalityId":90000,"type":"stop","coordName":"WGS84","gate":"1","attributes":{"rbl":4205}}},"lines":[{"name":"U2","towards":"KARLSPLATZ","direction":"H","platform":"1","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"departures":{"departure":[{"departureTime":{"timePlanned":"2014-05-13T10:16:48.000+0200","timeReal":"2014-05-13T10:16:48.000+0200","countdown":4}},{"departureTime":{"timePlanned":"2014-05-13T10:21:48.000+0200","timeReal":"2014-05-13T10:21:48.000+0200","countdown":9}}]},"type":"ptMetro","lineId":302}],"attributes":{}},{"locationStop":{"type":"Feature","geometry":{"type":"Point","coordinates":[16.3553706872941,48.2098649896921]},"properties":{"name":"60201072","title":"Rathaus","municipality":"Wien","municipalityId":90000,"type":"stop","coordName":"WGS84","gate":"2","attributes":{"rbl":4210}}},"lines":[{"name":"U2","towards":"ASPERNSTRASSE","direction":"R","platform":"2","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"departures":{"departure":[{"departureTime":{"timePlanned":"2014-05-13T10:14:48.000+0200","timeReal":"2014-05-13T10:14:48.000+0200","countdown":2}},{"departureTime":{"timePlanned":"2014-05-13T10:20:48.000+0200","timeReal":"2014-05-13T10:20:48.000+0200","countdown":8},"vehicle":{"name":"U2","towards":"SEESTADT","direction":"R","richtungsId":"1","barrierFree":true,"realtimeSupported":true,"trafficjam":false,"type":"ptMetro","linienId":302}}]},"type":"ptMetro","lineId":302}],"attributes":{}}]},"message":{"value":"OK","messageCode":1,"serverTime":"2014-05-13T10:13:06.511+0200"}}
 
</code>
 
  
 
[[Kategorie:Projekte]]
 
[[Kategorie:Projekte]]

Version vom 2. Oktober 2015, 23:52 Uhr

Language: English
Subpages:
Öffimonitor hat keine Unterseiten.


Öffimonitor
No-Logo.png
Gestartet: 21.01.2013
Involvierte: User:ente, User:nioram, User:Burnoutberni
Status: in progress
Beschreibung: Display departure times of nearby public transport.
Shutdownprozedur:
Zuletzt aktualisiert: 03.10.2015


Haltestellen-Anzeige

Abfahrtszeiten-Anzeige der umliegenden Öffis

Code gibts auf Github

Eingesetzte Technik:

  • Raspberry Pi
  • X11
  • Midori
  • HTML/CSS/Javascript
  • PHP/httpd für JSON Proxy um CORS zu erlauben (WIP)
  • Wiener Linien API

Anzeige gibts im Hauptraum oberhalb der Webstation zu bestaunen