Difference between revisions of "Component: DMX 512 Master (Comms: System)"

From Flowcode Help
Jump to navigationJump to search
 
(12 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
+
{| style="width:50%"
 
 
{| width="50%"
 
 
|-
 
|-
| width="20%" style="color: gray;" | Author
+
| width="20%" style="color:gray;" | Author
 
| MatrixTSL
 
| MatrixTSL
 
|-
 
|-
| width="20%" style="color: gray;" | Version
+
| width="20%" style="color:gray;" | Version
| 2.0 (Release)
+
| 2.0
 
|-
 
|-
| width="20%" style="color: gray;" | Category
+
| width="20%" style="color:gray;" | Category
 
| Comms: System
 
| Comms: System
 
|}
 
|}
  
  
 +
==DMX-512 Master component==
 +
A serial based communications protocol designed for controlling theatrical equipment such as dimmers, fog machines and intelligent lights. DMX-512 Slave devices are daisy chained  together with a final 180R terminating resistor at the end of the chail. DMX requires the signal to be level shifted from VCC and GND to +2.5V and -2.5V.
  
==[[File:Component Icon b4e10f9e_4ea9_4fbc_a584_a4d7d4d8fba6.png|Image]] DMX_512 Master component==
+
==Component Pack==
A serial based communications protocol designed for controlling theatrical equipment such
 
as dimmers, fog machines and intelligent lights. DMX-512 Slave devices are daisy chained
 
together with a final 180R terminating resistor at the end of the chail. DMX requires the signal
 
to be level shifted from VCC and GND to +2.5V and -2.5V.
 
  
==Examples==
+
COMMSC
DMX Master Example, reads the value of two ports using switch arrays to set the values and then transmits the data in a DMX packet.
 
  
{{Fcfile|DMX_Master_Example1.fcfx|DMX Master Example1}}
+
==Detailed description==
  
  
DMX Slave Example, captures the first DMX data channel sent from the Master and outputs the value onto a Port using the LED array component.
 
  
{{Fcfile|DMX_Slave_Example1.fcfx|DMX Slave Example1}}
 
  
==Downloadable macro reference==
 
  
===<span style="font-weight: normal;"><u><tt>SetDataChannel</tt></u></span>===
 
Sets the data byte in a data channel
 
  
'''Parameters'''
 
  
:[[Variable Types|UINT]] ''Channel''
 
  
:[[Variable Types|BYTE]] ''DataValue''
 
  
  
'''Return value'''
 
  
:''This call does not return a value''
 
  
  
===<span style="font-weight: normal;"><u><tt>SendDataChain</tt></u></span>===
 
Transmits the BREAK, MAB and StartCode followed by the contents of the data channels.
 
  
'''Parameters'''
 
  
:[[Variable Types|BYTE]] ''StartCode''
+
''No detailed description exists yet for this component''
  
  
'''Return value'''
 
  
:''This call does not return a value''
+
==Examples==
  
  
===<span style="font-weight: normal;"><u><tt>Initialise</tt></u></span>===
 
Configures the UART serial interface.
 
  
'''Parameters'''
 
  
:''This macro has no parameters''
 
  
  
'''Return value'''
 
  
:''This call does not return a value''
 
  
  
  
==Simulation macro reference==
 
  
''This component does not contain any simulation macros''
 
  
  
==Property reference==
 
<span style="font-weight: normal;"><u>Channel</u></span>
 
  
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_uart::CHANNEL''.
 
  
UART Channel selector
 
  
Software channels are bit banged using generic I/O pins but are not as reliable as hardware channels.
 
  
Hardware channels use the selected peripheral on-board the target microcontroller.
+
DMX Master Example, reads the value of two ports using switch arrays to set the values and then transmits the data in a DMX packet.
  
<span style="font-weight: normal;"><u>Baud Options</u></span>
+
{{Fcfile|DMX_Master_Example1.fcfx|DMX Master Example1}}
  
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_uart::BAUD_LIST''.
 
  
Baud rate option selector
+
For DMX 512 slave example see: [[Component: DMX 512 Slave (Comms: System)]]
  
<span style="font-weight: normal;"><u>Baud Rate</u></span>
+
==Downloadable macro reference==
  
This property is of type ''Signed integer'' and can be referenced with the variable name ''cal_uart::BAUD''.
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 +
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDataChannel'''
 +
|-
 +
| colspan="2" | Sets the data byte in a data channel&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
 +
| width="90%" | Channel
 +
|-
 +
| colspan="2" | &nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | DataValue
 +
|-
 +
| colspan="2" | &nbsp;
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
''<span style="color:red;">No additional information</span>''
 
  
 +
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 +
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SendDataChain'''
 +
|-
 +
| colspan="2" | Transmits the BREAK, MAB and StartCode followed by the contents of the data channels.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | StartCode
 +
|-
 +
| colspan="2" | &nbsp;
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
  
<span style="font-weight: normal;"><u>TX</u></span>
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 +
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Initialise'''
 +
|-
 +
| colspan="2" | Configures the UART serial interface.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
This property is of type ''Single digital pin'' and can be referenced with the variable name ''cal_uart::TX''.
 
  
Pin to be used for Transmit data
 
  
<span style="font-weight: normal;"><u>Data Channels</u></span>
 
  
This property is of type ''Unsigned integer'' and can be referenced with the variable name ''DataChannels''.
+
==Property reference==
  
Number of data bytes used by the DMX chain, Max 512 bytes per transmission.
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
+
|-
24 Bytes minimum to match minimum 1204us timing requirements, not all channels need to be used.
+
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
 
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''
<span style="font-weight: normal;"><u>Scope Traces</u></span>
+
|-
 
+
|-
This property is of type ''True or false'' and can be referenced with the variable name ''cal_uart::ScopeTraces''.
+
| width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]]
 
+
| width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Serial Properties
Selects if the scope traces are automatically added to the data recorder window or not.
+
|-
 
+
|-
     Simulation - draws an approximation of the UART data onto the scope trace.
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 
+
| width="90%" | Channel
     ICT - sets up the scope trace for incoming data and adds UART packet decoding at the correct BAUD.
+
|-
 
+
| colspan="2" | UART Channel selector Software channels are bit banged using generic I/O pins but are not as reliable as hardware channels. Hardware channels use the selected peripheral on-board the target microcontroller.&nbsp;
<span style="font-weight: normal;"><u>Console Data</u></span>
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
This property is of type ''True or false'' and can be referenced with the variable name ''cal_uart::ConsoleData''.
+
| width="90%" | Baud Options
 
+
|-
Selects if the console data is automatically generated or not
+
| colspan="2" | Baud rate option selector&nbsp;
 
+
|-
<span style="font-weight: normal;"><u>Console Columns</u></span>
+
| width="10%" align="center" | [[File:Fc9-type-14-icon.png]]
 
+
| width="90%" | Baud Rate
This property is of type ''Unsigned integer'' and can be referenced with the variable name ''cal_uart::ConsoleColumns''.
+
|-
 
+
| colspan="2" | &nbsp;
Number of characters that can be displayed on a single line of the console.
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-5-icon.png]]
<span style="font-weight: normal;"><u>Data Source</u></span>
+
| width="90%" | TX
 
+
|-
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''cal_uart::DataSource''.
+
| colspan="2" | Pin to be used for Transmit data&nbsp;
 
+
|-
Simulation data source used to allow the component to connect to various remote devices
+
| width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]]
 
+
| width="90%" style="background-color:#EAE1EA; color:#4B008D;" | DMX Properties
     Nothing - Simulation data is ignored
+
|-
 
+
|-
     COM port - Routes the communication data to and from a physical or virtual COM port  
+
| width="10%" align="center" | [[File:Fc9-type-21-icon.png]]
 
+
| width="90%" | Data Channels
    Injector - Routes the communication data via a data injector component on the Panel.
+
|-
 +
| colspan="2" | Number of data bytes used by the DMX chain, Max 512 bytes per transmission. 24 Bytes minimum to match minimum 1204us timing requirements, not all channels need to be used.&nbsp;
 +
|-
 +
| width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]]
 +
| width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Simulation
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 +
| width="90%" | Scope Traces
 +
|-
 +
| colspan="2" | Selects if the scope traces are automatically added to the data recorder window or not.    Simulation - draws an approximation of the UART data onto the scope trace.    ICT - sets up the scope trace for incoming data and adds UART packet decoding at the correct BAUD.&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 +
| width="90%" | Console Data
 +
|-
 +
| colspan="2" | Selects if the console data is automatically generated or not&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-type-21-icon.png]]
 +
| width="90%" | Console Columns
 +
|-
 +
| colspan="2" | Number of characters that can be displayed on a single line of the console.&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 +
| width="90%" | Data Source
 +
|-
 +
| colspan="2" | Simulation data source used to allow the component to connect to various remote devices    Nothing - Simulation data is ignored    COM port - Routes the communication data to and from a physical or virtual COM port     Injector - Routes the communication data via a data injector component on the Panel.&nbsp;
 +
|}

Latest revision as of 17:19, 9 November 2022

Author MatrixTSL
Version 2.0
Category Comms: System


DMX-512 Master component

A serial based communications protocol designed for controlling theatrical equipment such as dimmers, fog machines and intelligent lights. DMX-512 Slave devices are daisy chained together with a final 180R terminating resistor at the end of the chail. DMX requires the signal to be level shifted from VCC and GND to +2.5V and -2.5V.

Component Pack

COMMSC

Detailed description

No detailed description exists yet for this component


Examples

DMX Master Example, reads the value of two ports using switch arrays to set the values and then transmits the data in a DMX packet.

FC6 Icon.png DMX Master Example1


For DMX 512 slave example see: Component: DMX 512 Slave (Comms: System)

Downloadable macro reference

Fc9-comp-macro.png SetDataChannel
Sets the data byte in a data channel 
Fc9-u16-icon.png - UINT Channel
 
Fc9-u8-icon.png - BYTE DataValue
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SendDataChain
Transmits the BREAK, MAB and StartCode followed by the contents of the data channels. 
Fc9-u8-icon.png - BYTE StartCode
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
Configures the UART serial interface. 
Fc9-void-icon.png - VOID Return



Property reference

Fc9-prop-icon.png Properties
Fc9-conn-icon.png Serial Properties
Fc9-type-16-icon.png Channel
UART Channel selector Software channels are bit banged using generic I/O pins but are not as reliable as hardware channels. Hardware channels use the selected peripheral on-board the target microcontroller. 
Fc9-type-16-icon.png Baud Options
Baud rate option selector 
Fc9-type-14-icon.png Baud Rate
 
Fc9-type-5-icon.png TX
Pin to be used for Transmit data 
Fc9-conn-icon.png DMX Properties
Fc9-type-21-icon.png Data Channels
Number of data bytes used by the DMX chain, Max 512 bytes per transmission. 24 Bytes minimum to match minimum 1204us timing requirements, not all channels need to be used. 
Fc9-conn-icon.png Simulation
Fc9-type-7-icon.png Scope Traces
Selects if the scope traces are automatically added to the data recorder window or not. Simulation - draws an approximation of the UART data onto the scope trace. ICT - sets up the scope trace for incoming data and adds UART packet decoding at the correct BAUD. 
Fc9-type-7-icon.png Console Data
Selects if the console data is automatically generated or not 
Fc9-type-21-icon.png Console Columns
Number of characters that can be displayed on a single line of the console. 
Fc9-type-16-icon.png Data Source
Simulation data source used to allow the component to connect to various remote devices Nothing - Simulation data is ignored COM port - Routes the communication data to and from a physical or virtual COM port Injector - Routes the communication data via a data injector component on the Panel.