FC510x - PCI Cards for CANopen

Configuration: TwinCAT System Manager

The TwinCAT System Manager Tool is used to configure the FC510x CANopen PCI card. The System Manager provides a representation of the number of programs of the TwinCAT PLC systems, the configuration of the axis control and of the connected I/O channels as a structure, and organizes the mapping of the data traffic.

 
 systemmanager
TwinCAT System Manager

For applications without TwinCAT PLC or NC, the TwinCAT System Manager Tool configures the programming interfaces for a wide range of application programs:

ActiveX control (ADS-OCX) for e.g. Visual Basic, Visual C++, Delphi, etc.
DLL interface (ADS-DLL) for e.g. Visual C++ projects
Script interface (ADS script DLL) for e.g. VBScript, JScript, etc.
 

System Manager – Features

Bit-wise association of server process images and I/O channels
Standard data formats such as arrays and structures
User defined data formats
Continuous variable linking
Drag and Drop
Import and export at all levels
 

The procedure and the configuration facilities in the System Manager are described below.

 

Context menu

Context menu
 
 

Append Box... <Insert>

Adds CANopen slaves (boxes). The following boxes are currently supported (more detailed description of the boxes is given further down):

Supported boxes
Description
Bus Coupler
Economy Bus Coupler
Bus Coupler (successor of BK5100)
Low-cost Bus Couplers
Fieldbus compact box: CANopen in/output module, protection class IP67
General CANopen device or general CAN device (access via CAN layer 2)
 
 

Delete Device... <Del>

Removes the FC510x fieldbus card and all subsidiary elements from the I/O configuration.

 
 

Online Reset

Initiates an online reset on the CANopen bus.

 
 

FC510x tab

 
FC510x tab
 
 

PCI Bus/Slot

Indicates in which logical PCI slot the card was found.

 
 

Master-Node-ID

Node address for the FC5100. Range of values: 1...127. Determines the identifier of the master heartbeat telegram. Ensure that it is not the same as a slave node address. 

 
 

Baud rate

Set the baud rate here. Automatically tests whether the connected slave also supports this baud rate.

 
 

Synchronization Mode

The Synchronization Mode determines the accuracy with which the CANopen SYNC telegram is generated.

The highest-priority task linked to the FC510x card handles the control of the CANopen card and is thus synchronized with the CANopen bus. All other tasks are served asynchronously via corresponding buffers. For all operation modes you can individually set the communication type for each process data object (PDO) - event driven or synchronized (in each PDO tab). If one of the PDOs has been configured for a synchronous operation mode, a SYNC telegram is sent at the start of the cycle, which the slaves use to synchronize their actions with the master cycle.

Different modes can be selected, depending on the SYNC accuracy requirements. Note that individual SYNC telegrams in CAN systems inherently jitter by one telegram length if the bus is occupied at the time of the SYNC. The SYNC accuracy therefore primarily refers to the long-term stability. Bus nodes that synchronize via a PLL procedure are particularly dependent on good long-term stability.

 
Synchronization Mode
 
 

Slave

In slave mode, the card receives its time base from a SYNC master. The Sync Master is selected via the corresponding field.

Sync Master: PC Task. This is the default setting. The PC sets the timebase based on the TwinCAT real-time. Depending on the setting, the task start (default for TwinCAT NC) or task end (default for TwinCAT PLC) triggers the SYNC telegram. 
Sync Master: Balanced PC Task. In this operation mode, the sync cycle is also generated with the accuracy of the PC time base on average. However, the interval between two SYNC telegrams is more accurate than with the Sync Master "PC task":
runtime differences (e.g. due to case-dependent program branches) are compensated,
the FC510x card delays pending send telegrams until after the SYNC telegram,
the individual SYNC distances are determined by the crystal-precise timer of the FC510x card.

If necessary, the card timer is readjusted in small steps to the PC timer if it the latter deviates from the card timer by the value set in "PLL Sync Time".
In this mode, the sync telegram is delayed by the shift time relative to the completion of the TwinCAT task. The shift time should be as small as possible in this mode, but sufficiently large to ensure that the TwinCAT task can access the process data. The function "Calculate Equi-Times", which is triggered by clicking on the corresponding button after the mappings have been created, helps to set the optimum shift time.

 
Synchronization Mode: Slave (sync master: balanced PC clock)
 
 

Master

In master mode the card generates its time base locally. The SNYC telegram is crystal-precise on average. The start of the TwinCAT task is specified by the card and is delayed by the shift time relative to the SYNC telegram. In this mode, the shift time should be selected as large as possible. The function "Calculate Equi-Times", which is triggered by clicking on the corresponding button after the mappings have been created, helps to set the optimum shift time.

 
Synchronization Mode: Master
 
 

Cycle Time

Displays the cycle time of the corresponding highest priority task. The display is updated when the mapping is generated.

 
 

Watchdog Time

Here, a watchdog can be activated, which means that the FC510x enters STOP mode in the event of a PC crash and also transfers all projected slaves to this state.

 
 

Sync-Cycle Multiplier

CANopen SYNC Cycle Time = (Task) Cycle Time x Sync-Cycle Multiplier. Event driven PDO communications and cyclical synchronized PDO communication are frequently combined when used in conjunction with CANopen. In order to be able to respond rapidly to an event, the TwinCAT task cycle time has to be less than the CANopen SYNC cycle time. If the sync cycle multiplier is set to values > 1, the TwinCAT task is called repeatedly before the SYNC telegram is sent again.

 
 

Sync-Cycle Time

The cycle time of the CANopen snyc telegram is displayed here. It results from the cycle time of the highest-priority task, whose process data are linked with the card, and from the sync cycle multiplier.

 
 

Sync-Tx-PDO Delay

Directly after the SYNC telegram, the synchronized slaves send their input data/actual values. The FC510x can delay the sending of the output data / set value (TxPDOs from the perspective of the card) in order to minimize the telegram burst directly after the SYNC. This delay is set in percent of the SYNC cycle time with the parameter Sync-Tx-PDO -Delay.

 
Example

Task Cycle Time = 2000 µs, Sync-Cycle Multiplier = 5, Sync Tx-PDO Delay =40. The PLC task can process event-driven PDOs every 2 ms; the CANopen sync cycle is 10 ms; the FC510x sends its synchronous PDOs 4 ms (=40% of 10 ms) after the SYNC.

 
 

Search...

This is used to search all existing FC510x channels; the required channel can be selected. In the case of an FC5102 both channels A and B appear. These behave in logical terms like two FC5101 cards.

 
 

Hardware Configuration...

In which the address of the FC510x is set in the lower memory area (below 1 MB) of the PC.

 
 

Upload Configuration

Scans the CANopen network and adds all detected equipment to the device (FC510x) (boxes cannot be added). In the case of Beckhoff boxes, reads the configuration precisely. In the case of external devices, the PDO configuration and the identity object are read and evaluated.

 
 

Verify Configuration

Allows a comparison of the expected (entered) network configuration with the devices actually found in the network. The data from the CANopen Identify Object are read and compared. In the case of Beckhoff boxes the connected Bus Terminals or extension modules are read and compared (under preparation).

 
 

Firmware

Shows the current firmware version of the FC510x.

 
 

Firmware Update...

Update the FC510x card firmware version here. Attention: The TwinCAT System must be stopped for this function.

 
 

ADS tab

The FC510x is an ADS device with its own net ID, which can be changed here. All ADS services (diagnostics, acyclic communication) intended for the FC510x, have to address the card via this Net-ID.

 
 

Box States tab

 
Box States tab

Displays an overview of all current box states.

 
 

DPRAM (Online) tab

Refer to "Online display of DPRAM" in the System Manager documentation.

 
 

Diagnostic Inputs

The FC510x automatically provides various diagnostic variables which describe the status of the card and the CANopen network:

FC510x - diagnostic variables

cycleCounter: Is incremented at the end of each firmware cycle in order that this variable can indicate whether the last cycle was completed before the task was started

error: Shows the number of slaves whose Box State is not equal to zero. Only check the BoxState of the slaves if this value is other than 0

actualCycleTime: Shows the current cycle time in 4/25 µs. This variable is only updated when all slaves are involved in the data exchange (and when error is 0)

DiagFlag: Shows whether the diagnostics information on the card has changed. This can be read off using ADS-Read. For that purpose, specify the net ID of the FC510x, the port number 200 and the IndexGroup 0xF100. The IndexOffset and the length then relate to the diagnostic data. (Note: the Box States are also directly available as variables.)

Offset 1-127: BusStatus List, 1-127 one byte each station address which contains the station status (see BoxState for CANopen boxes)

Global State: Various diagnostic and status displays for the FC510x. The byte in GlobalState(0) shows the status of the card in relation to the TwinCAT system: RUN, RESET, OFFLINE and STOP are distinguished. GlobalState(2) gives information about the status of the CAN controller: "CAN Warning Limit Reached" and "Bus Off" are displayed. Warning limit reached means that the send/receive error counter on the CAN controller has exceeded the value 96. BusOff means that the CAN controller can no longer participate in bus communication; this is caused by an excessive number of CAN errors (Error Frames). In this case there is a serious physical error in the CAN network. (e.g. too few or too many termination resistors, at least one device with incorrect baud rate, short circuit, etc.) The "bus off" state can only be exited through a card reset. Details about further global state data, see comments in "Online" tab.

LastAdsError: Shows the error code of the last ADS access error, e.g. if an attempt has been made to read the diagnostic data for a deactivated node.

CycleFailedCounter: Counts the number of firmware cycles, which could not be completed before the corresponding task tried to read or write the process image again. If this counter is incremented, the task cycle time has been set too low for the actual network configuration.

BusLoad: Shows the current bus load in %. The Bus Load is an important design criterion for CAN networks. The value shown is an average value over 100 ms.