Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
blocks:drivers:serial [2018-01-08 15:11]
admin created
blocks:drivers:serial [2023-08-25 13:37] (current)
admin Added note on serial through player USB
Line 1: Line 1:
-====== Controlling devices with RS242/RS485 serial data ======+====== Controlling devices with RS232/RS485 serial data ======
 While network control, using the TCP or UDP IP standards is preferable for best performance and reliability, While network control, using the TCP or UDP IP standards is preferable for best performance and reliability,
-some devices may only support control over a serial data (COM) port. Such devices can be controlled through a TCP-to-serial data bridge, such as the [[https://www.moxa.com/product/NPort_5100A.htm|MOXA NPort]] series of interface modules.+some devices may only support control over a serial data (COM) port. Such devices can be controlled eirther through a USB-to-Serial device connected to a USB port on a PIXILAB Player or  through a TCP-to-serial data bridge, such as the [[https://www.moxa.com/product/NPort_5100A.htm|MOXA NPort]] series of interface modules.
  
 ==== Prerequisites ==== ==== Prerequisites ====
  
-Before proceeding, make sure you have the following details:+Before proceeding, make sure you know the answers to the following quesions:
  
   * What's the physical connection? For RS232, this is often a standard 9-pin D-sub. If not, you may also need to source an adapter cable.   * What's the physical connection? For RS232, this is often a standard 9-pin D-sub. If not, you may also need to source an adapter cable.
Line 34: Line 34:
    
 This illustration shows how you set the IP address of the NPort 5110 (a single RS232 port interface). This illustration shows how you set the IP address of the NPort 5110 (a single RS232 port interface).
 +
 {{ :blocks:serial:moxa_network_settings.png?nolink |}} {{ :blocks:serial:moxa_network_settings.png?nolink |}}
  
Line 46: Line 47:
  
 This illustration shows how to set the operation mode of the NPort 5110. This illustration shows how to set the operation mode of the NPort 5110.
 +
 {{ :blocks:serial:moxa_operating_settings.png?nolink |}} {{ :blocks:serial:moxa_operating_settings.png?nolink |}}
  
Line 79: Line 81:
 === Using a Device Specific Driver === === Using a Device Specific Driver ===
  
-When using device driver specifically written to manage the device at hand, this driver exposes high level functions, such as input selection, power on/off, volume, etc, as appropriate for the device. Such properties can be directly connected to buttons and sliders, manipulated using a Task, or even be used to trigger a Task. The set of parameters and functions available is entirely dictated by the device driver.+When using [[blocks:drivers|device driver]] specifically written to manage the device at hand, this driver exposes high level functions, such as input selection, power on/off, volume, etc, as appropriate for the device. Such properties can be directly connected to buttons and sliders, manipulated using a Task, or even be used to trigger a Task. The set of parameters and functions available is entirely dictated by the device driver.
  
 Furthermore, a device driver can handle bi-directional communication with the device. This can be used to verify proper device response to command, pick up the device's initial state, or simply to expose some state of the device as read-only properties. Furthermore, a device driver can handle bi-directional communication with the device. This can be used to verify proper device response to command, pick up the device's initial state, or simply to expose some state of the device as read-only properties.
Line 90: Line 92:
   * Select the Task page.   * Select the Task page.
   * Add a Task, giving it a descriptive name.   * Add a Task, giving it a descriptive name.
-  * Add a /7do// statement, targeting the Network device by its name, and selecting the "sendText" command.+  * Add a //do// statement, targeting the Network device by its name, and selecting the "sendText" command.
   * Type the string to send to the device in the //toSend// field.   * Type the string to send to the device in the //toSend// field.
   * Type the desired line termination sequence into the //eoln// field (or leave blank to use a single carriage return).   * Type the desired line termination sequence into the //eoln// field (or leave blank to use a single carriage return).