Elvas Tower: How to insert callon in sigscr.dat - Elvas Tower

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

How to insert callon in sigscr.dat Rate Topic: -----

#1 User is offline   Hannes44 

  • Fireman
  • Group: Status: Active Member
  • Posts: 161
  • Joined: 10-October 17
  • Gender:Male
  • Location:Select State/Province
  • Simulator:Open Rails
  • Country:

Posted 27 January 2021 - 11:48 AM

I've got problems making callon work. I couldn't find any precise information on how to insert the TrainHasCallon function in the sigscr.dat and where to put the $callon in the timetable. Maybe someone, who's more versed in sigscr.dat files than I am, could have a quick look at my sigscr.dat try. I'd also like to know where to put the $callon in the timetable, in the station line or the #note line? Thank you.



SCRIPT oebb_hs1980

extern float block_state();
extern float route_set();
extern float def_draw_state();
extern float sig_feature();
extern float state;
extern float draw_state;
extern float enabled;
extern float TrainHasCallOn();

if (!enabled || block_state() !=# BLOCK_CLEAR)
{
state = SIGASP_STOP;
draw_state = def_draw_state(state);
}
else if (enabled && route_set() && TrainHasCallOn() && block_state() == BLOCK_OCCUPIED

{
state = SIGASP_APPROACH_1;
draw_state = def_draw_state(state);
}
else if (block_state() ==# BLOCK_JN_OBSTRUCTED || !route_set())
{
if (sig_feature(SIGFEAT_USER1))
{
state = SIGASP_APPROACH_1;
draw_state = def_draw_state(state);
}
else
{
state = SIGASP_APPROACH_2;
draw_state = def_draw_state(state);
}
}
else if (sig_feature(SIGFEAT_USER3))
{
state = SIGASP_APPROACH_1;
draw_state = def_draw_state(state);
}
else if (sig_feature(SIGFEAT_USER4))
{
state = SIGASP_APPROACH_2;
draw_state = def_draw_state(state);
}
else
{
state = SIGASP_CLEAR_1;
draw_state = def_draw_state(state);
}

#2 User is offline   Vasi 

  • Apprentice
  • Group: Status: Switchman
  • Posts: 12
  • Joined: 11-January 20
  • Gender:Male
  • Simulator:Open Rails
  • Country:

Posted 27 January 2021 - 12:05 PM

I have started script with:

 if (block_state () == #BLOCK_OCCUPIED && TrainHasCallOn())
 state = 1; //choose your signal acpect
 else if... //continue with original code


This works for me in Czech signal script

#3 User is offline   roeter 

  • Vice President
  • Group: Status: Elite Member
  • Posts: 2,424
  • Joined: 25-October 11
  • Gender:Male
  • Country:

Posted 27 January 2021 - 12:27 PM

This bit is the problem :
if (!enabled || block_state() !=# BLOCK_CLEAR)
{
state = SIGASP_STOP;
draw_state = def_draw_state(state);
}


Obviously, callon is only usefull if the block ahead is occupied. So the block state will be BLOCK_OCCUPIED. As you test on NOT BLOCK_CLEAR, that will be 'true' and the signal will be set to stop.

This is now this bit should look like :
if (!enabled || block_state() ==# BLOCK_JN_OBSTRUCTED || !route_set())
{
state = SIGASP_STOP;
draw_state = def_draw_state(state);
}


All other references to enabled, BLOCK_JN_OBSTRUCTED and route_set() in the rest of the script can be removed as all three have now been captured here.

Regards,
Rob Roeterdink

#4 User is offline   Hannes44 

  • Fireman
  • Group: Status: Active Member
  • Posts: 161
  • Joined: 10-October 17
  • Gender:Male
  • Location:Select State/Province
  • Simulator:Open Rails
  • Country:

Posted 28 January 2021 - 03:34 AM

Thank you, now it works. Btw., does there anywhere exist a techdoc better than the microsoft one with all the script possibilities in sigscr.dat? For me working with sigscr.dat ist mostly guessing and hoping for the best.
Another question:what is the difference between "TrainHasCallOn" and "TrainHasCallOn_Restricted" ? They are mentioned in the manual but without explanation.

#5 User is offline   roeter 

  • Vice President
  • Group: Status: Elite Member
  • Posts: 2,424
  • Joined: 25-October 11
  • Gender:Male
  • Country:

Posted 28 January 2021 - 04:37 AM

Do you have the latest version of the OR manual? A couple of months ago, full details of all signal script functions have been added to the manual.
As for the difference between the two functions, this is what the manual says :

These functions are similar, except that TRAINHASCALLON will always allow CallOn if the route does not
lead into a platform, and therefor acts like a ‘permissive’ signal in that situation.
The function TRAINHASCALLON_RESTRICTED will only allow CallOn when one of the criteria is
met as detailed above.


And that "detailed above" refers to the list of condition which will allow callon.

Regards,
Rob Roeterdink

#6 User is offline   Hannes44 

  • Fireman
  • Group: Status: Active Member
  • Posts: 161
  • Joined: 10-October 17
  • Gender:Male
  • Location:Select State/Province
  • Simulator:Open Rails
  • Country:

Posted 28 January 2021 - 12:47 PM

Thank's for the answer, I'm using NewYearMg version and forgot, that there is no manual downloaded with these.

#7 User is offline   m61 

  • Fireman
  • PipPipPip
  • Group: Status: Fired
  • Posts: 163
  • Joined: 12-May 14
  • Gender:Male
  • Location:Bialobrzegi
  • Simulator:Open Rails
  • Country:

Posted 29 January 2021 - 10:02 AM

Polish routes to Open Rails use two versions of signaling. The first one is the "Signaling PKP version 3.x" project, which was suspended until further notice in 2011 http://www.ts-studio.eu07.pl/ . The second PLK signaling - version 1.4 is available to the public and can be downloaded and unpacked WinRar from https://or.trainsim....odatki-do-tras/ direct link https://or.trainsim....lizacja_1.4.rar . Due to the fact that the authors of these signals are not active in the work for Open Rails, I am asking for help in adapting the simulator to the new capabilities, mainly the callon function. For many years I have been trying to use the possibilities of Timetable mode, but adjusting the signaling is beyond my skills.

Marek

https://www.youtube....FSIYbL4sRM-VMd7

Attached File  Sygnalizacja_1.4.zip (10.05MB)
Number of downloads: 336
Attached File  Signaling PKP version 3.x.zip (26.88K)
Number of downloads: 327

#8 User is offline   Laci1959 

  • Foreman Of Engines
  • Group: Status: Contributing Member
  • Posts: 943
  • Joined: 01-March 15
  • Gender:Male
  • Simulator:Alföld
  • Country:

Posted 06 June 2021 - 02:33 AM

Hello

In reality, the Callon signal is often used even when the track is free. A typical example, if the green light on the signal is faulty, the traffic worker sets a Callon signal if the other conditions are present. Another example of using "TRAINHASCALLON_RESTRICTED". If an assembly from the storage is set on the free track of the station. In this case, the indicators for modern reversing tracks show the Restricted indicator. There are many reversing control indicators on such stations.
Sorry, if you don't understand, Google will translate.

Sincerely, Laci1959

Page 1 of 1
  • 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