Elvas Tower: Open Rails API - Elvas Tower

Jump to content

  • 3 Pages +
  • 1
  • 2
  • 3
  • You cannot start a new topic
  • You cannot reply to this topic

Open Rails API Rate Topic: -----

#11 User is offline   Genma Saotome 

  • Owner Emeritus and Admin
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 15,336
  • Joined: 11-January 04
  • Gender:Male
  • Location:United States
  • Simulator:Open Rails
  • Country:

Posted 17 February 2021 - 12:50 PM

View Poststeved, on 01 November 2020 - 07:55 AM, said:

It's available with the MonoGame version.
Is way cool.


(regarding OR sending information to en external device)

Is there a guide that makes this easy to implement? I use the Monogame version all of the time and I'd like to see how this new feature works.

#12 User is offline   cjakeman 

  • Vice President
  • PipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 2,866
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 18 February 2021 - 11:12 AM

View PostGenma Saotome, on 17 February 2021 - 12:50 PM, said:

Is there a guide that makes this easy to implement? I use the Monogame version all of the time and I'd like to see how this new feature works.

It's in the Testing Version too with a little bit of documentation in the manual. (As always, thise needs some attention.)

The web pages are included in the folder Content\Web\ so you can copy and tinker with the files as you wish. The simplest one is APISample which shows how to get data and display it.

You can see what's happening by selecting the Options > General > Web Server = checked and pressing Start. Then, from any browser on your PC, enter localhost:2150 to see a menu page.You can also do this from other devices, but use 192.168.1.99 or whatever the IP is on your Open Rails PC.

The idea is to supplement the existing 5 APIs with more. I want one to use with timetables.

#13 User is offline   BB22210 

  • Fireman
  • Group: Status: Active Member
  • Posts: 177
  • Joined: 24-August 17
  • Gender:Male
  • Location:Earth
  • Simulator:OpenRail
  • Country:

Posted 18 February 2021 - 09:59 PM

View Postcjakeman, on 18 February 2021 - 11:12 AM, said:

It's in the Testing Version too with a little bit of documentation in the manual. (As always, thise needs some attention.)

The web pages are included in the folder Content\Web\ so you can copy and tinker with the files as you wish. The simplest one is APISample which shows how to get data and display it.

You can see what's happening by selecting the Options > General > Web Server = checked and pressing Start. Then, from any browser on your PC, enter localhost:2150 to see a menu page.You can also do this from other devices, but use 192.168.1.99 or whatever the IP is on your Open Rails PC.

The idea is to supplement the existing 5 APIs with more. I want one to use with timetables.

Hello,
Why only few of Json datas are available but not ALL HUD datas (speed, speed control KVB status, volt, amp, pressure, etc ...) ?
Could pressure datas be Json displayed in separate lines ?

Rgds
BB22210

#14 User is offline   cjakeman 

  • Vice President
  • PipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 2,866
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 19 February 2021 - 09:15 AM

Hi Christophe,

View PostBB22210, on 18 February 2021 - 09:59 PM, said:

Why only few of Json datas are available but not ALL HUD datas (speed, speed control KVB status, volt, amp, pressure, etc ...) ?

Perhaps an oversight.

Shouldn't be difficult to fix so please add a Blueprint Request on Launchpad for the missing items and I'll see what I can do.

#15 User is offline   Howky 

  • Fireman
  • Group: Status: Active Member
  • Posts: 247
  • Joined: 14-February 13
  • Gender:Male
  • Location:Czech Republic
  • Simulator:Open Rails
  • Country:

Posted 20 March 2021 - 02:49 AM

Will there be instructions on how to use Api functions?

#16 User is offline   pgs 

  • Apprentice
  • Group: Status: Dispatcher
  • Posts: 19
  • Joined: 17-April 21
  • Gender:Male
  • Simulator:MSTS,OR,MASZYNA
  • Country:

Posted 05 May 2021 - 03:49 AM

Good afternoon friends.
I introduce myself.
I am Pablo from Spain, train engineer.
I am testing the OR APIs for a small project and have noticed that there are a lot of repeating parameters.
I was looking for information within my little programming experience to modify or create those APIs.
Thank you very much and have a good day.

#17 User is offline   cjakeman 

  • Vice President
  • PipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 2,866
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 05 May 2021 - 09:53 AM

Hi Pablo,

View Postpgs, on 05 May 2021 - 03:49 AM, said:

I am testing the OR APIs for a small project and have noticed that there are a lot of repeating parameters.
I was looking for information within my little programming experience to modify or create those APIs.

Welcome to Elvas Tower.

The Web APIs are fairly new. They make a lot of data available, but not everything yet.

If you can tell us what data you are looking for, we can help you find it or write code to make it available.

#18 User is offline   Howky 

  • Fireman
  • Group: Status: Active Member
  • Posts: 247
  • Joined: 14-February 13
  • Gender:Male
  • Location:Czech Republic
  • Simulator:Open Rails
  • Country:

Posted 06 May 2021 - 10:11 AM

View Postcjakeman, on 05 May 2021 - 09:53 AM, said:

Hi Pablo,


Welcome to Elvas Tower.

The Web APIs are fairly new. They make a lot of data available, but not everything yet.

If you can tell us what data you are looking for, we can help you find it or write code to make it available.


control signals and switch ?

#19 User is offline   cjakeman 

  • Vice President
  • PipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 2,866
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 07 May 2021 - 10:22 AM

View PostHowky, on 06 May 2021 - 10:11 AM, said:

control signals and switch ?

Do you mean the ability to release signals and change over switches through the Web API?

Our Web API is currently read-only and doesn't accept any inputs. This is something we want to change.

#20 User is offline   cjakeman 

  • Vice President
  • PipPipPipPipPipPipPipPip
  • Group: ET Admin
  • Posts: 2,866
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 07 May 2021 - 10:44 AM

Hi Christophe,

View PostBB22210, on 06 May 2021 - 11:50 PM, said:

Is KVB (speed control controler) activated inside API ? If yes what is the variable to be catched ?

Do you mean the TrainControlSystem, which I believe is a controller specified by a loaded script?

No, there isn't an API for this data yet. I understand the TrainControlSystem, being scripted, can do pretty much anything. The API will need some careful design to provide access suitable for all possible TrainControlSystem. Serana knows a lot about this topic.

  • 3 Pages +
  • 1
  • 2
  • 3
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users