New signalling functions OR specific signalling functions added in version 2266
#61
Posted 30 April 2020 - 06:36 AM
But your answer wakes up one more question, I'm sorry =)
Does it exist a "default setting" for variable value on the beginning of the scrit at start of simulation or after the save? "0" maybe? Or the value is "unknown"?
#62
Posted 30 April 2020 - 09:50 AM
#63
Posted 30 April 2020 - 10:09 AM
VicenteIR, on 30 April 2020 - 09:50 AM, said:
No. Back-facing heads are split from other heads and form a separate signal (signal object, to be precise).
If there are multiple back-facing heads, these are collected in a single signal.
The reason for this is that a signal can have only one direction. Signal and train control would become very complicated if signals could work in both directions.
And yes, default value for variables is 0.
Regards,
Rob Roeterdink
#65
Posted 15 May 2020 - 11:58 PM
roeter, on 21 July 2017 - 02:42 AM, said:
SCRIPT ChLEinffrei // CHL Einfahrsignal // freie Fahrt Fahrbegriff 1, wenn Signal enabled, Block frei und die Weichen für diese Route gestellt sind extern float block_state (); extern float state; extern float enabled; float blockfrei; blockfrei = -1; if (block_state() ==# BLOCK_CLEAR ) { blockfrei = 1; } else if (block_state() ==# BLOCK_OCCUPIED && TRAINHASCALLON_RESTRICTED() && APPROACH_CONTROL_POSITION(300)) { blockfrei = 2; } // If required, show the 'stop' indication. if (!enabled || !route_set() || blockfrei < 0) { state = SIGASP_STOP; } // Signal is enabled and the block ahead is clear else { state = SIGASP_CLEAR_2; }
This script uses TRAINHASCALLON_RESTRICTED() which has a number of advantages over TRAINHASCALLON() :
- The call-on test is only performed if the route from the signal leads into a platform.
If signals of this type are also used on 'free line' locations (i.e. on normal running lines not leading into platforms), the behaviour at such locations is not affected. - The call-on test is only linked to specific timetable commands ($callon, $attach, $pickup and $transfer), behaviour in activity mode is not affected.
In this example, the signal has no special aspect in case of call on, and so the actual value of 'blockfrei' (German for 'blockclear') is not used - there's only a check on <0.
If the signal does have a specific aspect, the actual value of 'blockfrei' can be used to set the normal 'clear' aspect (if blockfrei == 1) or the call-on aspect (if blockfrei == 2).
Because there is no special aspect, approach control is applied in case of calling-on with the signal held at danger until the train is at 300m. distance from the signal.
Regards,
Rob Roeterdink
Sorry Google translates, I hope it will be understood.
In reality, track design and electronic safety devices also apply this function to free track. It informs the driver that it will not proceed as a train but as a reversing to the next stop signal.
Laci 1959
#66
Posted 25 July 2020 - 01:06 PM
This Signal is showing clear if the track is free and the Entrance-Signal is showing clear. But if the entrance-Signal is showing a lower Aspect it is showing the Warning-Drawstate for this lower Aspect at the Entrance-Signal.
If a Train with CallOn is arriving before the combined MainSignal it is showing Warning for Stop at the entrance Signal because the Entrance-Signal will clear for CallOn only after the Train has passed this combined Signal.
Is there any Possibility to open the Entrance-Signal with CallOn before the train has arrived at the combined-Signal, so this can show Warning for CallOn at the Entrance-Signal?
Regards
EugenR
There are more and more such combined Signals as the Swiss Railway Signalsystem N
#67
Posted 11 August 2020 - 02:31 AM
eugenR, on 25 July 2020 - 01:06 PM, said:
This Signal is showing clear if the track is free and the Entrance-Signal is showing clear. But if the entrance-Signal is showing a lower Aspect it is showing the Warning-Drawstate for this lower Aspect at the Entrance-Signal.
If a Train with CallOn is arriving before the combined MainSignal it is showing Warning for Stop at the entrance Signal because the Entrance-Signal will clear for CallOn only after the Train has passed this combined Signal.
Is there any Possibility to open the Entrance-Signal with CallOn before the train has arrived at the combined-Signal, so this can show Warning for CallOn at the Entrance-Signal?
Regards
EugenR
There are more and more such combined Signals as the Swiss Railway Signalsystem N
The Functions TrainHasCallOn() and TrainHasCallOn_Restricted(), to use in the file sigscr.dat, have the following Problem:
If a Distant-Signal is placed before the Signal with a CallOn-Aspect, all is o.k., but if the Signal before this CallOn-Signal is a combined Main/Distant-Signal, and the Train is arriving before this combined Signal, this will show “Warning Stop at the Next Signal”, instead of the Warning-Aspect for CallOn, because this functions are opening the CallOnl-Aspect only if the train is entered in the Block before this CallOn-Signal.
To avoid this, Rob has defined two similar Functions, TrainHasCallOn_Advanced() and TrainHasCallOn_Restricted_Advanced(). These functions are opening the Signal with the CallOn-Aspect depending of the Parameter SignalNumClearAhead(x) (in the file sigcfg.dat), of the preceding signals. This will be introduced in one of the next Releases.
Regards
Eugenr
#68
Posted 11 August 2020 - 05:53 AM
eugenR, on 11 August 2020 - 02:31 AM, said:
To avoid this, Rob has defined two similar Functions, TrainHasCallOn_Advanced() and TrainHasCallOn_Restricted_Advanced(). These functions are opening the Signal with the CallOn-Aspect depending of the Parameter SignalNumClearAhead(x) (in the file sigcfg.dat), of the preceding signals. This will be introduced in one of the next Releases.
Regards
Eugenr
The feature is now available in U2020.08.11-1351.
#69
Posted 17 October 2020 - 09:18 AM
I am not sure if this is the right thread in which to put all of our signalling questions, I have a number of questions regarding signalling systems I would like to set up. Here is the first question, concerning an unusual and possibly unique type of signalling.
The real life system (after electrification):
Double track sections - there were no signals - operation was permissive drive on sight and stop if you see another train ahead.
Single track sections - a signal at the entrance to each section - approach controlled
Three possible indications
( i ) No indication = assume danger (fail safe) = STOP (train may approach signal to obtain white for permission to enter section)
( ii ) White - two meanings is a problem here
(a) If white is shown prior to approaching the signal it means a train is proceeding in the same direction on the single track section - driver must wait for the train ahead to clear the section - and the signal to return to no indication - at which point train may approach for permission to enter section = STOP
(B) If no indication is shown until the signal is approached then white gives permission to enter the section = CLEAR 2
( iii ) Red - a train travelling in the opposite direction is in the section = STOP
The method of operation was simple - if the signal was approached a white indication is given at one end of the section and red at the other - both continue to show until the train leaves the section. There was a mechanism to prevent stand offs which gave priority to trains travelling in one direction.
So how to model this in Open Rails?
I am thinking the best way is to use three types of signal.
For the double line sections use a hidden (underground) signal that permanently displays a Train Has Call On aspect.
For the single line sections use two signals, a hidden ( underground ) signal ahead of the actual signal.
The hidden signal would have two aspects - APPROACH 1 and STOP - such that if the section ahead is not occupied it shows APPROACH 1 (yellow in HuD) allowing driver or AI train to approach the section signal.
If the block is occupied then then it would show STOP in the HuD or for the AI train.
The section signal would normally show STOP and would use Approach_Control_Req_Position to change to CLEAR (for the HuD or AI train) as the train approaches it.
At this point I am getting stuck - although when the train goes into the block the signal will now mean STOP for any following train - the white indication needs to remain showing in the model - with red being shown at the other end of the section. Is there as yet any way to know in which direction the train in the section is travelling? so we can use
Block occupied - train moving towards signal - shows red
Block occupied - train moving away from signal - shows white
Also if two trains approach opposite ends of the section at the same time is there a way to set priority for one direction and avoid those horrible stand offs that happened so often on signle line in MSTS?
#70
Posted 17 October 2020 - 01:54 PM
darwins, on 17 October 2020 - 09:18 AM, said:
Block occupied - train moving towards signal - shows red
Block occupied - train moving away from signal - shows white
for Blockstate and CallOn please read Manual 10.15.3 (and compare with 10.15.4) in a new testing version
Block_Occupied is only thrue if the block is occupied by a Train in the same direction!!
regards
EugenR