Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[resource request] Transport for London #243

Open
Sandvich opened this issue Jun 3, 2016 · 9 comments
Open

[resource request] Transport for London #243

Sandvich opened this issue Jun 3, 2016 · 9 comments

Comments

@Sandvich
Copy link

Sandvich commented Jun 3, 2016

Hi!

Right now Ubuntu Touch is missing any decent transport apps for London, and I think fahrplan could do a good job. The details of the API are on the TfL website here: https://tfl.gov.uk/info-for/open-data-users/data-feeds?intcmp=29422
I would, of course, be up for doing most of this myself, but for now I don't really know where to begin!

Thanks,
Sanchit

@leppa
Copy link
Collaborator

leppa commented Jun 3, 2016

I would, of course, be up for doing most of this myself, but for now I don't really know where to begin!

If you know C++, you can create a new parser yourself and submit a pull request.

For this, you need to subclass ParserAbstract (or ParserEfa/HafasXml/HafasBinary, which already implement parsing of some common data formats) and re-implement relevant virtual functions. Then add your new parser to FahrplanParserThread::run() and FahrplanBackendManager::getParserList().

@Sandvich
Copy link
Author

Sandvich commented Jun 3, 2016

This sounds complex but hopefully doable :3

@leppa
Copy link
Collaborator

leppa commented Jun 3, 2016

I see that the API you mentioned supports JSON and XML. Parsing XML is a pain, so I'd suggest using JSON here. You can take a look at ParserNinetwo implementation, which also uses JSON-based backend.

Don't know how is it for @smurfy, but unfortunately, I don't have much time for side-projects ATM. But I'll try to help if you have some questions (or need a code review).

@smurfy
Copy link
Owner

smurfy commented Jun 3, 2016

I'm quite busy myself at the moment too.

@Sandvich
Copy link
Author

Sandvich commented Jun 3, 2016

Sounds good - I use JSON a lot at work, so I'm much more comfortable with that than XML.

@balcy
Copy link

balcy commented Feb 7, 2018

Hi I wanted to say that I've written a backend for Transport for London based on api.tfl.gov.uk
Station search (by name and GPS) and journeys (with various transport types) should be fine already.
For the timetable I used the "Live arrivals" API. Therefore you cannot search for departures / arrivals at other times than the current time, and departures from terminal stations do not work.
For other stations / bus stops departures and arrivals should be identical.
What I'm not sure about is if all platform support unicode symbols for bus stops (🚏) or underground (🚇), because I only could test it on Ubuntu touch
I can send a PR for that.

@balcy
Copy link

balcy commented Mar 1, 2018

#268

@balcy
Copy link

balcy commented Mar 17, 2018

@dayrover, @smurfy I would like to make TFL available on Ubuntu touch.

@balcy
Copy link

balcy commented Apr 1, 2018

The feature is now available for Ubuntu Touch: https://open-store.io/app/openstore.fahrplan2 @dayrover thanks for uploading.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants