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

From Second Life Wiki
Jump to navigation Jump to search
 
(18 intermediate revisions by 2 users not shown)
Line 31: Line 31:
==Description==
==Description==
<div style="padding:0.5em">
<div style="padding:0.5em">
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.
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.
</div></div>
</div></div>


Line 92: Line 92:
  - Texture: Transparent  
  - 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.
*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 [[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.
*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.
*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.


===Touch Start===
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 not part of the linkset to avoid LOD and distance rendering issues.
prim attributes
- prim name: 'Switch Controller'
- prim description: 'say "Main" or "Branch" on 133' (channel may vary)
- phantom
- size: larger enough to cover the tracks and the 'Switch Stand'
- Texture: Transparent


===Switch stand Prim/linkset parameters and changes and data string===
===Switch stand Prim/linkset parameters and changes and data string===
Line 113: Line 103:
  - prim description: (see details below)
  - prim description: (see details below)
  - phantom
  - phantom
  - linked set: includes switch stand and dwarf signals
  - linked set: includes switch stand, touch prim and dwarf signals
  - Texture: multiple
  - Texture: multiple
  - Texture: full bright in parts
  - Texture: full bright in parts


Object Description of the Switch Stand root 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>
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>
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
Format uses ~ to separate fields of data and "." to designate hierarchies within fields
Line 128: Line 122:


explanation of the live example:
explanation of the live example:
* The switch is located in Tuliptree/30/42/30
* 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
* It is currently set to the branch
* The heading side goes to Calleta Station
* The heading side goes to Calleta Station
Line 141: Line 135:


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 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===
===System messaging===
Line 154: Line 150:
*Each switch installed on a mainline will reset to the mainline position 2.5 minutes after it is put in the branch position.
*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.
*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 and positioned on/inside the guide rail.
*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.
*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.


Line 166: Line 162:


It is the intention of the LDPW to publish scripts used in the switch setup here in the future.
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.
  *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)
  *Once approved, actual Switch code will be placed here as well.(Sylvan Mole)
Fine with me! (Michael Linden)


</div></div>
</div></div>
Line 180: Line 179:
<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_History|SLRR History]]
* [[Second_Life_Railroad/SLRR_History|SLRR History]]
* [[Second_Life_Railroad/SLRR_standards|SLRR standards]]
* [[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: