Jump to content

Component: EtherCAT Slave (EasyCAT) (Comms: IoT/Cloud): Difference between revisions

From Flowcode Help
No edit summary
No edit summary
Line 16: Line 16:


==Detailed description==
==Detailed description==




Line 24: Line 26:


==Examples==
==Examples==




Line 107: Line 111:
| colspan="2" | Data Index 
| colspan="2" | Data Index 
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:]] -  
| 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''
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
|}
Line 202: Line 206:
| colspan="2" | Data Index 
| colspan="2" | Data Index 
|-
|-
| width="10%" align="center" | [[File:]] -  
| width="10%" align="center" | [[File:Fc9-f32-icon.png]] - FLOAT
| width="90%" | Data
| width="90%" | Data
|-
|-
Line 220: Line 224:
|-
|-
|-
|-
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:]] -  
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-bool-icon.png]] - BOOL
| width="90%" style="border-top: 2px solid #000;" | ''Return''
| width="90%" style="border-top: 2px solid #000;" | ''Return''
|}
|}

Revision as of 13:28, 17 November 2021

Author Matrix TSL
Version 1.0
Category Comms: IoT/Cloud


EtherCAT Slave (EasyCAT) component

Provides support for the EtherCAT Slave industrial protocol using an EasyCAT Arduino shield. The shield can be driven from a Flowcode compatible Arduino type board or can be driven using an Arduino using the SCADA Slave firmware to drive EtherCAT from the Flowcode simulation runtime. Compatible with the EasyCAT Easy Configurator tool.

Detailed description

No detailed description exists yet for this component

Examples

No additional examples


Downloadable macro reference

SetInt
Write a 16-bit value to the In receive buffer 
- BYTE Index
Data Index 
- UINT Data
 
- VOID Return


MainTask
Must be called as part of the application main program loop. 
- BYTE Return


SetLong
Write a 32-bit value to the In receive buffer 
- BYTE Index
Data Index 
- ULONG Data
 
- VOID Return


GetFloat
Read a 32-bit floating point value from the Out receive buffer 
- BYTE Index
Data Index 
- FLOAT Return


GetLong
Read a 32-bit value from the Out receive buffer 
- BYTE Index
Data Index 
- ULONG Return


GetInt
Read a 16-bit value from the Out receive buffer 
- BYTE Index
Data Index 
- UINT Return


SetByte
Write an 8-bit value to the In receive buffer 
- BYTE Index
Data Index 
- BYTE Data
 
- VOID Return


GetByte
Read a 8-bit value from the Out receive buffer 
- BYTE Index
Data Index 
- BYTE Return


SetFloat
Write a 32-bit floating point value to the In receive buffer 
- BYTE Index
Data Index 
- FLOAT Data
 
- VOID Return


Initialise
Starts up the SPI connection to the EasyCAT board and configures the board. Returns 1 for a sucessful initialise. 
- BOOL Return



Property reference

Properties
Synchronisation Mode
ASYNC = free running i.e. no synchronization between master and slave (default) DC_SYNC = interrupt is generated from the distributed clock unit SM_SYNC = interrupt is generated from the syncronisation manager 
Header File
Used to load a header file from Easy CAT Configurator tool to describe the units inputs and outputs 
Total Byte Num Out
Total number of bytes to come out from the EtherCAT master 
Total Byte Num In
Total bytes to come in from the EtherCAT master 
Connections
Channel
SPI Channel selector 
MOSI
SPI Data Out Pin SDO - Also Known as Master Out Slave In (MOSI) when used in Master mode. 
MISO
SPI Data In Pin SDI - Also Known as Master In Slave Out (MISO) when used in Master mode. 
CLK
SPI Clock Pin CLK - The Clock signal is driven by the SPI master. 
CS / SS
Chip Select / Slave Select Pin Master Mode: General purpose output pin used to select the remote SPI device. Slave Mode: Hardware chip select pin input used to select the SPI device.  
Prescale
Prescale option selector 
Simulations
Simulation Comms
 
Scope Traces
Selects if the scope traces are automatically generated or not 
Console Data
Selects if the console data is automatically generated or not 
API