You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/_components/sensor.mvglive.markdown
+21-27Lines changed: 21 additions & 27 deletions
Original file line number
Diff line number
Diff line change
@@ -22,45 +22,39 @@ To enable this sensor, add the following lines to your `configuration.yaml` file
22
22
# Example configuration.yaml entry
23
23
sensor:
24
24
- platform: mvglive
25
-
station: STATION_OR_STOP
25
+
nextdeparture:
26
+
- station: STATION_OR_STOP_NAME
26
27
```
27
28
28
29
Configuration variables:
29
30
30
31
- **station** (*Required*): Name of the stop or station. Visit [the MVG live web site](http://www.mvg-live.de) to find valid names.
31
-
- **destination** (*Optional*): Name of the line's final destination to display only connections ending there.
32
-
- **line** (*Optional*): Online display connections from this line, e.g. `'U6'`, `'S2'`.
33
-
- **offset** (*Optional*): Do not display connections departing sooner than this number of minutes (defaults to 0). Useful if you are a couple of minutes away from the stop.
34
-
- **bus** (*Optional*): If 'False', do not display bus connections
35
-
- **tram** (*Optional*): If 'False', do not display tram connections
36
-
- **ubahn** (*Optional*): If 'False', do not display U-Bahn (subway) connections
37
-
- **sbahn** (*Optional*): If 'False', do not display S-Bahn (suburban train) connections
38
-
32
+
- **destinations** (*Optional*): One or multiple final stop names, e.g. 'Feldmoching' or ['Feldmoching','Harthof']. This can be used to only consider a particular direction of travel
33
+
- **directions** (*Optional*): Filter by direction of the departure. For Tram, Bus, SEV, and S-Bahn, direction = direction. For U-Bahn trains, directions are more general. For U1, U2, U3 and U6, direction='1' indicates south-bound trains, direction='2' indicates northbound trains. For U4 and U5, direction='1' indicates east-bound trains, direction='2' indicates west-bound trains. For example, setting directions: '1' can be used to get all south-bound trains at Scheidplatz.
34
+
- **lines** (*Optional*): One or more line numbers, e.g. 'U2' or ['U2','U8','N41']
35
+
- **products** (*Optional*): One or more modes of transport, defaults to all 4 modes ['U-Bahn', 'Tram', 'Bus', 'S-Bahn'].
36
+
- **timeoffset** (*Optional*): Do not display departures leaving sooner than this number of minutes (defaults to 0). Useful if you are a couple of minutes away from the stop.
37
+
- **name** (*Optional*): You can customise the name of the sensor, which defaults to the station name.
39
38
## {% linkable_title Examples %}
40
39
41
40
### {% linkable_title Full configuration %}
42
41
43
-
The example below shows a full configuration using the 'line' argument.
44
-
45
-
```yaml
46
-
# Example configuration.yml entry
47
-
sensor:
48
-
- platform: mvglive
49
-
station: Marienplatz
50
-
line: U6
51
-
offset: 5
52
-
destination: Garching-Forschungszentrum
53
-
```
54
-
55
-
Another example showing all bus connections at the main station.
42
+
The example below shows a full configuration with three sensors that showcase the various configuration options.
The first sensor will return S-Bahn departures to Munich Airport or Markt Schwaben that are at least 2 minutes away. The second sensor returns U2 and U8 departures from Sendlinger Tor while the third sensor returns all south-bound U-Bahn trains from Scheidplatz.
0 commit comments