Difference between revisions of "SHIP:Node:linkset"

From Serious Documentation
Jump to: navigation, search
(Created page with "A linkset node binds a protocol to a physical communications channel. Each channel in a platform may only be bound once to a sing...")
 
Line 1: Line 1:
A [[SHIP:Node:linkset|linkset]] node binds a protocol to a physical communications channel. Each channel in a [[SHIP:Node#platform|platform]] may only be bound once to a single protocol.  For example, UART0 can only be bound to a single protocol (e.g. [[SHIP:Protocols#Modbus_Master_RTU|MODBUS_MASTER_RTU]]).
+
Within a given link, there may be one or more linkset nodes. Each linkset encompasses all the traffic between two endpoints in a link.
  
 
== Parent Nodes ==
 
== Parent Nodes ==
 
The following nodes are permitted to hold this node:
 
The following nodes are permitted to hold this node:
* [[SHIP:Node:resource|resource]]
+
* [[SHIP:Node:link|link]]
  
 
== Child Nodes ==
 
== Child Nodes ==
 
The following nodes are permitted to exist within this node:
 
The following nodes are permitted to exist within this node:
* [[SHIP:Node:linkset|linkset]]
+
* [[SHIP:Node:linkvar|linkvar]]
* [[SHIP:Node:constant|constant]]
+
* [[SHIP:Node:const|const]]
  
 
== Properties ==
 
== Properties ==
 
{| class="wikitable" style="margin: 1em auto 1em auto;"  
 
{| class="wikitable" style="margin: 1em auto 1em auto;"  
! scope="col" | Property
+
! scope="col" | Property Name
 
! scope="col" | Description
 
! scope="col" | Description
 
|-
 
|-
| name|| A unique link name
+
| name|| A unique linkset name within the link
 
|-
 
|-
| protocol || The [[SHIP:Protocols|protocol]] bound to the channel (e.g. [[SHIP:Protocols#Modbus_Master_RTU|MODBUS_MASTER_RTU]])
+
| id || Some [[SHIP:Protocols|protocols]] require the endpoint to have an ID number assigned
 
|-
 
|-
 
| channel || A port name (e.g. UART0)
 
| channel || A port name (e.g. UART0)
Line 23: Line 23:
  
 
== Examples ==
 
== Examples ==
 +
 +
 +
[[File:SHIPTide-linkExample1.png|400px|border|center|Example link with two linksets]]
 +
 +
 +
 
For example, the following link binds a [[SHIP:Protocols#Modbus_Slave_ASCII|MODBUS_SLAVE_ASCII]] protocol to UART0 on a [[SIM110]]:
 
For example, the following link binds a [[SHIP:Protocols#Modbus_Slave_ASCII|MODBUS_SLAVE_ASCII]] protocol to UART0 on a [[SIM110]]:
  
Line 35: Line 41:
 
| channel || platform.UART0
 
| channel || platform.UART0
 
|}
 
|}
 +
 +
 +
 +
On the slave side of master/slave protocols (for example the [[SHIP:Protocols#Modbus_Slave_RTU|MODBUS_SLAVE_RTU]]), the link may be representing one or more Modbus slaves within the SHIPEngine environment.  Even though the protocol is running on a single physical communications channel (e.g. UART0), each linkset within the link can act as one of a number of independent virtual slaves.
 +
 +
On the master side of master/slave protocols (for example [[SHIP:Protocols#Modbus_Master_ASCII|MODBUS_MASTER_ASCII]]) you may want to address multiple slaves on the channel.  Each slave would be identified by a linkset with the slave ID set appropriately.
 +
 +
Adding two linksets to our prior example might look like this:
 +
 +
[[File:SHIPTide-linkExample1.png|400px|border|center|Example link with two linksets]]
 +
 +
In this example, our GUI is acting as a Modbus Slave attached to UART0, potentially one of many on the communications channel.  This physical channel could be, for instance, a multi-drop RS485 network with many slaves of which our [[SIMs|SIM]] is only one.  Our GUI, because it has the two linksets at ID #1 and #13 created, will respond as if it were two of those slaves on the network.

Revision as of 14:48, 25 November 2012

Within a given link, there may be one or more linkset nodes. Each linkset encompasses all the traffic between two endpoints in a link.

Parent Nodes

The following nodes are permitted to hold this node:

Child Nodes

The following nodes are permitted to exist within this node:

Properties

Property Name Description
name A unique linkset name within the link
id Some protocols require the endpoint to have an ID number assigned
channel A port name (e.g. UART0)

Examples

Example link with two linksets


For example, the following link binds a MODBUS_SLAVE_ASCII protocol to UART0 on a SIM110:

Property Value
name myModbusSlave
protocol MODBUS_SLAVE_ASCII
channel platform.UART0


On the slave side of master/slave protocols (for example the MODBUS_SLAVE_RTU), the link may be representing one or more Modbus slaves within the SHIPEngine environment. Even though the protocol is running on a single physical communications channel (e.g. UART0), each linkset within the link can act as one of a number of independent virtual slaves.

On the master side of master/slave protocols (for example MODBUS_MASTER_ASCII) you may want to address multiple slaves on the channel. Each slave would be identified by a linkset with the slave ID set appropriately.

Adding two linksets to our prior example might look like this:

Example link with two linksets

In this example, our GUI is acting as a Modbus Slave attached to UART0, potentially one of many on the communications channel. This physical channel could be, for instance, a multi-drop RS485 network with many slaves of which our SIM is only one. Our GUI, because it has the two linksets at ID #1 and #13 created, will respond as if it were two of those slaves on the network.