Difference between revisions of "Component: K8055D (Third Party)"

From Flowcode Help
Jump to navigationJump to search
 
(5 intermediate revisions by the same user not shown)
Line 17: Line 17:
 
==Component Source Code==
 
==Component Source Code==
  
Please click here to download the component source project: [https://www.flowcode.co.uk/wikicopy/componentsource/FC_Comp_Source_K8055D.fcsx FC_Comp_Source_K8055D.fcsx]
+
Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_K8055D.fcsx FC_Comp_Source_K8055D.fcsx]
  
 
Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_K8055D.fcsx FC_Comp_Source_K8055D.fcsx]
 
Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_K8055D.fcsx FC_Comp_Source_K8055D.fcsx]
Line 29: Line 29:
  
  
''No detailed description exists yet for this component''
 
  
==Examples==
 
  
  
  
 +
''No detailed description exists yet for this component''
  
 +
==Examples==
  
  
  
''<span style="color:red;">No additional examples</span>''
 
  
==Macro reference==
 
  
{| 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;" | '''GetCount'''
 
|-
 
| colspan="2" | Read the value of the chosen counter for the currently selected board.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | The counter to read (1 or 2)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
  
  
{| 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;" | '''GetAnalogIn'''
 
|-
 
| colspan="2" | Read analog input 1 or 2&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Input
 
|-
 
| colspan="2" | Which input to read (1 ro 2)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
  
  
{| 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;" | '''SetAnalogOut'''
 
|-
 
| colspan="2" | Sets the chosen analog output to the given value (0-255)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Output
 
|-
 
| colspan="2" | Which output to set the value for (1 ro 2)&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
|-
 
| colspan="2" | Value to set (0-255)&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''
 
|}
 
  
  
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
+
''<span style="color:red;">No additional examples</span>''
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDigitalOut'''
 
|-
 
| colspan="2" | Sets the state of the output given by the output index (1 to 8)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Out
 
|-
 
| colspan="2" | Number of the output to set the value for&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
 
| width="90%" | Value
 
|-
 
| 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''
 
|}
 
  
  
{| 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;" | '''GetDigitalByte'''
 
|-
 
| colspan="2" | Read all five inputs at once, returning them as a bit pattern in a byte. The upper three bits will always be zero.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
  
  
{| 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;" | '''ResetCount'''
 
|-
 
| colspan="2" | Resets the chosen counter of the currently selected board.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | Which counter to reset (1 or 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''
 
|}
 
  
  
{| 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;" | '''GetDevices'''
 
|-
 
| colspan="2" | Returns a value representing the available devices. Device is a binary value where bit(N) set = device at address (N) is connected.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
  
  
{| 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;" | '''Select'''
 
|-
 
| colspan="2" | Selects the board address to send  to and receive data from. Echos the address if the selection is valid. Returns -1 if there is no device available at that address.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Address
 
|-
 
| colspan="2" | The address off the board to be selected (0...3).&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
  
  
{| 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;" | '''SetDigitalByte'''
 
|-
 
| colspan="2" | Sets all eight digital outputs according to the individual bits of the Value parameter.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
|-
 
| colspan="2" | Value to send to the selected board.&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''
 
|}
 
  
 +
==Macro reference==
  
 +
===GetAnalogIn===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDigitalIn'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetAnalogIn'''
 
|-
 
|-
| colspan="2" | Read the individual input at the given index (1..5)&nbsp;
+
| colspan="2" | Read analog input 1 or 2&nbsp;
 
|-
 
|-
 
|-
 
|-
Line 216: Line 73:
 
| width="90%" | Input
 
| width="90%" | Input
 
|-
 
|-
| colspan="2" | Which input to read (1 to 5)&nbsp;
+
| colspan="2" | Which input to read (1 ro 2)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
Line 223: Line 80:
  
  
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
+
===GetCount===
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetCountDebounce'''
 
|-
 
| colspan="2" | Set the amount of time allowed for switches to settle before being counted as a new event to count.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | Which counter to make a setting for (1 or 2)&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | DebounceTime
 
|-
 
| colspan="2" | Settling time for switch debouncing in milliseconds&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''
 
|}
 
 
 
 
 
 
 
 
 
==Property reference==
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''
 
|-
 
|-
 
| 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%" | Addr 0
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 0.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 1
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 1.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 2
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 2.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 3
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 3.&nbsp;
 
|-
 
| width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]]
 
| width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Hardware
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 
| width="90%" | Scan
 
|-
 
| colspan="2" | Request a scan of the currently connected hardware to detect what Velleman boards are connected and at what addresses. Where hardware is not detected at an addess, a System Panel simulation will be used instead where one has been requested in the properties.&nbsp;
 
|}==Macro reference==
 
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
Line 308: Line 99:
  
  
 +
===GetDevices===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetAnalogIn'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDevices'''
 
|-
 
|-
| colspan="2" | Read analog input 1 or 2&nbsp;
+
| colspan="2" | Returns a value representing the available devices. Device is a binary value where bit(N) set = device at address (N) is connected.&nbsp;
 
|-
 
|-
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Input
 
|-
 
| colspan="2" | Which input to read (1 ro 2)&nbsp;
 
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
Line 326: Line 113:
  
  
 +
===GetDigitalByte===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetAnalogOut'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDigitalByte'''
 
|-
 
|-
| colspan="2" | Sets the chosen analog output to the given value (0-255)&nbsp;
+
| colspan="2" | Read all five inputs at once, returning them as a bit pattern in a byte. The upper three bits will always be zero.&nbsp;
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
+
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
| width="90%" | Output
 
|-
 
| colspan="2" | Which output to set the value for (1 ro 2)&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
|-
 
| colspan="2" | Value to set (0-255)&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''
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
|}
  
  
 +
===GetDigitalIn===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDigitalOut'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDigitalIn'''
 
|-
 
|-
| colspan="2" | Sets the state of the output given by the output index (1 to 8)&nbsp;
+
| colspan="2" | Read the individual input at the given index (1..5)&nbsp;
 
|-
 
|-
 
|-
 
|-
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
+
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
| width="90%" | Out
+
| width="90%" | Input
|-
 
| colspan="2" | Number of the output to set the value for&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
 
| width="90%" | Value
 
|-
 
| 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''
 
|}
 
 
 
 
 
{| 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;" | '''GetDigitalByte'''
 
|-
 
| colspan="2" | Read all five inputs at once, returning them as a bit pattern in a byte. The upper three bits will always be zero.&nbsp;
 
 
|-
 
|-
 +
| colspan="2" | Which input to read (1 to 5)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
Line 385: Line 146:
  
  
 +
===ResetCount===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
Line 403: Line 165:
  
  
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
+
===Select===
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDevices'''
 
|-
 
| colspan="2" | Returns a value representing the available devices. Device is a binary value where bit(N) set = device at address (N) is connected.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
Line 434: Line 184:
  
  
 +
===SetAnalogOut===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDigitalByte'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetAnalogOut'''
 +
|-
 +
| colspan="2" | Sets the chosen analog output to the given value (0-255)&nbsp;
 +
|-
 
|-
 
|-
| colspan="2" | Sets all eight digital outputs according to the individual bits of the Value parameter.&nbsp;
+
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Output
 
|-
 
|-
 +
| colspan="2" | Which output to set the value for (1 ro 2)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
| width="90%" | Value
 
|-
 
|-
| colspan="2" | Value to send to the selected board.&nbsp;
+
| colspan="2" | Value to set (0-255)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 452: Line 208:
  
  
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
+
===SetCountDebounce===
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDigitalIn'''
 
|-
 
| colspan="2" | Read the individual input at the given index (1..5)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Input
 
|-
 
| colspan="2" | Which input to read (1 to 5)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
Line 493: Line 232:
  
  
 
+
===SetDigitalByte===
 
 
==Property reference==
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
 
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''
 
|-
 
|-
 
| 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%" | Addr 0
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 0.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 1
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 1.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 2
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 2.&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
 
| width="90%" | Addr 3
 
|-
 
| colspan="2" | Use software simulation to emulate a board connected at address 3.&nbsp;
 
|-
 
| width="10%" align="center" style="background-color:#EAE1EA;" | [[File:Fc9-conn-icon.png]]
 
| width="90%" style="background-color:#EAE1EA; color:#4B008D;" | Hardware
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 
| width="90%" | Scan
 
|-
 
| colspan="2" | Request a scan of the currently connected hardware to detect what Velleman boards are connected and at what addresses. Where hardware is not detected at an addess, a System Panel simulation will be used instead where one has been requested in the properties.&nbsp;
 
|}==Macro reference==
 
 
 
{| 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;" | '''GetCount'''
 
|-
 
| colspan="2" | Read the value of the chosen counter for the currently selected board.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | The counter to read (1 or 2)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
 
 
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetAnalogIn'''
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDigitalByte'''
 
|-
 
|-
| colspan="2" | Read analog input 1 or 2&nbsp;
+
| colspan="2" | Sets all eight digital outputs according to the individual bits of the Value parameter.&nbsp;
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Input
 
|-
 
| colspan="2" | Which input to read (1 ro 2)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
 
 
{| 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;" | '''SetAnalogOut'''
 
|-
 
| colspan="2" | Sets the chosen analog output to the given value (0-255)&nbsp;
 
 
|-
 
|-
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Output
 
|-
 
| colspan="2" | Which output to set the value for (1 ro 2)&nbsp;
 
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
| width="90%" | Value
 
|-
 
|-
| colspan="2" | Value to set (0-255)&nbsp;
+
| colspan="2" | Value to send to the selected board.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
Line 596: Line 251:
  
  
 +
===SetDigitalOut===
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
|-
 
|-
Line 617: Line 273:
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
|}
 
 
{| 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;" | '''GetDigitalByte'''
 
|-
 
| colspan="2" | Read all five inputs at once, returning them as a bit pattern in a byte. The upper three bits will always be zero.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
{| 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;" | '''ResetCount'''
 
|-
 
| colspan="2" | Resets the chosen counter of the currently selected board.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | Which counter to reset (1 or 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''
 
|}
 
 
 
{| 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;" | '''GetDevices'''
 
|-
 
| colspan="2" | Returns a value representing the available devices. Device is a binary value where bit(N) set = device at address (N) is connected.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
{| 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;" | '''Select'''
 
|-
 
| colspan="2" | Selects the board address to send  to and receive data from. Echos the address if the selection is valid. Returns -1 if there is no device available at that address.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Address
 
|-
 
| colspan="2" | The address off the board to be selected (0...3).&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
{| 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;" | '''SetDigitalByte'''
 
|-
 
| colspan="2" | Sets all eight digital outputs according to the individual bits of the Value parameter.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 
| width="90%" | Value
 
|-
 
| colspan="2" | Value to send to the selected board.&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''
 
|}
 
 
 
{| 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;" | '''GetDigitalIn'''
 
|-
 
| colspan="2" | Read the individual input at the given index (1..5)&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Input
 
|-
 
| colspan="2" | Which input to read (1 to 5)&nbsp;
 
|-
 
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
|}
 
 
 
{| 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;" | '''SetCountDebounce'''
 
|-
 
| colspan="2" | Set the amount of time allowed for switches to settle before being counted as a new event to count.&nbsp;
 
|-
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | Counter
 
|-
 
| colspan="2" | Which counter to make a setting for (1 or 2)&nbsp;
 
|-
 
| width="10%" align="center" | [[File:Fc9-s16-icon.png]] - INT
 
| width="90%" | DebounceTime
 
|-
 
| colspan="2" | Settling time for switch debouncing in milliseconds&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''
 
|}
 
 
 
  
  

Latest revision as of 13:11, 7 February 2023

Author Matrix Ltd
Version 2.3
Category Third Party


K8055D component

Support for the Velleman K8055 USB input/output board. Allows Flowcode to communicate with up to four K8055 boards, or to simulate them with interactive on-screen controls. All digital and analog I/O functions are supported.

Component Source Code

Please click here to download the component source project: FC_Comp_Source_K8055D.fcsx

Please click here to view the component source code (Beta): FC_Comp_Source_K8055D.fcsx

Detailed description

No detailed description exists yet for this component

Examples

No additional examples






Macro reference

GetAnalogIn

Fc9-comp-macro.png GetAnalogIn
Read analog input 1 or 2 
Fc9-s16-icon.png - INT Input
Which input to read (1 ro 2) 
Fc9-s16-icon.png - INT Return


GetCount

Fc9-comp-macro.png GetCount
Read the value of the chosen counter for the currently selected board. 
Fc9-s16-icon.png - INT Counter
The counter to read (1 or 2) 
Fc9-u16-icon.png - UINT Return


GetDevices

Fc9-comp-macro.png GetDevices
Returns a value representing the available devices. Device is a binary value where bit(N) set = device at address (N) is connected. 
Fc9-s16-icon.png - INT Return


GetDigitalByte

Fc9-comp-macro.png GetDigitalByte
Read all five inputs at once, returning them as a bit pattern in a byte. The upper three bits will always be zero. 
Fc9-s16-icon.png - INT Return


GetDigitalIn

Fc9-comp-macro.png GetDigitalIn
Read the individual input at the given index (1..5) 
Fc9-s16-icon.png - INT Input
Which input to read (1 to 5) 
Fc9-s16-icon.png - INT Return


ResetCount

Fc9-comp-macro.png ResetCount
Resets the chosen counter of the currently selected board. 
Fc9-s16-icon.png - INT Counter
Which counter to reset (1 or 2) 
Fc9-void-icon.png - VOID Return


Select

Fc9-comp-macro.png Select
Selects the board address to send to and receive data from. Echos the address if the selection is valid. Returns -1 if there is no device available at that address. 
Fc9-s16-icon.png - INT Address
The address off the board to be selected (0...3). 
Fc9-s16-icon.png - INT Return


SetAnalogOut

Fc9-comp-macro.png SetAnalogOut
Sets the chosen analog output to the given value (0-255) 
Fc9-u8-icon.png - BYTE Output
Which output to set the value for (1 ro 2) 
Fc9-u8-icon.png - BYTE Value
Value to set (0-255) 
Fc9-void-icon.png - VOID Return


SetCountDebounce

Fc9-comp-macro.png SetCountDebounce
Set the amount of time allowed for switches to settle before being counted as a new event to count. 
Fc9-s16-icon.png - INT Counter
Which counter to make a setting for (1 or 2) 
Fc9-s16-icon.png - INT DebounceTime
Settling time for switch debouncing in milliseconds 
Fc9-void-icon.png - VOID Return


SetDigitalByte

Fc9-comp-macro.png SetDigitalByte
Sets all eight digital outputs according to the individual bits of the Value parameter. 
Fc9-u8-icon.png - BYTE Value
Value to send to the selected board. 
Fc9-void-icon.png - VOID Return


SetDigitalOut

Fc9-comp-macro.png SetDigitalOut
Sets the state of the output given by the output index (1 to 8) 
Fc9-u8-icon.png - BYTE Out
Number of the output to set the value for 
Fc9-bool-icon.png - BOOL Value
 
Fc9-void-icon.png - VOID Return


Property reference

Fc9-prop-icon.png Properties
Fc9-conn-icon.png Simulation
Fc9-type-7-icon.png Addr 0
Use software simulation to emulate a board connected at address 0. 
Fc9-type-7-icon.png Addr 1
Use software simulation to emulate a board connected at address 1. 
Fc9-type-7-icon.png Addr 2
Use software simulation to emulate a board connected at address 2. 
Fc9-type-7-icon.png Addr 3
Use software simulation to emulate a board connected at address 3. 
Fc9-conn-icon.png Hardware
Fc9-type-16-icon.png Scan
Request a scan of the currently connected hardware to detect what Velleman boards are connected and at what addresses. Where hardware is not detected at an addess, a System Panel simulation will be used instead where one has been requested in the properties.