background image

Programming

BC3150

75

Version: 2.1.0

5.13.2

Program transfer via PROFIBUS

TwinCAT offers a facility for transferring the user program to the Bus Terminal Controller over the fieldbus.
The BC/BX can be selected as the target system in PLC Control, after saving in the registry and restarting
the TwinCAT system. The TwinCAT-level TwinCAT PLC is necessary.

Minimum requirements:

• FC310x with firmware from 2.55

• TwinCAT 2.9 Build 1025

Initializing the Bus Terminal Controller

The coupler must first be made known to the system before it can be selected in PLC Control.
Enter the Bus Terminal Controller in the System Manager, specify type, quantity and size of the fieldbus
variables and link them with a task. For the subsequent program download via the PROFIBUS, the ADS
interface must be enabled for the Bus Terminal Controller in the ADS tab. Save your settings and activate
the configuration. Then start the TwinCAT system and the cyclic task.

TwinCAT System Manager

Fig. 71: ADS Interface

PLC Control

When TwinCAT PLC Control is restarted, TwinCAT asks for the target platform, i.e. the device on which the
user program is later to run. TwinCAT offers two target platforms as controller, the PC or the Bus Terminal
Controller.

Two options are available to you for transmission to the Bus Terminal Controller:

• AMS for BCxx00 (Bus Terminal Controller without online change, one task)

• AMS for BCxx50 and BX (Bus Terminal Controller with online change, two tasks)

• BC serial – the serial cable for communication via the 

RS232 interface [

}

 73]

of the PC and the

programming interface of the Bus Terminal Controller

Содержание BC3150

Страница 1: ...Documentation BC3150 Bus Terminal Controller for PROFIBUS DP 2 1 0 2017 07 11 Version Date...

Страница 2: ......

Страница 3: ...conditions extended temperature range 25 4 Parameterization and Commissioning 26 4 1 Start up behavior of the Bus Terminal Controller 26 4 2 Configuration 27 4 2 1 Overview 27 4 2 2 Creating a TwinCA...

Страница 4: ...s image 76 6 PROFIBUS 78 6 1 Introduction to the system 78 6 1 1 Fieldbus Overview 78 6 1 2 PROFIBUS DP 81 6 1 3 PROFIBUS DPV1 83 6 1 4 Plug connectors cables and switches 84 6 1 5 Topology 86 7 Error...

Страница 5: ...e data diagrams and descriptions in this documentation Trademarks Beckhoff TwinCAT EtherCAT Safety over EtherCAT TwinSAFE XFC and XTS are registered trademarks of and licensed by Beckhoff Automation G...

Страница 6: ...iliar with the applicable national standards Description of symbols In this documentation the following symbols are used with an accompanying safety instruction or note The safety instructions must be...

Страница 7: ...Minor routine corrections typing errors spelling etc English version available 1 0 0 First public issue only in German Firmware BC3150 For updating your firmware you need a serial cable 53 the KS2000...

Страница 8: ...data can be exchanged between the Bus Terminal Controller and the higher level controller via the fieldbus Fieldbus interface The variants of the BCxx50 series Bus Terminal Controllers differ in term...

Страница 9: ...Product overview BC3150 9 Version 2 1 0 2 2 The principle of the Bus Terminal Fig 1 The principle of the Bus Terminal...

Страница 10: ...icro controller Diagnostic LEDs 2 x power supply 2 x K Bus Configuration and programming software TwinCAT PLC Fieldbus interface BC3150 Fieldbus PROFIBUS DP Interfaces Serial interface COM1 RS232 for...

Страница 11: ...t 4 Starting current approx 2 5 x continuous current K bus current 5 V maximum 1000 mA Power contact voltage Up maximum 24 VDC Power contact current load Up maximum 10 A Recomm back up fuse Up 10 A Di...

Страница 12: ...Data transfer rate up to 12 MBaud Topology RS485 line optical fiber ring Transmission time approx 0 5 ms with 10 stations for 32 bits input output at 12 MBaud 2 3 3 Technical Data PLC PLC data BCxx5x...

Страница 13: ...ers for all usual bus systems The Beckhoff Bus Terminal system unites the advantages of a bus system with the possibilities of the compact series terminal Bus Terminals can be driven within all the us...

Страница 14: ...t are necessary for operation of the connected Bus Terminals The operation and configuration of the Bus Terminals is carried out exclusively by the Bus Coupler Nevertheless the parameters that have be...

Страница 15: ...ler and a number of Bus Terminals will be used The mechanical dimensions of the Bus Couplers are independent of the fieldbus system Fig 3 BCxx50 The total width of the fieldbus station is the width of...

Страница 16: ...assembled no significant gap can be seen between the attached housings Fig 5 Power contact on the left Attention Bus Terminals should only be pulled or plugged in switched off state Insertion and rem...

Страница 17: ...er Bus Terminal Controller and Bus Terminals is realized automatically by latching the components The transfer of the data and the supply voltage for the intelligent electronics in the Bus Terminals i...

Страница 18: ...ng e g breakdown of the insulation from a 230 V power consuming device to the PE conductor The PE supply line at the Bus Coupler Bus Terminal Controller must be disconnected for an insulation test In...

Страница 19: ...tage is used for the electronic components of the Bus Coupler Bus Terminal Controllers and via the K bus the electronic components of the Bus Terminals It is galvanically separated from the field leve...

Страница 20: ...connection between feed terminal contacts allows the connection wires to be looped through to various terminal points The current load from the power contact must not exceed 10 A for long periods The...

Страница 21: ...B310 Fig 10 Pin assignment M12 socket B310 Pin assignment M12 socket plug connector B318 Fig 11 Pin assignment M12 socket plug connector B318 Nine pin D Sub Pin 6 transfers 5 VDC pin 5 transfers GND f...

Страница 22: ...types of area where a fieldbus system can be used is largely determined by the choice of the transmission medium and the physical bus interface In addition to the requirements for transmission securit...

Страница 23: ...nected PROFIBUS station not to achieve a connection but for it to be included again when the neighboring station is disconnected Or there may be transmission errors when a specific bit pattern is tran...

Страница 24: ...to the last module Installation guidelines When assembling the modules and laying the cables observe the technical guidelines provided by the PROFIBUS User Organization PROFIBUS Nutzerorganisation e V...

Страница 25: ...otect against the rated operating voltage being exceeded by more than 40 due to short term interference voltages The individual terminals may only be unplugged or removed from the Bus Terminal sys tem...

Страница 26: ...igures the K bus creates a configuration list based on the connected Bus Terminals and starts its local PLC The I O LEDs flash when the Bus Terminal Controller starts up If the system is in an error f...

Страница 27: ...the Bus Terminal Controller must be scanned in the System Manager and FreeRun mode must be enabled to use this function no PLC program may be active on the Bus Terminal Controller TWINCAT CONFIG In th...

Страница 28: ...terface to PLC K bus fieldbus only for BX controllers Support for TwinSAFE terminals only BX controllers from firmware 1 17 In addition the TwinCAT configuration can be used to parameterize special be...

Страница 29: ...c units have already been prepared Open the corresponding Bus Terminal Controller with New from Template Fig 16 Creating a TwinCAT configuration Select the corresponding Bus Terminal Controller Fig 17...

Страница 30: ...0 BC9x20 BC9050 BX3100 BX5100 BX9000 only A prerequisite is that TwinCAT operates as master and is engaged in data exchange i e the physical and fieldbus configuration must be complete and data exchan...

Страница 31: ...Config and the BUS and I O LED will flash Once the configuration is successfully loaded onto Bus Terminal Controller TwinCAT Config should appear in the display of a BXxx00 The corresponding program c...

Страница 32: ...he dialog for downloading your file to the corresponding device Fig 22 Choose Target System Select the corresponding Bus Terminal Controller Fig 23 Selecting the Bus Terminal Controller The state of t...

Страница 33: ...ources tab of the Bus Terminal Controller Mapping code The mapping code is required for calculating the TwinCAT configuration see Figure Memory for the code mapping The percentages are added here In t...

Страница 34: ...Code and data memory 3 Used PLC source in Fig 28 Code and data memory Other memory Fig Other Memory 1 Used Near Heap is required for the COM interface and SSB values Fig Other Memory 2 Used Huge Heap...

Страница 35: ...21 20 1 1 If the IP address of the BX9000 is changed the AMS Net ID of the BX9000 also changes There is a menu option for displaying the cur rent AMS Net ID Example If you change the IP address to 10...

Страница 36: ...led see above Enter the name AMS Net ID and transport type and close the dialog With the second call you can enter your COM port The communication starts when TwinCAT is in Config mode TwinCAT icon is...

Страница 37: ...he output data of the PROFIBUS master are retained unchanged or set to 0 depending on the parameterization From the perspective of the Bus Terminal controller these are input data which the PROFIBUS m...

Страница 38: ...able from the Beckhoff website http www beckhoff de german download bkconfg htm The GSD file can describe the following data types Variable Length Integer 8 1 bytes UnInteger 8 1 bytes Integer 16 2 by...

Страница 39: ...ONFIG Otherwise select your configured BX file If no such file exists you have to create one Creating a BX file 29 Once you have selected your BX file all required PROFIBUS data are copied automatical...

Страница 40: ...FIBUS data ADS Communication has to be selected for preparing the configuration If the configuration data are to be transferred via the fieldbus data communication has to be active i e the BX must be...

Страница 41: ...ng with the PLC project the PLC program must be read in Add your PLC program under PLC Configuration The PLC variables can now be linked with the fieldbus variables Note Permitted number of PROFIBUS d...

Страница 42: ...y Fig 36 https infosys beckhoff com content 1033 bc3150 Resources zip 3733330315 zip Fig 37 https infosys beckhoff com content 1033 bc3150 Resources zip 3733334667 zip Fig 38 https infosys beckhoff co...

Страница 43: ...rameterization and Commissioning BC3150 43 Version 2 1 0 4 2 7 2 4 2 Configuration Siemens S7 controller with BX3100 BX3100 parameter data Fig 39 Settings BX3100 module configuration Sample 1 1 x BX31...

Страница 44: ...Parameterization and Commissioning BC3150 44 Version 2 1 0 Fig 40 Sample for entering individual bytes Note byte for byte Each individual byte requires one byte of ConfigData...

Страница 45: ...Parameterization and Commissioning BC3150 45 Version 2 1 0 Fig 41 Sample for entering associated bytes...

Страница 46: ...cted the Bus Terminal Controller does not enter into data exchange The PLC project will not be started Auto K Bus Reset Once a K bus error has been rectified the Bus Terminal Controller automatically...

Страница 47: ...e Trigger 3 4 x 85 ms 340 ms Reaction on K Bus Error In the event of a K Bus error the K Bus inputs are set to 0 or retain their last state Response on PLC Stop The user can set the behavior of the fi...

Страница 48: ...ord or data structures Automatic addressing via the System Manager is possible but should be checked for offset Note Word alignment byte orientation With data structures ensure that the Bus Terminal C...

Страница 49: ...nd hardware Once all links have been created activate the configuration Actions Activate Configuration Ctrl Shift F4 and start TwinCAT Set Reset TwinCAT to Run Mode Ensure that you have selected the c...

Страница 50: ...ry 20 ms as long as the general cycle time is less than 20 ms To determine the load of your system the PLC cycle time can be measured in the System Manager In order to ensure trouble free operation th...

Страница 51: ...ly The lower switch is the ten multiplier the upper switch is the one multiplier The change in address is active as soon as the module is switched on Example You want to set address 34 Lower rotary se...

Страница 52: ...tection The COM 1 interface of the BXxx00 features automatic baud rate detection between 9 6 kbaud and 56 4 kbaud Note Required KS2000 version Configuration or diagnostics of Bus Terminals at BXxx00 i...

Страница 53: ...rdered separately order identifier KS2000 Z2 Fig 49 Programming cable KS2000 Z2 KS2000 Z2 The programming cable offers the option of programming the BCxx50 via the serial interface Attention Do not in...

Страница 54: ...generation Bus Terminal Controllers are configured with the TwinCAT System Manager and programmed with TwinCAT PLC Control TwinCAT PLC must be installed for these couplers Windows NT4 Windows 2000 Win...

Страница 55: ...Out of global data memory Error POUs For each function block one POU process object unit is created 256 function blocks are available by default Fig 50 Maximum number of POUs exceeded If libraries are...

Страница 56: ...deactivate online changes Global memory error Fig 53 Global memory insufficient 2 x 16 kbyte of data are available by default If large data quantities are to be used this range should be increased A...

Страница 57: ...Programming BC3150 57 Version 2 1 0 Fig 55 Build...

Страница 58: ...ould not be used in function blocks All FB data are copied into the retain memory This leads to an unnecessary increase in cycle time and the retain memory is filled with unnecessary data Note Do not...

Страница 59: ...Meaning Index offset value range 0x4020 Flag only BXxxx0 0 4096 Example BX program VAR Flag_01 AT MB0 WORD END_VAR TwinCAT PC CX master program VAR fbADRSREAD ADSREAD Flag_M WORD END_VAR fbADRSREAD NE...

Страница 60: ...age Mapping within the Bus Terminal Controller is carried out according to the following rule First all the complex Bus Terminals in the sequence they are physically inserted followed by the digital B...

Страница 61: ...www beckhoff de Byte oriented Bus Terminals Bit oriented Bus Terminals KL15x1 KL10xx KL11xx KL12xx KL17xx KM1xxx KL25xx KL20xx KL21xx KL22xx KL26xx KL27xx KM2xxx KL3xxx KL4xxx KL5xxx KL6xxx KL7xxx KL...

Страница 62: ...rminal is inserted the whole address range may be shifted The TwinCAT configuration enables allocated variables to be linked to a Bus Terminal as required This is parameterized in the System Manager a...

Страница 63: ...hen the boot project is deleted Note Using the current project as boot project After an online change the old project is still shown as boot project To use the current project after the online change...

Страница 64: ...wVar_1 0 bInput_01 Note Do not use real values in a mixed data structure A mixed data structure should not contain real values If this is nevertheless the case the high and low words must be swapped...

Страница 65: ...ine change is possible the PLC does not stop All files as Source code only plus all required libraries Source code only compile info excluded only the prx file is transferred Login is only possible wh...

Страница 66: ...wnloading the program code After a short delay a window will open that indicates the download progress Fig 61 Download progress Uploading a program For uploading the program code again open a new file...

Страница 67: ...you are connected to the Bus Terminal Controller via the fieldbus or BCxx50 or BX via serial if you are connected to the Bus Terminal Controller via the serial interface Fig 63 Selecting the data tran...

Страница 68: ...zip 3730728971 zip TcSystemBCxx50 requires the TcBaseBCxx50 library TcBaseBCxx50 https infosys beckhoff com content 1033 bc3150 Resources zip 3730731147 zip ChrAscBX lbx https infosys beckhoff com co...

Страница 69: ...5200 BX8000 SFC Version Firmware BC3150 BC5150 BC5250 BC8150 AnalyzeExpression AppendErrorString SFCActionControl System Time TBus Version Firmware BC3150 BC5150 BC5250 BC8150 DRAND B0 B0 B1 B0 SYSTEM...

Страница 70: ...unction starts the timer The return value is 0 Read Debug Timer function Fig 66 Function block F_READDEBUGTIMER This function reads the timer value The return value has to be multiplied with 5 12 s Ex...

Страница 71: ...able indicates whether the task is active taskName the task name firstCycle During the first PLC task cycle this variable has the value TRUE cycleTimeExceeded this variable indicates whether the set t...

Страница 72: ...6 1 Local ADS Port Numbers Port number Description 100 72 dec Reading and writing of registers and tables from the coupler and the complex Bus Terminals 801 72 dec Local PLC process image 5 12 2 6 2...

Страница 73: ...1 255 0 3 1 255 Register of the Bus Terminals Hi Word channel number Lo Word register number of the Bus Terminal Note Minimum timeout When reading the register the time out of the ADS block has to be...

Страница 74: ...erial interface Program transfer via the serial interface and ADS The Bus Terminal Controller can be programmed via the PC s RS232 interface Before you can work with the Bus Terminal Controller TwinCA...

Страница 75: ...h a task For the subsequent program download via the PROFIBUS the ADS interface must be enabled for the Bus Terminal Controller in the ADS tab Save your settings and activate the configuration Then st...

Страница 76: ...specified on the slave side i e in the BC3150 The BC3150 can process a maximum of 128 bytes of input data and 128 bytes of output data Two configuration types are available No special configuration i...

Страница 77: ...ress gaps are only permitted if they are configured on the master side Otherwise addressing must be continuous from address 1000 TWINCAT CONFIG For the TwinCAT CONFIG a configuration must be created v...

Страница 78: ...ave been received or to send messages in response to a request from master Slaves are referred to as passive devices They only require a small proportion of the bus protocol which means that they can...

Страница 79: ...ved with this system configuration Multi Master Operation In a multi master mode there is more than one master on the bus They either form subsystems that are independent of one another each consistin...

Страница 80: ...reeze control command similarly causes the addressed DP slaves to enter Freeze mode In this operation mode the states of the inputs are frozen at their current value The input data is only updated aga...

Страница 81: ...the monitoring interval In this case the user is informed If automatic error reaction is enabled Auto_Clear True then the DPM1 leaves the Operate state switches the outputs of the assigned slaves int...

Страница 82: ...the core of the PROFIBUS DP protocol is the cyclic data exchange during which the master exchanges I O data with each slave within a PROFIBUS DP cycle This involves the master sending the outputs to...

Страница 83: ...d Class 2 C2 connections is that the acyclic C1 connection is established during the DP StartUp phase of cyclic DP operation Once the slave has reached the WAIT CFG state it is possible for acyclic DP...

Страница 84: ...to some surprising phenomena This could for example be that some station is not connected but when the neighboring station is unplugged the connection appears again Or there may be transmission error...

Страница 85: ...2 Mbit s infinitely variable Connector 9 pin D sub connector for IP20 M12 round connector for IP65 67 Cabling for PROFIBUS DP and PROFIBUS_FMS Fig 75 PROFIBUS cable assignment Note Termination resisto...

Страница 86: ...um of 32 devices including the repeaters The maximum cable length of a segment depends on the data transfer rate in use and on the quality of the bus cables being used No more than 9 repeaters may be...

Страница 87: ...PROFIBUS BC3150 87 Version 2 1 0 Fig 78 RS485 topology with 3 segments and 2 repeaters...

Страница 88: ...ulled or the PLC is switched the Bus Terminal Controller indicates this by reporting 130 in DP state That is the Bus Terminal Controller is waiting for parameter data from the master Slave boot sequen...

Страница 89: ...6 0006 IndexOffset 16 000C_9000 LEN 1 7 2 Diagnostic LEDs The Bus Coupler features status indicator LEDs The row of LEDs on the left describes the status of the fieldbus and of the PLC The row of LEDs...

Страница 90: ...l n Exchange the nth Bus Terminal 6 0 Error at initialization Exchange Bus Coupler 1 Internal data error Perform a hardware reset on the Bus Coupler switch off and on again 2 DIP switch changed after...

Страница 91: ...ler has found baud rate waiting for config and parameter data LED RUN LED BF LED DIA Meaning off off off no fieldbus connected Bus Coupler searches for baud rate on on on on on off Bus Coupler has fou...

Страница 92: ...ly unit etc Software TwinCAT 2 9 build 1020 minimum TwinCAT PLC level Example 1 Default Configuration a Open the following link https infosys beckhoff com content 1033 bc3150 Resources tsm 3730735499...

Страница 93: ...address and the physical connection to the PROFIBUS master terminating resistors etc a Open the following link https infosys beckhoff com content 1033 bc3150 Resources prx 3730737675 prx This link is...

Страница 94: ...tatus and cycle tick is not copied to the BCxx50 BCxx20 This information is available in TcSystemBCxx50 lbx as a function for the BCxx50 BCxx20 The allocated flags do not act as retain variables Retai...

Страница 95: ...ory 256 kbyte Task time The task time is specified in the PLC Control It should be set to a realistic value measuring of PLC cycle time and K Bus The background time is not used Task configuration A m...

Страница 96: ...e serial interface Note for BX3100 Updates are not available with BX3100 firmware 0 64 or lower If these devices need updating send the BX3100 to the manufacturer with a corresponding note Beckhoff Au...

Страница 97: ...port Fig 87 Select the COM port Open the file you wish to download Fig 88 Open the firmware file Start the download via the green traffic light The download begins after about a minute and is then al...

Страница 98: ...chnical data Installation position variable Vibration resistance conforms to EN 60068 2 6 Shock resistance conforms to EN 60068 2 27 EMC immunity conforms to EN 61000 6 2 Emission conforms to EN 61000...

Страница 99: ...urer Beckhoff Automation GmbH Co KG CE mark Conformity mark UL mark Mark for UL approval UL stands for the Underwriters Laboratories Inc the leading certification organization for North America based...

Страница 100: ...rman books PROFIBUS PROFIBUS DP DPV1 Basic principles tips and tricks for users by Manfred Popp ISBN 3778527819 General fieldbus technology Gerhard Gruhler Pub Fieldbuses and device communication syst...

Страница 101: ...German device master file GSE file English device master file IP20 IP65 IP66 IP67 Protection class contact water dust K bus Terminal Bus Internal bus for communication between Bus Coupler and Bus Term...

Страница 102: ...onents there Beckhoff Headquarters Beckhoff Automation GmbH Co KG Huelshorstweg 20 33415 Verl Germany Phone 49 0 5246 963 0 Fax 49 0 5246 963 198 e mail info beckhoff com Beckhoff Support Support offe...

Страница 103: ...n 29 Fig 17 Selecting the Bus Terminal Controller 29 Fig 18 Downloading a TwinCAT configuration 30 Fig 19 Selecting the Bus Terminal Controller 31 Fig 20 State of the Bus Terminal Controller 31 Fig 21...

Страница 104: ...k F_READDEBUGTIMER 70 Fig 67 Selecting the data transfer route serial interface 73 Fig 68 Parameterization of the serial interface 74 Fig 69 Selecting the data transfer route AMS 74 Fig 70 Selecting t...

Отзывы: