External integration - Worldwide departure

Hello everyone, who wants to test my new and first widget. Created without Claude. Currently still with some shortcomings, but:

Current procedure:

Installation only directly from Github:

First shortcoming:

The widget configuration only comes when adding the widget.

  1. Currently, only one location can be displayed; you need your geolocation.

  2. The other values are self-explanatory, so keep the search radius at the beginning between 100 and 2000 meters, the display of max hits is up to Gladys. That’s all.

  3. You still need a unique identifier (requirement from Transitous). I simply use my email.

  4. I still need a better image.

Here is the configuration:

Please be so kind … Github is absolutely new … so any errors, additions, etc. in this forum or via this forum directly to me. Not in Github … I still have to learn there.

Have fun with the worldwide display of traffic departures.

Regards

Tom

I’ve stretched the widget a bit:

The configuration is not done during integration, but in the widget, which allows an arbitrary number of widgets with an arbitrary number of different outputs to be displayed.

Please report errors and suggestions here and not via GitHub, as it’s still uncharted territory for me.
Regards

Tom

So, the first version has been released.

  • GUI adjusted
  • Logo created
  • Stop display adjusted
  • various load tests

-Languages added and corresponding note that configuration is done in the widget.

It is in the store according to Gladys Integrations Tracker, but not yet in the store
( Suivi des intégrations Gladys )

So still direct installation via github:

( GitHub - tomgermany/gladys-transitous-departures: Lightweight public transport departures display using Transitous for Gladys Assistant · GitHub )

Otherwise, the first release carries version 1.0.3

Comments, suggestions, corrections are welcome (but please still here, Github needs a bit of learning and a few beers)

Regards

Tom

@Will_71

I’m a complete beginner, but on your list I found the following entries:

1096 MVG Munich
1016 UK Transport
1002 Transport for NSW
950 RMV

Perfect for my integration: Next departure at a selected stop

Best regards
Tom

Hi Tom,

Yes, this is the list of 1190 Home Assistant integrations that @pierre-gilles has compiled so we can make a match in Gladys.

To everyone, I can release the first version for final testing:

Gladys Assistant: Version 5.2.0
external integration version: 1.4.2

What you can expect, here an example from Lisbon:

When inserting!!! (not under Configuration) the widget, you need:

-Internet access

-Geolocation of the desired location
-Search radius
-Number of hits (currently still included, but you always get 6 hits, will be removed)

-Repetition of the search in 10-minute intervals

-a unique identifier for the API request, e.g. URL homepage, email, name or similar

You will receive a widget with the following basic functionality:

Based on the geolocation, bus stops are searched up to the search radius. The nearest bus stop is taken and then the next departure for this bus stop is displayed.

Buses, rail-bound trams, S-Bahn, ICE, TGV, cable cars, ferries in scheduled service and other means of transport are displayed. The names of the stops and their distance appear at the bottom.
The departure times then appear in the tiles with time - line name - destination

In other words: In the countryside, the user takes a larger search radius and, for example, gets the output of the nearest bus stop in 500 meters and the nearest train station in 2000 meters.

Conversely, a city dweller, for example, only takes a search radius of 100 meters, as he only needs the next departures of the bus stop in front of his house.

ToDo: Error handling in case of internet disconnection

ToDo: Documentation

I would be happy to receive tests from all over Europe, feedback, hints or errors here via the community.

Additional: Why the data only when adding the widget? Theoretically, you could insert an unlimited number of widgets with unlimited locations. But I wouldn’t do that, on the one hand the provider is a private organization and on the other hand each widget requires at least two internet queries…

Best regards

Tom

Hello everyone, first of all, congratulations to @pierre-gilles, you’ve done a very very good job with the SDK.
Even absolute beginners can find their way around.

To everyone else:
I’m now ready. Version 2.0.1 is available with some interesting updates:

a.) The search radius can be set by the user in freely selectable steps up to a maximum of 10,000 meters.
b.) A button on the widget and you can go through the search radii and back again.
c.) New languages: Spanish, Korean and with a little nod to North America: Kalaallisut.

It’s only spoken by a few thousand people and I can’t imagine for the life of me that there’s public scheduled air traffic, but it had to be done :joy:

d.) Most important change: If there are flight schedules in Transitous, they are now also displayed. Example from Sardinia:

I

I’m now just waiting for public transport by plane to Sylt or the airlines by helicopter in Stavanger.
Let’s see and until then,

Have fun testing and using,

Best regards,

Tom

Thank you for the integration. I see a fundamental need for this at home. However, I tested it yesterday and received instant feedback from my wife that I didn’t want to withhold from you (and I agree with her :)). A screenshot is attached for illustration.

Design and UI

  • The information is correct, but visually hard to understand. Where does my train to Regensburg depart from? No information about that. Where do my buses depart from exactly? We have 6 stops here.
  • Suggestion: Could you not group by stops/stations/airports, whatever, and then put the respective cards underneath? Then you also know at which stop the good thing departs. (possibly behind the stop, then the distance), then the list below becomes obsolete
  • The button label is too technical. Why not call it « Expand search radius Â»? And possibly make it optional in the widget configuration. I don’t need it, for example, and it just takes up unnecessary space.

I quickly threw something together here to show you what I mean. In this context, you could maybe use a different separator from the « - Â», for example the middle dot and handle it with spacing, so that it has some room to breathe. I’ve attached 2 suggestions for you. The second suggestion would be to bring more hierarchy into the card.

Functional

  • It would be great if you could also define the time in the widget configuration, for example. For example, tomorrow, the day after tomorrow. Possibly even a time ± X hours. Why? My wife, for example, wants to know tomorrow when all the buses depart from which stops exactly. This way, you could make a widget for now and one for tomorrow.

I hope you don’t take all this too critically and are happy about the feedback :slight_smile:

@stefanbauer Great suggestions, that’s actually what I wanted to do, but unfortunately the specifications for widgets are quite strict. 8 components are allowed:
1 heading
6 value tiles
1 card-list with the train stations
1 button

… that was all that was allowed.

That’s why I had the following structure in mind:
a.) Starting from a geolocation, the nearest stop is searched for, then other stops of different modes of transport are searched for until the end of the desired search radius.
As a result, you get your nearest stops marked in color, for example in green the nearest bus stop, in blue the nearest TRAM and so on.
b.) Then you get the departure times in the same color and a logo with the mode of transport.
c.) You only get a stop if something is actually running there

Regarding your image:
The next departure is at 07:23, it’s a train, TRAM or similar, and the direction is Munich Airport. Departure is 7371 meters away and the stop there is called Langenbach.

To start: Start small, then probably only one bus stop will be displayed. Since only one stop is coming, the next six departures will be displayed there.

Then expand the circle, depending on the location up to the next train station, then you get two departure points and depending on the location two or three departures.

But since I was only allowed to use one component and I somehow wanted to implement that the user can go through his three search circles, only the button with a kind of up and down switching remains.

But I’ll see if there isn’t a better way, thanks for the many hints and greetings to your partner

Best regards

Tom

@stefanbauer Almost overlooked… I’ll check the time period setting today to see if I can get it in, should be easy to implement.

Regards

Tom

@stefanbauer Dear Stefan, you’re stirring things up :joy: , but what wouldn’t we do for our women.
As said, so done:
Update 1: Currently includes a clearer connection between the departures and the departure stops. Not just the distance, but according to the available data. If Transitorius also provides the line, it should appear in the badge in the list of departure stops.

Non-changeable: The number of components and their assignment. Various attempts to use a cardlist with a grid ended up visually more than in Nirvana. I also can’t set the value tiles to be displayed after the card-list (i.e., the list of departure stops before the departures). Maybe someone else has an idea?

Current status:

ToDo: Remove duplicate distance indication
ToDo: Incorporate the time component in the configuration, expected pattern: Current time, Current time plus 1 day, Current time plus 2 days (or freely enterable)

For the regular testers here: Just wait until the next round.
For the impatient: Gladys - Integrations - Installed - Select Transitous - Monitoring and then force update. Version 3.1.0 should be installed.

Regards

Tom

But that can’t be correct, can it? If I enter 339m as the radius, I would expect only the upper one to be displayed and not the lower one. It’s also interesting that both are displayed here, and it’s the same stop, but they seem to be 27m apart :smiley:

@stefanbauer Hi Stefan, sorry, but… in Erdinger Straße there are two bus stops with the same name and a check in Google Maps showed a distance of 36 meters. I assume there’s a curve there and the builders planned it that way. That is, one bus stop for each direction, 36 meters apart.

Regarding the duplicate entries, that is, the display of bus stops without departure times, I need to look into that. But I consider it not critical due to the color coding.

Currently, I’m working on the category « RED Â», you remember. This involves departures that were not carried out, canceled, or postponed, and there’s still a missing note in the list of bus stops.

Best regards

Tom

Oh, does he consider each « side Â» of the station as its own? They’re actually right across from each other. With a bit of offset because there’s a tree, so it couldn’t be exactly opposite :joy: But in principle, it’s still pointless why the provider delivers it this way. A station always has the same name, no matter which direction or from which side you’re approaching it :man_shrugging:

General explanations about the structure:

  • The search circle is two-dimensional. This can lead to problems. An example to illustrate:
    The fire brigade is called, there is a fire in the street ABC in house 20. The fire brigade drives there, looks around… strange, nothing is burning. Until someone looks up, they are standing in front of a high-rise building and it is burning on the 25th floor.
    This has been found multiple times in the application and unfortunately cannot be corrected. Especially with cable cars in scheduled traffic or the same station name, which are spatially distant but have the same station ID.

There are many cable cars, for example in Toulouse, Barcelona, Heidelberg, etc. I get an ID in the search circle, but the station is hundreds of meters away and upwards.

  • The color coding: I am currently still looking for the possibility to display it clearly. But basically no problem with standard means of transport such as bus or train, also special means of transport such as airplane and ferry or cable cars.

With a small catch: There is the special case of the special case:
The same station, the same line, but no scheduled traffic.
Examples are:
Call taxi (Taxi takes over this line after prior call, as regular bus does not run) or

Moonliner (A ride at night on this line, but it does not belong to the reported scheduled traffic)

I currently display these special services on a reported line in gray. If this is the result, then it means: If there is a departure display: Departure is possible. Without departure display: There is special traffic at this station, but no departure in the display period.

Sounds quite complicated, but I have not yet found a way to store the color coding as a hint at this point.

Regards

Tom