DbInfo extension
- allows you to check if your train is punctual
- just go into the extension menu and select DbInfo
- in background the web service mobile.bahn.de is used to search for the train information
Installation
- software you need
- checkout the Extensions folder (if not already done)
- change into the DbInfo folder
- create the configuration file DbUserConf.py; the format is very easy:
from DbStation import DbStation stations = [ DbStation('<LABEL>', '<STATION_ID>', [ ('<TRAIN_NAME_REGEX>', '<DESTINATION>') ]) ]- To ascertain to the values for STATION_ID, etc., go to mobile.bahn.de, enter your station name and click on Abfahrt. Choose the right one from the combo box and click Abfahrt again. Now you should see the list of trains leaving this station in the next one hour. To determine the STATION_ID click on the link Ankunft and extract the number after "dox?si=" in the URL. The values for TRAIN_NAME_REGEX and DESTINATION are also simple. If you want to use a special train, use this name instead of TRAIN_NAME_REGEX. Otherwise replace TRAIN_NAME_REGEX with ".*". The DESTINATION must be the exact name of the train destination. That's all.
- in detail:
- stations is a list of DbStations
- each DbStation defines a train connection, which has a LABEL, a STATION_ID and a list of train filter
- a train filter is just a pair ('<TRAIN_NAME_REGEX>', '<DESTINATION>'), where TRAIN_NAME_REGEX is a regular expression for the train name and DESTINATION just a string which has to match exactly
- test you configuration by running
python run.py
The program should print the current departure information available for your trains for the next hour. If you miss a train or want to get rid of waste trains, you have to adapt your configuration file again.
- upload the plugin to your Dreambox
make install
Source
- checkout
svn co https://mail.cweiske.de/svn/dreambox/trunk/Extensions/DbInfo
Tickets
- open tickets: 0
About
Author
License
- This extension is free software; you can redistribute it and/or modify it under the GNU General Public License.
![(please configure the [header_logo] section in trac.ini)](http://common.open-dreambox.org/images/trac_logo.png)