Difference between revisions of "Component: Control (AllCode)"

From Flowcode Help
Jump to navigationJump to search
(XML import)
 
Line 1: Line 1:
 
+
{| style="width:50%"
 
 
{| width="50%"
 
 
|-
 
|-
| width="20%" style="color: gray;" | Author
+
| width="20%" style="color:gray;" | Author
 
| Matrix TSL
 
| Matrix TSL
 
|-
 
|-
| width="20%" style="color: gray;" | Version
+
| width="20%" style="color:gray;" | Version
| 1.0 (Release)
+
| 1.0
 
|-
 
|-
| width="20%" style="color: gray;" | Category
+
| width="20%" style="color:gray;" | Category
 
| AllCode
 
| AllCode
 
|}
 
|}
  
  
 
+
==Control component==
==[[File:Component Icon bd23228f_b173_4135_ab3b_a4c3c4caa7a8.png|Image]] Control component==
 
 
Drives the Matrix Control hardware via the AllCode API.
 
Drives the Matrix Control hardware via the AllCode API.
  
==Examples==
+
==Component Pack==
''<span style="color:red;">No additional examples</span>''
 
  
 +
FREE
  
==Downloadable macro reference==
+
==Detailed description==
  
''This component does not contain any downloadable macros''
+
''No detailed description exists yet for this component''
  
==Simulation macro reference==
+
==Examples==
  
===<span style="font-weight: normal;"><u><tt>SetAutoPrescaler</tt></u></span>===
 
Configures the automatic mode prescaler, for running really slowly.
 
  
Defaults off so no need to call this unless you are using it.
+
''<span style="color:red;">No additional examples</span>''
  
'''Parameters'''
 
  
:[[Variable Types|BYTE]] ''Prescaler''
+
==Downloadable macro reference==
::0=Off, 2=Div by 2, 3=Div By 3 etc
 
  
 +
{| 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;" | '''SetAutoPrescaler'''
 +
|-
 +
| colspan="2" | Configures the automatic mode prescaler, for running really slowly. Defaults off so no need to call this unless you are using it.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Prescaler
 +
|-
 +
| colspan="2" | 0=Off, 2=Div by 2, 3=Div By 3 etc&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''
 +
|}
  
'''Return value'''
 
  
:''This call does not return a value''
+
{| 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;" | '''GetOutput'''
 +
|-
 +
| colspan="2" | Gets the output value as an integer value betwen 0 and 100 representing the output PWM duty&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
  
===<span style="font-weight: normal;"><u><tt>GetOutput</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Gets the output value as an integer value betwen 0 and 100 representing
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetAutoOnOff'''
 +
|-
 +
| colspan="2" | Enable the auto PID control using the on-board microcontroller&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Channel
 +
|-
 +
| colspan="2" | Range: 0-1&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Enable
 +
|-
 +
| colspan="2" | 0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz&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''
 +
|}
  
the output PWM duty
 
  
'''Parameters'''
+
{| 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;" | '''SetWIFIPort'''
 +
|-
 +
| colspan="2" | Configures the WIFI Port number.  Default 1245.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
 +
| width="90%" | Port
 +
|-
 +
| colspan="2" | Default 1245&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 macro has no parameters''
 
  
 +
{| 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;" | '''SetAutoPIDFlip'''
 +
|-
 +
| colspan="2" | Controls if the PID response is flipped, a negative response vs a positive&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
 +
| width="90%" | Flip
 +
|-
 +
| colspan="2" | Default: 0=Not Flipped, 1=Flipped&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''
 +
|}
  
'''Return value'''
 
  
:[[Variable Types|BYTE]]
+
{| 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;" | '''SetBluetoothDetails'''
 +
|-
 +
| colspan="2" | Configures the Bluetooth device name and pin and stores into the none volatie memory onboard the robot arm. Call the SetBluetoothMode macro after this to action the change.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" | Name
 +
|-
 +
| colspan="2" | Bluetooth Device String, Max 20 Characters&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" | Pin
 +
|-
 +
| colspan="2" | Pin String, 4 Numeric Characters e.g. "1234"&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><tt>SetAutoOnOff</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Enable the auto PID control using the on-board microcontroller
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetDataArray'''
 +
|-
 +
| colspan="2" | Collects a data array from the Control board. Returns number of samples collected.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | data
 +
|-
 +
| colspan="2" | &nbsp;
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
'''Parameters'''
 
  
:[[Variable Types|BYTE]] ''Channel''
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
::Range: 0-1
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetWifiIP'''
 +
|-
 +
| colspan="2" | Collects the IP address of the robot arm WIFI connection.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
:[[Variable Types|BYTE]] ''Enable''
 
::0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz
 
  
 +
{| 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;" | '''SetWifiDetails'''
 +
|-
 +
| colspan="2" | Configures the WIFI SSID and Password strings and stores into the none volatie memory onboard the robot arm. Call the SetWifiMode macro after this to action the change.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" | SSID
 +
|-
 +
| colspan="2" | Netword ID String, Max 32 Characters&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" | Password
 +
|-
 +
| colspan="2" | Password String, Max 32 Characters&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''
 +
|}
  
'''Return value'''
 
  
:''This call does not return a value''
+
{| 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;" | '''ResetToBoot'''
 +
|-
 +
| colspan="2" | Resets the board into bootload mode for reprogramming. Comms port will be closed on calling this macro,&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><tt>SetWIFIPort</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Configures the WIFI Port number.  
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetAutoOnOffParam'''
 +
|-
 +
| colspan="2" | Sets the Hysteresis parameter for the Auto on-board On/Off&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | Hysteresis
 +
|-
 +
| colspan="2" | Hysterists in real world units&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''
 +
|}
  
Default 1245.
 
  
'''Parameters'''
+
{| 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;" | '''SetWifiMode'''
 +
|-
 +
| colspan="2" | Configures the WIFI mode. When enabled the control system can either create its own WIFI network or join an existing WIFI network,&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Mode
 +
|-
 +
| colspan="2" | 0=Disabled, 1=Host Network, 2=Join Network&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''
 +
|}
  
:[[Variable Types|UINT]] ''Port''
 
::Default 1245
 
  
 +
{| 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;" | '''GetPIDComponent'''
 +
|-
 +
| colspan="2" | Gets one of the PID controller output components in real world units&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Index
 +
|-
 +
| colspan="2" | Range 0-2, 0=P, 1=I, 2=D&nbsp;
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
'''Return value'''
 
  
:''This call does not return a value''
+
{| 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;" | '''SetEthernetPort'''
 +
|-
 +
| colspan="2" | Configures the Ethernet Port number.  Default 1245.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
 +
| width="90%" | Port
 +
|-
 +
| colspan="2" | Default 1245&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><tt>SetAutoPIDFlip</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Controls if the PID response is flipped, a negative response vs a positive
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetEthernetIP'''
 +
|-
 +
| colspan="2" | Configures the Ethernet IP Address.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING
 +
| width="90%" | IP
 +
|-
 +
| colspan="2" | IP Address string e.g. "192.168.1.100"&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''
 +
|}
  
'''Parameters'''
 
  
:[[Variable Types|BOOL]] ''Flip''
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
::Default: 0=Not Flipped, 1=Flipped
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetCANID'''
 +
|-
 +
| colspan="2" | Stores the specified CAN ID into an internal none volatile memory location.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT
 +
| width="90%" | ID
 +
|-
 +
| 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''
 +
|}
  
  
'''Return value'''
+
{| 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;" | '''GetFeedback'''
 +
|-
 +
| colspan="2" | Gets the feedback as a value in real world units&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
:''This call does not return a value''
 
  
 +
{| 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;" | '''GetAPI'''
 +
|-
 +
| colspan="2" | Gets the API version number&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
===<span style="font-weight: normal;"><u><tt>SetBluetoothDetails</tt></u></span>===
 
Configures the Bluetooth device name and pin and stores into the none volatie memory onboard the robot arm.
 
  
Call the SetBluetoothMode macro after this to action the change.
+
{| 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;" | '''SetManualDuty'''
 +
|-
 +
| colspan="2" | Sets duty parameter for one of the manual controlled outputs&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Channel
 +
|-
 +
| colspan="2" | Range: 0-1&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | Duty
 +
|-
 +
| colspan="2" | Duty Cycle Output in Percentage Range 0 - 100%&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''
 +
|}
  
'''Parameters'''
 
  
:[[Variable Types|<- STRING]] ''Name''
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
::Bluetooth Device String, Max 20 Characters
+
|-
::''This parameter may be returned back to the caller''
+
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CheckErrorStatus'''
 +
|-
 +
| colspan="2" | Returns the Error status value indicating if there has been any errors. 0 = No Error 1 = Timeout Error&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 +
|}
  
:[[Variable Types|<- STRING]] ''Pin''
 
::Pin String, 4 Numeric Characters e.g. "1234"
 
::''This parameter may be returned back to the caller''
 
  
 +
{| 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;" | '''SetCANMode'''
 +
|-
 +
| colspan="2" | Configures if the CAN API mde is enabled or disabled.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Mode
 +
|-
 +
| colspan="2" | 0=Disabled / 1=Enabled&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''
 +
|}
  
'''Return value'''
 
  
:''This call does not return a value''
+
{| 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;" | '''SetAutoPID'''
 +
|-
 +
| colspan="2" | Enable the auto PID control using the on-board microcontroller&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Channel
 +
|-
 +
| colspan="2" | Range: 0-1&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Enable
 +
|-
 +
| colspan="2" | 0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz&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><tt>GetDataArray</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Collects a data array from the Control board.
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetLogDivider'''
 +
|-
 +
| colspan="2" | Configures the rate of the PID logging.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Divider
 +
|-
 +
| colspan="2" | Divides the rate by the selected value&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''
 +
|}
  
Returns number of samples collected.
 
  
'''Parameters'''
+
{| 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;" | '''ZeroSensor'''
 +
|-
 +
| colspan="2" | Zeros the attached sensor reading.  Useful for Pressure and Level control applications.&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''
 +
|}
  
:[[Variable Types|FLOAT]] ''data''
 
  
 +
{| 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;" | '''SetAutoPIDParam'''
 +
|-
 +
| colspan="2" | Sets one of the P, I, D parameters for the Auto on-board PID&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Index
 +
|-
 +
| colspan="2" | Range: 0-5 Where 0=P, 1=I, 2=D, 3=IntClamp, 4=DFilt, 5=FiltCo&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | Value
 +
|-
 +
| colspan="2" | Range: 0.0 to 65.535&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''
 +
|}
  
'''Return value'''
 
  
:[[Variable Types|BYTE]]
+
{| 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;" | '''SetEthernetMode'''
 +
|-
 +
| colspan="2" | Configures the Ethernet mode.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | Mode
 +
|-
 +
| colspan="2" | 0=Disabled, 1=Enabled&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><tt>GetWifiIP</tt></u></span>===
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
Collects the IP address of the robot arm WIFI connection.
+
|-
 +
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 +
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetBluetoothMode'''
 +
|-
 +
| colspan="2" | Configures the Bluetooth mode.&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-bool-icon.png]] - BOOL
 +
| width="90%" | Mode
 +
|-
 +
| colspan="2" | 0=Disabled, 1=Enabled&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''
 +
|}
  
'''Parameters'''
 
  
:''This macro has no parameters''
+
{| 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" | &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''
 +
|}
  
  
'''Return value'''
+
{| 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;" | '''SetFeedbackMethod'''
 +
|-
 +
| colspan="2" | Sets feedback method to dictate which control application we are running&nbsp;
 +
|-
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE
 +
| width="90%" | FBMethod
 +
|-
 +
| colspan="2" | Range: 0-3 Where 0=Level, 1=Flow, 2=Pressure, 3=Temp&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | InputScaler
 +
|-
 +
| colspan="2" | Feedback scaling factor used to convert the feedback reading into a meaningful value&nbsp;
 +
|-
 +
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
 +
| width="90%" | OutputScaler
 +
|-
 +
| colspan="2" | Value used to convert input to 0-100% duty&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''
 +
|}
  
:[[Variable Types|STRING]]
 
  
 
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
===<span style="font-weight: normal;"><u><tt>SetWifiDetails</tt></u></span>===
+
|-
Configures the WIFI SSID and Password strings and stores into the none volatie memory onboard the robot arm.
+
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]]
 
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetSetpoint'''
Call the SetWifiMode macro after this to action the change.
+
|-
 
+
| colspan="2" | Sets Setpoint parameter for the Auto on-board PID&nbsp;
'''Parameters'''
+
|-
 
+
|-
:[[Variable Types|<- STRING]] ''SSID''
+
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
::Netword ID String, Max 32 Characters
+
| width="90%" | Setpoint
::''This parameter may be returned back to the caller''
+
|-
 
+
| colspan="2" | Required Output in Real World Units&nbsp;
:[[Variable Types|<- STRING]] ''Password''
+
|-
::Password String, Max 32 Characters
+
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID
::''This parameter may be returned back to the caller''
+
| width="90%" style="border-top: 2px solid #000;" | ''Return''
 
+
|}
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>ResetToBoot</tt></u></span>===
 
Resets the board into bootload mode for reprogramming.
 
 
 
Comms port will be closed on calling this macro,
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetAutoOnOffParam</tt></u></span>===
 
Sets the Hysteresis parameter for the Auto on-board On/Off
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|FLOAT]] ''Hysteresis''
 
::Hysterists in real world units
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetWifiMode</tt></u></span>===
 
Configures the WIFI mode.
 
 
 
When enabled the control system can either create its own WIFI network or join an existing WIFI network,
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Mode''
 
::0=Disabled, 1=Host Network, 2=Join Network
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>GetPIDComponent</tt></u></span>===
 
Gets one of the PID controller output components in real world units
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Index''
 
::Range 0-2, 0=P, 1=I, 2=D
 
 
 
 
 
'''Return value'''
 
 
 
:[[Variable Types|FLOAT]]
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetEthernetPort</tt></u></span>===
 
Configures the Ethernet Port number.  
 
 
 
Default 1245.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|UINT]] ''Port''
 
::Default 1245
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetEthernetIP</tt></u></span>===
 
Configures the Ethernet IP Address.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|<- STRING]] ''IP''
 
::IP Address string e.g. "192.168.1.100"
 
::''This parameter may be returned back to the caller''
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetCANID</tt></u></span>===
 
Stores the specified CAN ID into an internal none volatile memory location.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|UINT]] ''ID''
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>GetFeedback</tt></u></span>===
 
Gets the feedback as a value in real world units
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:[[Variable Types|FLOAT]]
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>GetAPI</tt></u></span>===
 
Gets the API version number
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:[[Variable Types|BYTE]]
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetManualDuty</tt></u></span>===
 
Sets duty parameter for one of the manual controlled outputs
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Channel''
 
::Range: 0-1
 
 
 
:[[Variable Types|FLOAT]] ''Duty''
 
::Duty Cycle Output in Percentage Range 0 - 100%
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>CheckErrorStatus</tt></u></span>===
 
Returns the Error status value indicating if there has been any errors.
 
 
 
0 = No Error
 
 
 
1 = Timeout Error
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:[[Variable Types|BYTE]]
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetCANMode</tt></u></span>===
 
Configures if the CAN API mde is enabled or disabled.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Mode''
 
::0=Disabled / 1=Enabled
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetAutoPID</tt></u></span>===
 
Enable the auto PID control using the on-board microcontroller
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Channel''
 
::Range: 0-1
 
 
 
:[[Variable Types|BYTE]] ''Enable''
 
::0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetLogDivider</tt></u></span>===
 
Configures the rate of the PID logging.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Divider''
 
::Divides the rate by the selected value
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>ZeroSensor</tt></u></span>===
 
Zeros the attached sensor reading.
 
 
 
Useful for Pressure and Level control applications.
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetAutoPIDParam</tt></u></span>===
 
Sets one of the P, I, D parameters for the Auto on-board PID
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Index''
 
::Range: 0-5 Where 0=P, 1=I, 2=D, 3=IntClamp, 4=DFilt, 5=FiltCo
 
 
 
:[[Variable Types|FLOAT]] ''Value''
 
::Range: 0.0 to 65.535
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetEthernetMode</tt></u></span>===
 
Configures the Ethernet mode.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''Mode''
 
::0=Disabled, 1=Enabled
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetBluetoothMode</tt></u></span>===
 
Configures the Bluetooth mode.
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BOOL]] ''Mode''
 
::0=Disabled, 1=Enabled
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>Initialise</tt></u></span>===
 
''<span style="color:red;">No additional information</span>''
 
 
 
 
 
 
 
'''Parameters'''
 
 
 
:''This macro has no parameters''
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetFeedbackMethod</tt></u></span>===
 
Sets feedback method to dictate which control application we are running
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|BYTE]] ''FBMethod''
 
::Range: 0-3 Where 0=Level, 1=Flow, 2=Pressure, 3=Temp
 
 
 
:[[Variable Types|FLOAT]] ''InputScaler''
 
::Feedback scaling factor used to convert the feedback reading into a meaningful value
 
 
 
:[[Variable Types|FLOAT]] ''OutputScaler''
 
::Value used to convert input to 0-100% duty
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
 
 
 
 
===<span style="font-weight: normal;"><u><tt>SetSetpoint</tt></u></span>===
 
Sets Setpoint parameter for the Auto on-board PID
 
 
 
'''Parameters'''
 
 
 
:[[Variable Types|FLOAT]] ''Setpoint''
 
::Required Output in Real World Units
 
 
 
 
 
'''Return value'''
 
 
 
:''This call does not return a value''
 
  
  
Line 496: Line 574:
  
 
==Property reference==
 
==Property reference==
<span style="font-weight: normal;"><u>Comms Method</u></span>
 
  
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''CommsMethod''.
+
{| class="wikitable" style="width:60%; background-color:#FFFFFF;"
 
+
|-
Selects the method to communicate with the Matrix 3 Axis Robot Arm.
+
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-prop-icon.png]]
 
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Properties'''  
USB connection requires the USB drivers to be installed.
+
|-
 
+
|-
Bluetooth connection requires the device first be paired using the Windows Bluetooth control panel.
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 
+
| width="90%" | Comms Method
WIFI connection requires the connection settings to be configured first on the robot using USB or Bluetooth.  
+
|-
 
+
| colspan="2" | Selects the method to communicate with the Matrix 3 Axis Robot Arm. USB connection requires the USB drivers to be installed. Bluetooth connection requires the device first be paired using the Windows Bluetooth control panel. WIFI connection requires the connection settings to be configured first on the robot using USB or Bluetooth. CAN connection does not simulate and works on embedded hardware e.g. the MIAC.&nbsp;
CAN connection does not simulate and works on embedded hardware e.g. the MIAC.
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-7-icon.png]]
<span style="font-weight: normal;"><u>Autodetect</u></span>
+
| width="90%" | Autodetect
 
+
|-
This property is of type ''True or false'' and can be referenced with the variable name ''Autodetect''.
+
| colspan="2" | Autodetects the COM port, only works for USB AllCode connection.&nbsp;
 
+
|-
Autodetects the COM port, only works for USB AllCode connection.
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
 
+
| width="90%" | COM Port
<span style="font-weight: normal;"><u>COM Port</u></span>
+
|-
 
+
| colspan="2" | Selects which port to communicate with, only lists ports which are currently available. &nbsp;
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''COMPort1::COM_port''.
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
Selects which port to communicate with, only lists ports which are currently available.
+
| width="90%" | Network Interface
 
+
|-
<span style="font-weight: normal;"><u>Network Interface</u></span>
+
| colspan="2" | Some computers may have several network interfaces such as ethernet ports and wifi access. Select the correct network interface for the network you wish to connect to. Use the IP address to confirm you are connected to the right network.&nbsp;
 
+
|-
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''NetworkComms1::NetworkInterface''.
+
| width="10%" align="center" | [[File:Fc9-type-10-icon.png]]
 
+
| width="90%" | Local IP Address
Some computers may have several network interfaces such as ethernet ports and wifi access.
+
|-
 
+
| colspan="2" | IP Address of the selected network interface.&nbsp;
Select the correct network interface for the network you wish to connect to.
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-10-icon.png]]
Use the IP address to confirm you are connected to the right network.
+
| width="90%" | Control IP Address
 
+
|-
<span style="font-weight: normal;"><u>Local IP Address</u></span>
+
| colspan="2" | IP address of the Control Board. You can find the IP address by connecting using USB and running the GetIP component macro. You may first need to configure the Control Board in WIFI mode by providing the network SSID and Password.&nbsp;
 
+
|-
This property is of type ''Line of text'' and can be referenced with the variable name ''NetworkComms1::IPAddress''.
+
| width="10%" align="center" | [[File:Fc9-type-21-icon.png]]
 
+
| width="90%" | Port
IP Address of the selected network interface.
+
|-
 
+
| colspan="2" | Allows the Control TCP/IP Port to be selected. Default 1245.&nbsp;
<span style="font-weight: normal;"><u>Control IP Address</u></span>
+
|-
 
+
| width="10%" align="center" | [[File:Fc9-type-16-icon.png]]
This property is of type ''Line of text'' and can be referenced with the variable name ''ArmIP''.
+
| width="90%" | Channel
 
+
|-
IP address of the Control Board.  
+
| colspan="2" | Switches between Internal CAN peripheral and External CAN controller IC MCP2515.&nbsp;
 
+
|-
You can find the IP address by connecting using USB and running the GetIP component macro.
+
| width="10%" align="center" | [[File:Fc9-type-1-icon.png]]
 
+
| width="90%" | Text Colour
You may first need to configure the Control Board in WIFI mode by providing the network SSID and Password.
+
|-
 
+
| colspan="2" | &nbsp;
<span style="font-weight: normal;"><u>Port</u></span>
+
|-
 
+
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-conn-icon.png]]
This property is of type ''Unsigned integer'' and can be referenced with the variable name ''Port''.
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Connections'''  
 
+
|-
Allows the Control TCP/IP Port to be selected. Default 1245.
+
|-
 
+
| width="10%" align="center" style="background-color:#D8C9D8;" | [[File:Fc9-conn-icon.png]]
<span style="font-weight: normal;"><u>Channel</u></span>
+
| width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Simulations'''  
 
+
|-
This property is of type ''Fixed list of ints'' and can be referenced with the variable name ''can1::CHANNEL_CAN''.
+
|}
 
 
Switches between Internal CAN peripheral and External CAN controller IC MCP2515.
 
 
 
<span style="font-weight: normal;"><u>Text Colour</u></span>
 
 
 
This property is of type ''Color picker'' and can be referenced with the variable name ''TextColour''.
 
 
 
''<span style="color:red;">No additional information</span>''
 

Revision as of 14:52, 7 January 2022

Author Matrix TSL
Version 1.0
Category AllCode


Control component

Drives the Matrix Control hardware via the AllCode API.

Component Pack

FREE

Detailed description

No detailed description exists yet for this component

Examples

No additional examples


Downloadable macro reference

Fc9-comp-macro.png SetAutoPrescaler
Configures the automatic mode prescaler, for running really slowly. Defaults off so no need to call this unless you are using it. 
Fc9-u8-icon.png - BYTE Prescaler
0=Off, 2=Div by 2, 3=Div By 3 etc 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetOutput
Gets the output value as an integer value betwen 0 and 100 representing the output PWM duty 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png SetAutoOnOff
Enable the auto PID control using the on-board microcontroller 
Fc9-u8-icon.png - BYTE Channel
Range: 0-1 
Fc9-u8-icon.png - BYTE Enable
0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetWIFIPort
Configures the WIFI Port number. Default 1245. 
Fc9-u16-icon.png - UINT Port
Default 1245 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetAutoPIDFlip
Controls if the PID response is flipped, a negative response vs a positive 
Fc9-bool-icon.png - BOOL Flip
Default: 0=Not Flipped, 1=Flipped 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetBluetoothDetails
Configures the Bluetooth device name and pin and stores into the none volatie memory onboard the robot arm. Call the SetBluetoothMode macro after this to action the change. 
Fc9-string-icon.png - STRING Name
Bluetooth Device String, Max 20 Characters 
Fc9-string-icon.png - STRING Pin
Pin String, 4 Numeric Characters e.g. "1234" 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetDataArray
Collects a data array from the Control board. Returns number of samples collected. 
Fc9-f32-icon.png - FLOAT data
 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png GetWifiIP
Collects the IP address of the robot arm WIFI connection. 
Fc9-string-icon.png - STRING Return


Fc9-comp-macro.png SetWifiDetails
Configures the WIFI SSID and Password strings and stores into the none volatie memory onboard the robot arm. Call the SetWifiMode macro after this to action the change. 
Fc9-string-icon.png - STRING SSID
Netword ID String, Max 32 Characters 
Fc9-string-icon.png - STRING Password
Password String, Max 32 Characters 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ResetToBoot
Resets the board into bootload mode for reprogramming. Comms port will be closed on calling this macro, 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetAutoOnOffParam
Sets the Hysteresis parameter for the Auto on-board On/Off 
Fc9-f32-icon.png - FLOAT Hysteresis
Hysterists in real world units 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetWifiMode
Configures the WIFI mode. When enabled the control system can either create its own WIFI network or join an existing WIFI network, 
Fc9-u8-icon.png - BYTE Mode
0=Disabled, 1=Host Network, 2=Join Network 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetPIDComponent
Gets one of the PID controller output components in real world units 
Fc9-u8-icon.png - BYTE Index
Range 0-2, 0=P, 1=I, 2=D 
Fc9-f32-icon.png - FLOAT Return


Fc9-comp-macro.png SetEthernetPort
Configures the Ethernet Port number. Default 1245. 
Fc9-u16-icon.png - UINT Port
Default 1245 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetEthernetIP
Configures the Ethernet IP Address. 
Fc9-string-icon.png - STRING IP
IP Address string e.g. "192.168.1.100" 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetCANID
Stores the specified CAN ID into an internal none volatile memory location. 
Fc9-u16-icon.png - UINT ID
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png GetFeedback
Gets the feedback as a value in real world units 
Fc9-f32-icon.png - FLOAT Return


Fc9-comp-macro.png GetAPI
Gets the API version number 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png SetManualDuty
Sets duty parameter for one of the manual controlled outputs 
Fc9-u8-icon.png - BYTE Channel
Range: 0-1 
Fc9-f32-icon.png - FLOAT Duty
Duty Cycle Output in Percentage Range 0 - 100% 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png CheckErrorStatus
Returns the Error status value indicating if there has been any errors. 0 = No Error 1 = Timeout Error 
Fc9-u8-icon.png - BYTE Return


Fc9-comp-macro.png SetCANMode
Configures if the CAN API mde is enabled or disabled. 
Fc9-u8-icon.png - BYTE Mode
0=Disabled / 1=Enabled 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetAutoPID
Enable the auto PID control using the on-board microcontroller 
Fc9-u8-icon.png - BYTE Channel
Range: 0-1 
Fc9-u8-icon.png - BYTE Enable
0=Off, 1=5Hz, 2=10Hz, 3=20Hz, 4=50Hz, 5=100Hz, 6=200Hz, 7=500Hz, 8=1KHz 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetLogDivider
Configures the rate of the PID logging. 
Fc9-u8-icon.png - BYTE Divider
Divides the rate by the selected value 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png ZeroSensor
Zeros the attached sensor reading. Useful for Pressure and Level control applications. 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetAutoPIDParam
Sets one of the P, I, D parameters for the Auto on-board PID 
Fc9-u8-icon.png - BYTE Index
Range: 0-5 Where 0=P, 1=I, 2=D, 3=IntClamp, 4=DFilt, 5=FiltCo 
Fc9-f32-icon.png - FLOAT Value
Range: 0.0 to 65.535 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetEthernetMode
Configures the Ethernet mode. 
Fc9-u8-icon.png - BYTE Mode
0=Disabled, 1=Enabled 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetBluetoothMode
Configures the Bluetooth mode. 
Fc9-bool-icon.png - BOOL Mode
0=Disabled, 1=Enabled 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png Initialise
 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetFeedbackMethod
Sets feedback method to dictate which control application we are running 
Fc9-u8-icon.png - BYTE FBMethod
Range: 0-3 Where 0=Level, 1=Flow, 2=Pressure, 3=Temp 
Fc9-f32-icon.png - FLOAT InputScaler
Feedback scaling factor used to convert the feedback reading into a meaningful value 
Fc9-f32-icon.png - FLOAT OutputScaler
Value used to convert input to 0-100% duty 
Fc9-void-icon.png - VOID Return


Fc9-comp-macro.png SetSetpoint
Sets Setpoint parameter for the Auto on-board PID 
Fc9-f32-icon.png - FLOAT Setpoint
Required Output in Real World Units 
Fc9-void-icon.png - VOID Return



Property reference

Fc9-prop-icon.png Properties
Fc9-type-16-icon.png Comms Method
Selects the method to communicate with the Matrix 3 Axis Robot Arm. USB connection requires the USB drivers to be installed. Bluetooth connection requires the device first be paired using the Windows Bluetooth control panel. WIFI connection requires the connection settings to be configured first on the robot using USB or Bluetooth. CAN connection does not simulate and works on embedded hardware e.g. the MIAC. 
Fc9-type-7-icon.png Autodetect
Autodetects the COM port, only works for USB AllCode connection. 
Fc9-type-16-icon.png COM Port
Selects which port to communicate with, only lists ports which are currently available.  
Fc9-type-16-icon.png Network Interface
Some computers may have several network interfaces such as ethernet ports and wifi access. Select the correct network interface for the network you wish to connect to. Use the IP address to confirm you are connected to the right network. 
Fc9-type-10-icon.png Local IP Address
IP Address of the selected network interface. 
Fc9-type-10-icon.png Control IP Address
IP address of the Control Board. You can find the IP address by connecting using USB and running the GetIP component macro. You may first need to configure the Control Board in WIFI mode by providing the network SSID and Password. 
Fc9-type-21-icon.png Port
Allows the Control TCP/IP Port to be selected. Default 1245. 
Fc9-type-16-icon.png Channel
Switches between Internal CAN peripheral and External CAN controller IC MCP2515. 
Fc9-type-1-icon.png Text Colour
 
Fc9-conn-icon.png Connections
Fc9-conn-icon.png Simulations