[iRail] liveboards arrival time messed up

Tim Besard tim.besard at gmail.com
Wed Jan 4 21:11:13 UTC 2012

Oh yeah now I get what you mean. AFAIK it might very well be possible
that RailTime (Infrabel) offers different, more accurate information
than Hafas (NMBS) does; there tend to be subtle differences between
both datasources all the time.

However, it is possible that the Hafas API offers an option to query
for actual arrival times, and not just the "boardType" one (which is
what we are using now [0]). The query in aforementioned source file is
reconstructed from snooping the network traffic one of the official
apps generate (the Symbian one IIRC), so could you check if one of the
apps directly using Hafas offer accurate departure/arrival times, and
if so have a look at the query options it uses?

0: https://github.com/iRail/iRail/blob/thedatatank/custom/packages/NMBS/Liveboard.class.php#L38
Note that this is the new API (I can't seem to find the source code of
the old one, has the master branch been overwritten?) but the concept
is the same.


2012/1/4 bert bruynooghe <bert.bruynooghe at gmail.com>:
> Hi Tim,
> using timeSel=arrive or timeSel=departure doesn't make any difference
> in giving back the time of the vehicle. I expect at least one minute
> differnce between arrival and departure, as is the case in
> railtime.be.
> I tried arrdep=ARR as described in the API, and that gives me arrivals
> instead of departure, but still with the departure time.
> My user story is the following: I take the train several times a week
> from Gent Sint Pieters to Terhulpen, carrying my bike on the train.
> The route you guys and railtime propose do not take into account
> platform travel distance, and I can most of the times stay on same
> platform if I choose another Brussels station manually. (I can in fact
> choose between 3 instead of the 1 you propose.) I was now hoping I
> could get the write a quick webapp using your API that I can use for
> this purpose without having to load the route, the vehicles, the
> liveboards, .. by hand. Especially when trains have delay, it would be
> great to have the capability to recalculate the optimal route...
> On Wed, Jan 4, 2012 at 8:58 PM, Tim Besard <tim.besard at gmail.com> wrote:
>> Hi Bert,
>>> I have the impression that arrival times of trains in the liveboard
>>> are actually the departure times. Also, the station is the destination
>>> station, not the origin as expected...
>> That's the expected behaviour. If you want arrivals, you need to
>> specify "timeSel=arrive", e.g.
>> http://api.irail.be/liveboard/?station=Gent?timeSel=arrive, as per
>> http://project.irail.be/wiki/API/APIv1
>>> Is there anywhere a buglist to be found?
>> There are several. Firstly (and mainly) there is the Trac on
>> project.irail.be, which has a bugtracker at
>> http://project.irail.be/report/1
>> Recently, some bug reports are being posted at the GitHub source
>> repository of the iRail code (at
>> https://github.com/iRail/iRail/issues), but I think that's only being
>> used for bugs on the new (TDT powered, currently in alpha) API.
>> @Pieter: maybe close down the GitHub bug reports and redirect to the Trac?
>> Tim
>> _______________________________________________
>> iRail mailing list
>> iRail at list.irail.be
>> http://lists.rootspirit.com/mailman/listinfo/irail
> _______________________________________________
> iRail mailing list
> iRail at list.irail.be
> http://lists.rootspirit.com/mailman/listinfo/irail

More information about the iRail mailing list