Difference between revisions of "Second Life Railroad/SLRR Switch"

From Second Life Wiki
Jump to navigation Jump to search
m (→‎Background information: Correciont by Jer Straaf moved to talk page)
 
(49 intermediate revisions by 5 users not shown)
Line 15: Line 15:
|OldInfo=
|OldInfo=
}}  
}}  
{{hint
|mode=note
|desc=As with all wiki.secondlife pages that are not [[KB2Wiki#What_is_the_Linden_Lab_Official_namespace.3F | LL Official pages]], this article is open to edit as and when a resident feels it is appropriate (see [[Editing Guidelines]]). If however you simply wish to ask or make a suggestion about or discuss the railroad or the content of this article, please use the [[Talk:Second_Life_Railroad/SLRR_Switch|Talk page]]. The talk page is also where any disputes over proposed page content should be discussed. This Wiki (being a document of an ever changing world) is constantly in need of updating and improvement. If you are aware of information this article should have added/changed please go ahead and do so. If you do not feel confident about editing make the suggestion on the talk page and another contributor may be able to assist.
}}


{|style="width: 100%; font-size: 100%; background: #ffffff; border:1px solid #c0c0c0;"
{|style="width: 100%; font-size: 100%; background: #ffffff; border:1px solid #c0c0c0;"
Line 26: Line 31:
==Description==
==Description==
<div style="padding:0.5em">
<div style="padding:0.5em">
On the following page you find a concept of how a semi automated rail switch system could help users switch track.
The following page describes the working and standards used on the [[LDPW]] switch. The SLRR switch is part of the greater SLRR rail network and will be implemented over the next months.
 
If you have a different idea about the concept as descripted here you can use the [https://wiki.secondlife.com/wiki/Talk:Second_Life_Railroad/SLRR_Switch_concept Talk page] to add your comments, idea's and suggestions. Please don't add them in this text
</div></div>
</div></div>


Line 34: Line 37:


==Background information==
==Background information==
<div style="padding:0.5em">
<div style="padding:0.5em">
On the Northern Continent there are a few sections of railway lines. Some are under construction and other are in full operation. At the moment none of the 'Branch lines' or 'Pass tracks' are connected to each other. This is because there are no switch points to go from one track (guide rail) to an other.
On the Northern Continent (Heterocera Atoll) there are a few sections of railway line (see [[Second_Life_Railroad|SLRR Map]] ). Some are under construction and other are in full operation. The [[LDPW]] has started work to get the 'Branch lines' and 'Passing tracks' connected to each other. In order to do this a rail switch was designed by {{User2|Sylvan Mole}}.
 
Having the ability to switch from one track to the other is an essential part of any rail network. This can be done in many different ways. It depends on the type of guidance used to make the train move along the tracks. But also on the type of trains that use the system.


* One way to construct a switch point is to make a fully automated system that know where trains are on the line and sets the switches accordingly. This may limit the freedom of use of the SLRR tracks.
The basis for the design of the switch was the concept; "''The switch should work for the greatest number of existing rolling stock''". For that reason the switch is design without active scripts inside the guide rail prims. Most of the parts of the switch are mostly cosmetics. The actual switching is done by changing the (invisible) center guide rail. This is done in such a way that physical trains as well as sensor driven train can use the switch. (see below for more details).
* An other way is to construct a manual switch point. Giving the ability of user to choose what track they want to ride next. Either by e.g. a chat command or a touch to a control box. This would give [[Griefer|griefers]] the ability to derail SLRR train riders.
* A third option to construct a switch is a semi automated way. But stand-alone in the network. This would give even inexperienced SLRR user the ability to ride the SLRR tracks and the more experienced users full control over where they wanted to go.
 
On this page we are going to show a concept of an semi automated switch.


Some SL merchants already have made commercial version of a switch for the Guide rail available. Due to legal reasons the LDPW is not able to use these and therefor opted to make their own system.
</div></div>
</div></div>


Line 50: Line 49:


==Drawing==
==Drawing==
<div style="padding:0.5em">
<div style="padding:0.5em">
[[File:Points_expl.png|600px|center|Concept drawing semi automated switch]]
====Diagram of Switch parts====
* Guide rail  
 
[[File:Points_expl.png|600px|center|Drawing semi automated switch]]
* Guide rail (normally invisible but as example colored in)
*# white normal [[Second_Life_Railroad/SLRR_standards#Standards|Guide rail]]
*# white normal [[Second_Life_Railroad/SLRR_standards#Standards|Guide rail]]
*# green normal Guide rail on the switch named "Guide" and unlinked
*# green normal Guide rail on the switch named "'''Guide'''" made '''not phantom''', in other words, made solid
*# red switched off Guide rail and renamed "OFF-Guide" and made phantom and linked
*# red switched off Guide rail and renamed "'''Alternate Guide'''" and made '''phantom'''
* Control box
* Switch stand
* Detector
* Sensors
*# A for trains going down the main line
*# A for trains going down the main line, from the merge side toward the heading of the switch
*# B for trains going down the branch line toward the main line
*# B for trains going down the branch line, from the merge side toward the heading of the switch
*# Z for trains going up the main line or up the branch line
* Touch start Prim to allow SL Residents to change the switch setting
* Dwarf Signal Lights
 
====Switch stand signaling diagram====
 
[[File:SLRR_Switch_Signaling_1024.png|600px|center|Drawing of Swtich stand signaling]]


</div></div>
</div></div>
Line 67: Line 74:


==System description==
==System description==
<div style="padding:0.5em">
<div style="padding:0.5em">
The above semi automated system could be scripted to the following rules


<small>
===Basics===
===Basics===
</small>
 
*A Guide rail in use (direction of travel, depicted in green)
*A Guide rail in use (direction of travel, depicted in green)
  prim attributes
  prim attributes
Line 78: Line 84:
  - NOT phantom
  - NOT phantom
  - Material: Glass
  - Material: Glass
- Unlinked (if made up in more then 1 section)
  - Texture: Transparent  
  - Texture: Transparent  
*A Guide rail not in use (switched off, depicted in red)
*A Guide rail not in use (switched off, depicted in red)
  prim attributes
  prim attributes
  - prim name: 'OFF-Guide'
  - prim name: 'Alternate Guide'
  - phantom
  - phantom
  - Material: Glass
  - Material: Glass
- Linked (to save on open listener inside scripts)
  - Texture: Transparent  
  - Texture: Transparent  
*Control box can be given any shape or form. It houses the main scripts that talk to the Guide rail sections as well as the train Detectors A, B and Z.
*Switch Stand Signal rotates 90deg. to reveal appropriate signal. It houses the main scripts that talk to the Guide rail sections as well as the train sensors A and B.
*Detectors A, B, Z have collision based scripts in them and talk to the main script in the control box.
*Large invisible prim covering the Switch Stand to provide Touch start support (click-able switches)
*Sensors look straight up for 4 meters, sensing ACTIVE unflagged, with an arc as wide as the [[Second_Life_Railroad/SLRR_standards#SLRR_track_standards|Loading Gauge]]. If a train is detected it will automatically switch to the appropriate setting. However, If you go too fast into a merge they may miss detecting the train. As sensors fire only once per second.
*Dwarf Signal Lights on the Merge side of the switch display a Green or Red light. A green Dwarf Signal on the side of the merge you are on, means the switch is set correctly. A red Dwarf Signal on the side of the merge you are on, mean switch set incorrectly. Going on past a red light may cause trains to derail.


<small>
===Operational rules===
</small>
* If a train arrives at (has collided with) detector A the line switches automatically to allow the train to pass from A to Z
* If a train arrives at (has collided with) detector B the line switches automatically to allow the train to pass from B to Z
* If a train arrives at (has collided with) detector Z the line does not switches automatically


===Switch stand Prim/linkset parameters and changes and data string===


* If a train has collided with detector A or B the system can not be switched over (the train is on the switch point). As soon as the train passes detector Z the system is free to change direction again.
prim attributes
** if a train has collided with detector A or B but did not arrive after a given time passed detector Z the system needs to be reset automatically.
- prim name: 'Switch Stand'
* If a train has collided with detector Z the system can not be switched over (the train is on the switch point). As soon as the train passes detector A or B the system is free to change direction again.
- prim description: (see details below)
** if a train has collided with detector Z but did not arrive after a given time passed detector A or B the system needs to be reset automatically.
- phantom
- linked set: includes switch stand, touch prim and dwarf signals
- Texture: multiple
- Texture: full bright in parts
 
To provide touch support to each switch, there is a larger invisible cube placed over each switch (see drawing: purple box over the switch).<BR>
Simply hover your mouse over the area and click. These are very large and part of the linkset of the Switch.
 
The Object Description of the Switch Stand root prim holds a data string. This data will make it possible for train builders to semi-automate trains / train routes, as well as get enough information to message switches appropriately. i.e. control switches by sending messages 'main' or 'branch' to it.<BR>
 
String format -Identifier~Status~Heading Name~Mainline Name~Branch Name~messaging channel<BR>
Format uses ~ to separate fields of data and "." to designate hierarchies within fields
 
Notation example:
SimName.x.y.z~Main~Heading~Mainline~branch~channel


Live example:
Tuliptree.30.42.30~Branch~Calleta Station~TulipTree Station~VRC Yard~133


* If a train is near detector Z but has not yet collided with it the user can manually switch tracks by clicking the control box.
explanation of the live example:
* The switch is located in Tuliptree/30/42/30 (the coordinates reflect the root prim of the Switch Stands position)
* It is currently set to the branch
* The heading side goes to Calleta Station
* The main side goes to Tuliptree Station
* The branch side goes to VRC Yard
* It listens and talks on channel 133
 
So in this example the switch is set to the branch line that links the VRC-Yard in Tuliptree to the Calleta Station.
 
If the switch was turned the other way (to mainline going straight ahead) it would read:
Tuliptree.30.42.30~Main~Calleta Station~TulipTree Station~VRC Yard~133
 
The data string changes only the Status field during normal operation. The 'Status' field will display "Main" or "Branch" for train builders/scripters to sense and react.
 
The standard for the data string currently specifies the minimal info that a script can expect, but it is unclear if the standard forbids that extra information is added (and it should not). For maximal flexibility indexes could be used to read the data string from the description. Changes to the future data string inside the switches may happen. It is wise to plan for that when creating scripts that sense switches remotely.
 
===System messaging===
 
*All switch systems message on a unique channel published in the Object Description of the switch stand linkset.
*All switch systems listen for the message "Main" OR(not and) "Branch" on appropriate channel.
*All switch systems [[llShout]] (100 meter) "Main" or "Branch" on the same channel once switch has completed changes.
 
This allows signal changes up to 100 meters further up and down line. Including communication between LDPW construct and private installations.
 
===Sensors and mainline resets===
 
*Each switch installed on a mainline will reset to the mainline position 2.5 minutes after it is put in the branch position.
*On the merge side of each switch are two sensors. One for each side of the merge.  These effectively "Spring" the switch correctly for traffic heading into the merge.  When tripped they messages the switch and set it to the correct position.
*The [[llSensor]] scripts are placed in a prim 1.0x0.5x0.5 meter always with the X axis looking straight up and positioned/rotated with the top of the sensor flush with the top of the guide.
*These sensors look straight up for 4 meters, sensing ACTIVE unflagged, with an arc as wide as the Loading Gauge. However, If you go too fast into a merge they may miss detecting the train, as the sensors fire only once per second.
 
</div></div>
 
<div id="box">
 
==Scripts==
 
<div style="padding:0.5em">
 
It is the intention of the LDPW to publish scripts used in the switch setup here in the future.
*I would like to publish the sensor code here, so everyone can verify that their trains are being sensed.
*Also i would like to post some code showing some examples of data wrangling from the Switch Stand Description.
*Once approved, actual Switch code will be placed here as well.(Sylvan Mole)
 
Fine with me! (Michael Linden)


<b> CORRECTION: Locomotives that are phantom and non-physical will not trigger this system! A short-range avatar sensor would be useful in this situation to switch locomotives carrying an avatar. </b>  Jer Straaf
</div></div>
</div></div>


Line 113: Line 174:
==Source==
==Source==
<div style="padding:0.5em">
<div style="padding:0.5em">
The above information was collected by {{User2|Stryker Jenkins}}.
The above information was provided by LDPW {{User2|Sylvan Mole}} and edited for the wiki by {{User2|Stryker Jenkins}}. Thank You very much Stryker!  Information confirmed and minor edits added by {{User2|Sylvan Mole}}.
 
Linden Lab is currently the "operator" of the SLRR track. This is just a concept hoped to be of use to those who construct SLRR tracks.
</div></div>
</div></div>


<div id="box">
<div id="box">


==Also See==
==References==
<div style="padding:0.5em">
<div style="padding:0.5em">
Here is a list of Related resources. You can find more information about the SLRR and other Rail related articles on these wiki pages and external websites.
Wiki pages:
* [[Second_Life_Railroad]] (main page)
* [[Second_Life_Railroad]] (main page)
* [[Second_Life_Railroad/SLRR_standards|SLRR standards]]
* [[Second_Life_Railroad/SLRR_History|SLRR History]]
* [[Second_Life_Railroad/SLRR_standards|SLRR Standards]]
* [[Second_Life_Railroad/SLRR Switch|SLRR Switch]]
 
* [[LDPW|Linden Department of Public Works]]
* [[Linden_Vehicle_Tutorial]]
 
* [[Virtual_Railway_Consortium]] Group wiki page
* [[Virtual_Railway_Consortium/SLRR_History]] SLRR History main page compiled by the VRC
* [[Virtual_Railway_Consortium/SLRR_Stations]] SLRR and Resident station along the SLRR
 
External information:
* [http://en.wikipedia.org/wiki/Rail_gauge Wikipedia: Rail gauge]
* [http://en.wikipedia.org/wiki/Rail_gauge Wikipedia: Rail gauge]
* [http://lslwiki.net/lslwiki/wakka.php?wakka=physics Physics related LSL on LSLwiki.net]
* [http://lslwiki.net/lslwiki/wakka.php?wakka=vehicles Vehicle related LSL on LSLwiki.net]
* [http://www.virtualrailwayconsortium.org/ Virtual Railway Consortium]
</div></div>
</div></div>
[[Category:SL_Railroad]]

Latest revision as of 16:04, 24 January 2012


Emblem-important-yellow.png Note!

As with all wiki.secondlife pages that are not LL Official pages, this article is open to edit as and when a resident feels it is appropriate (see Editing Guidelines). If however you simply wish to ask or make a suggestion about or discuss the railroad or the content of this article, please use the Talk page. The talk page is also where any disputes over proposed page content should be discussed. This Wiki (being a document of an ever changing world) is constantly in need of updating and improvement. If you are aware of information this article should have added/changed please go ahead and do so. If you do not feel confident about editing make the suggestion on the talk page and another contributor may be able to assist.

Points ani.gif


Description

The following page describes the working and standards used on the LDPW switch. The SLRR switch is part of the greater SLRR rail network and will be implemented over the next months.

Background information

On the Northern Continent (Heterocera Atoll) there are a few sections of railway line (see SLRR Map ). Some are under construction and other are in full operation. The LDPW has started work to get the 'Branch lines' and 'Passing tracks' connected to each other. In order to do this a rail switch was designed by Sylvan Mole.

The basis for the design of the switch was the concept; "The switch should work for the greatest number of existing rolling stock". For that reason the switch is design without active scripts inside the guide rail prims. Most of the parts of the switch are mostly cosmetics. The actual switching is done by changing the (invisible) center guide rail. This is done in such a way that physical trains as well as sensor driven train can use the switch. (see below for more details).

Some SL merchants already have made commercial version of a switch for the Guide rail available. Due to legal reasons the LDPW is not able to use these and therefor opted to make their own system.

Drawing

Diagram of Switch parts

Drawing semi automated switch
  • Guide rail (normally invisible but as example colored in)
    1. white normal Guide rail
    2. green normal Guide rail on the switch named "Guide" made not phantom, in other words, made solid
    3. red switched off Guide rail and renamed "Alternate Guide" and made phantom
  • Switch stand
  • Sensors
    1. A for trains going down the main line, from the merge side toward the heading of the switch
    2. B for trains going down the branch line, from the merge side toward the heading of the switch
  • Touch start Prim to allow SL Residents to change the switch setting
  • Dwarf Signal Lights

Switch stand signaling diagram

Drawing of Swtich stand signaling

System description

Basics

  • A Guide rail in use (direction of travel, depicted in green)
prim attributes
- prim name: 'Guide'
- NOT phantom
- Material: Glass
- Texture: Transparent 
  • A Guide rail not in use (switched off, depicted in red)
prim attributes
- prim name: 'Alternate Guide'
- phantom
- Material: Glass
- Texture: Transparent 
  • Switch Stand Signal rotates 90deg. to reveal appropriate signal. It houses the main scripts that talk to the Guide rail sections as well as the train sensors A and B.
  • Large invisible prim covering the Switch Stand to provide Touch start support (click-able switches)
  • Sensors look straight up for 4 meters, sensing ACTIVE unflagged, with an arc as wide as the Loading Gauge. If a train is detected it will automatically switch to the appropriate setting. However, If you go too fast into a merge they may miss detecting the train. As sensors fire only once per second.
  • Dwarf Signal Lights on the Merge side of the switch display a Green or Red light. A green Dwarf Signal on the side of the merge you are on, means the switch is set correctly. A red Dwarf Signal on the side of the merge you are on, mean switch set incorrectly. Going on past a red light may cause trains to derail.


Switch stand Prim/linkset parameters and changes and data string

prim attributes
- prim name: 'Switch Stand'
- prim description: (see details below)
- phantom
- linked set: includes switch stand, touch prim and dwarf signals
- Texture: multiple
- Texture: full bright in parts

To provide touch support to each switch, there is a larger invisible cube placed over each switch (see drawing: purple box over the switch).
Simply hover your mouse over the area and click. These are very large and part of the linkset of the Switch.

The Object Description of the Switch Stand root prim holds a data string. This data will make it possible for train builders to semi-automate trains / train routes, as well as get enough information to message switches appropriately. i.e. control switches by sending messages 'main' or 'branch' to it.

String format -Identifier~Status~Heading Name~Mainline Name~Branch Name~messaging channel
Format uses ~ to separate fields of data and "." to designate hierarchies within fields

Notation example:
SimName.x.y.z~Main~Heading~Mainline~branch~channel
Live example:
Tuliptree.30.42.30~Branch~Calleta Station~TulipTree Station~VRC Yard~133

explanation of the live example:

  • The switch is located in Tuliptree/30/42/30 (the coordinates reflect the root prim of the Switch Stands position)
  • It is currently set to the branch
  • The heading side goes to Calleta Station
  • The main side goes to Tuliptree Station
  • The branch side goes to VRC Yard
  • It listens and talks on channel 133

So in this example the switch is set to the branch line that links the VRC-Yard in Tuliptree to the Calleta Station.

If the switch was turned the other way (to mainline going straight ahead) it would read:
Tuliptree.30.42.30~Main~Calleta Station~TulipTree Station~VRC Yard~133

The data string changes only the Status field during normal operation. The 'Status' field will display "Main" or "Branch" for train builders/scripters to sense and react.

The standard for the data string currently specifies the minimal info that a script can expect, but it is unclear if the standard forbids that extra information is added (and it should not). For maximal flexibility indexes could be used to read the data string from the description. Changes to the future data string inside the switches may happen. It is wise to plan for that when creating scripts that sense switches remotely.

System messaging

*All switch systems message on a unique channel published in the Object Description of the switch stand linkset.
*All switch systems listen for the message "Main" OR(not and) "Branch" on appropriate channel.
*All switch systems llShout (100 meter) "Main" or "Branch" on the same channel once switch has completed changes. 

This allows signal changes up to 100 meters further up and down line. Including communication between LDPW construct and private installations.

Sensors and mainline resets

  • Each switch installed on a mainline will reset to the mainline position 2.5 minutes after it is put in the branch position.
  • On the merge side of each switch are two sensors. One for each side of the merge. These effectively "Spring" the switch correctly for traffic heading into the merge. When tripped they messages the switch and set it to the correct position.
  • The llSensor scripts are placed in a prim 1.0x0.5x0.5 meter always with the X axis looking straight up and positioned/rotated with the top of the sensor flush with the top of the guide.
  • These sensors look straight up for 4 meters, sensing ACTIVE unflagged, with an arc as wide as the Loading Gauge. However, If you go too fast into a merge they may miss detecting the train, as the sensors fire only once per second.

Scripts

It is the intention of the LDPW to publish scripts used in the switch setup here in the future.

*I would like to publish the sensor code here, so everyone can verify that their trains are being sensed. 
*Also i would like to post some code showing some examples of data wrangling from the Switch Stand Description.
*Once approved, actual Switch code will be placed here as well.(Sylvan Mole)

Fine with me! (Michael Linden)

Source

The above information was provided by LDPW Sylvan Mole and edited for the wiki by Stryker Jenkins. Thank You very much Stryker! Information confirmed and minor edits added by Sylvan Mole.

References

Here is a list of Related resources. You can find more information about the SLRR and other Rail related articles on these wiki pages and external websites.

Wiki pages:

External information: