This sensor use unofficial API provided by MPK Rzeszów.
Key | Type | Required | Default | Description |
---|---|---|---|---|
name |
string |
False |
MPK Rzeszów |
Name of sensor |
stops |
list |
True |
- | List of stop configurations |
Key | Type | Required | Default | Description |
---|---|---|---|---|
id |
positive integer |
True |
- | ID of a stop |
name |
string |
False |
id | Name of a stop |
lines |
list |
False |
all available | List of monitored lines. |
directions |
list |
False |
all available | List of monitored directions. |
sensor:
- platform: mpk_rzeszow
stops:
- id: 875
lines:
- "13"
- "2"
- id: 18
directions:
- "Obr. Poczty Gdańskiej"
Using HACS (recommended)
This integration can be added to HACS as a custom repository:
- URL:
https://github.com/PiotrMachowski/Home-Assistant-custom-components-MPK-Rzeszow
- Category:
Integration
After adding a custom repository you can use HACS to install this integration using user interface.
To install this integration manually you have to download mpk_rzeszow.zip and extract its contents to config/custom_components/mpk_rzeszow
directory:
mkdir -p custom_components/mpk_rzeszow
cd custom_components/mpk_rzeszow
wget https://github.com/PiotrMachowski/Home-Assistant-custom-components-MPK-Rzeszow/releases/latest/download/mpk_rzeszow.zip
unzip mpk_rzeszow.zip
rm mpk_rzeszow.zip
-
Value for
stop_id
can be retrieved from E-INFO Rzeszów. After choosing a desired stop open its electronical table.stop_id
is a number visibile in URL. -
These sensors provides attributes which can be used in HTML card or HTML Template card:
html_timetable
,html_departures
- HTML card:
- type: custom:html-card title: 'MPK' content: | <big><center>Timetable</center></big> [[ sensor.mpk_rzeszow_875.attributes.html_timetable ]] <big><center>Departures</center></big> [[ sensor.mpk_rzeszow_18.attributes.html_departures ]]
- HTML Template card:
- type: custom:html-template-card title: 'MPK' ignore_line_breaks: true content: | <big><center>Timetable</center></big></br> {{ state_attr('sensor.mpk_rzeszow_875','html_timetable') }} </br><big><center>Departures</center></big></br> {{ state_attr('sensor.mpk_rzeszow_18','html_departures') }}
- HTML card:
If you want to support my work with a donation you can use one of the following platforms:
Platform | Payment methods | Link | Comment |
---|---|---|---|
Ko-fi |
|
|
|
buycoffee.to |
|
||
PayPal |
|
|
|
Revolut |
|
|