background image

 

 

Basic Principles 

 

BC7300 

15

    

 

Peripheral Data in the Process Image 

 

 

After  being  switched  on,  the  Bus  Coupler  determines  the  configuration  of 
the inserted input/output terminals. The assignment of the physical slots for 
the  input/output  channels  and  the  addresses  in  the  process  image  is 
carried out automatically by the Bus Coupler. 
 
The  Bus  Coupler  creates  an  internal  assignment  list,  in  which  the 
input/output  channels  have  a  specific  position  in  the  process  image.  A 
distinction is made here according to inputs and outputs, and according to 
bit-oriented  (digital)  and  byte-oriented  (analog  or  complex)  signal 
processing.  
 
Two  groups  are  created,  one  for  inputs  and  the  other  for  outputs.  Each 
group has the byte-oriented channels in ascending sequence starting from 
the lowest address. The bit-oriented channels are placed after this block. 
 

Digital signals 
(bit-oriented) 

The digital signals are bit-oriented.  This means that one bit in the process 
image  is  assigned  to  each  channel.  The  Bus  Coupler  creates  a  memory 
area containing the current input bits, and ensures that the bits in a second 
memory area dedicated to the output channels are written out immediately. 
 
The  details  of  the  assignment  of  the  input  and  output  channels  to  the 
controller's process image  is explained fully  with the  aid of an  example in 
the appendix.  
 

Analog signals 
(byte-oriented) 

The processing of all analog signals is always byte-oriented.  Analog input 
and  output  values  are  represented  in  memory  by  two  bytes  each.  Values 
are  represented  in  SIGNED  INTEGER  or  two‘s  complement  format.  The 
number "0" stands for the input/output value "0 V", "0 mA" or "4 mA". The 
maximum value of an output or input value is represented, according to the 
standard settings, by "7FFF" (hex). Negative input or output  values, e.g. -
10  V,    are  represented  from  "8000"  (hex).  The  intermediate  values  are 
correspondingly  proportional.  A  range  with  a  resolution  of  15  bits  is  not 
achieved  for  all  inputs  and  outputs.  If  the  actual  resolution  is  12  bits,  the 
last  three  bits  have  no  effect  in  outputs,  while  as  inputs  they  are  read  as 
"0".  Each  channel  also  has  a  control  and  status  byte.  The  control  and 
status  byte  is  the  lowest  value  byte.  The  master  configuration  software 
must  specify  whether  the  control/status  byte  is  also  mapped  into  the 
controller.  An  analog  channel  is  represented  in  the  process  image  by  2 
bytes of user data. 
 

Special signals and 
interface 

A  Bus  Coupler  supports  Bus  Terminals  with  other  interfaces  such  as 
RS232,  RS485,  incremental  encoder  and  others.  These  signals  can  be 
considered similarly to the analog signals named above. For some special 
signals  the  bit  width  of  16  is  not  sufficient.  The  Bus  Coupler  can  support 
any byte width. 
 

Default assignment of 
inputs/outputs to the 
process image 

Once  it  has  been  switched  on,  the  Bus  Coupler  finds  out  how  many  Bus 
Terminals  are  inserted,  and  creates  an  assignment  list.  The  analog  and 
digital  channels,  divided  into  inputs  and  outputs,  are  assembled  into 
separate parts of this list. The assignment starts on the left next to the Bus 
Coupler. The software in the Bus Coupler collects the individual entries for 
each  of  the  channels  in  order  to  create  the  assignment  list  counting  from 
left to right.  

Summary of Contents for BC7300

Page 1: ...MODBUS Bus Terminal Controller BC7300 Version 1 5 Last change 2006 11 06...

Page 2: ...pment For that reason the documentation is not in every case checked for consistency with performance data standards or other characteristics and does not represent an assurance of characteristics in...

Page 3: ...errors 18 3 MODBUS 19 Basic Principles 19 Bus Topology 19 Process Data and Memory Map 20 MODBUS Process Image 22 BC7300 Process Image 22 Assignment of the Bus Terminals 23 Setting and Parameterisatio...

Page 4: ...als 42 List of references 42 Firmware 42 Table 42 Example Program 43 Explanation of the Program 43 The Program in the Bus Terminal Controller 43 Creating the BOOT Program 44 MODBUS Communication 44 6...

Page 5: ...cked for consistency with performance data standards or other characteristics None of the statements of this manual represents a guarantee Garantie in the meaning of 443 BGB of the German Civil Code o...

Page 6: ...ed and nullify the liability of Beckhoff Automation GmbH Description of safety symbols The following safety symbols are used in this documentation They are intended to alert the reader to the associat...

Page 7: ...ndustrial PC as the controller means that the operating and observing element can be implemented in the controller s hardware The controller can therefore be located at an operating panel in a control...

Page 8: ...rinciple of the Bus Terminal 02 01 PE PE WD RX TX PLC MODBUS BECKHOFF 24V 0V 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 K Bus End Terminal Potential isolation Potential input terminal Power contacts Bus...

Page 9: ...inals can be used to feed the supply for the peripherals The spring loaded terminals are joined in pairs to a power contact The feed for the power contacts has no connection to the voltage supply for...

Page 10: ...Bus Contacts 6 contacts on the side In order to connect the Bus Coupler and Bus Terminals the Bus Coupler has gold contacts on the right hand side When the Bus Terminals are pushed together the gold c...

Page 11: ...us Terminal Controller enters the STOP state Once the start up has completed without error the Bus Terminal Controller enters the fieldbus start state Start up behaviour of the Bus Terminal Controller...

Page 12: ...upler for example Maximum number of terminals Up to 64 Bus Terminals can be attached to the Bus Coupler on the right hand side When plugging the components together be sure to assemble the housings wi...

Page 13: ...sons this contact mates first when plugging together and can ground short circuit currents of up to 125 A Note that for reasons of electromagnetic compatibility the PE contacts are capacitatively coup...

Page 14: ...ms to EN 50082 ESD Burst EN 50081 Installation position any Type of protection IP20 PLC data Programmability via programming interface TwinCAT BC TwinCAT Program size approx 3000 PLC statements Progra...

Page 15: ...are represented in SIGNED INTEGER or two s complement format The number 0 stands for the input output value 0 V 0 mA or 4 mA The maximum value of an output or input value is represented according to t...

Page 16: ...nterfaces Those chapters of this manual that deal with the fieldbus refer to the most widespread interfaces Complex signal processing All the byte oriented signal channels such as RS232 RS485 or incre...

Page 17: ...nal n 0 coupler Check whether the n 1 Bus Terminal is correctly connected replace if necessary Check whether the Bus End Terminal 9010 is connected 5 pulses n K Bus error with register communication w...

Page 18: ...flashes while a boot project is being created WD RX TX PLC MODBUS If a K Bus error occurs during operation the procedures for reaction to a K Bus error are executed in accordance with the parameterisa...

Page 19: ...7 6 5 4 3 2 1 BK 7300 02 01 02 01 PE PE 02 01 PE PE 02 01 PE PE 02 02 01 01 PE PE PE PE RUN RX TX MODBUS BECKHOFF 24V 0V 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 BK 7300 02 01 02 01 PE PE 02 01 PE PE...

Page 20: ...er is the process image on the Bus Terminal Controller Bus Terminals can be assigned to one or the other process image The PLC variables offer an interface between these two process images MODBUS The...

Page 21: ...ses I128 and Q128 Example 02 PE PE PE PE RUN RX TX MODBUS BECKHOFF 24V 0V 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 BC 7300 PE PE PE PE PE PE PE PE PLC PE PE PE PE PE PE PE PE POS 1 KL1012 MODBUS termin...

Page 22: ...bit 16 bit MODBUS example PLC variables 16 byte outputs 3 6 16 23 0x0003 0x0004 0x0005 0x0006 0x0007 0x0008 0x0009 0x000A 16 bit 16 bit 16 bit 16 bit 16 bit 16 bit 16 bit 16 bit BC7300 Process Image...

Page 23: ...oriented Bus Terminal means that only the user data is transmitted Example a KL3xx2 has 2 input words and a KL4xx2 has 2 output words Complex Complex evaluation of a byte oriented Bus Terminal means...

Page 24: ...ve all the terminals except the KL9010 end terminal 3 Set the x10 address selection switch to 0 and the x1 switch to 3 4 Switch on the Bus Coupler s 24 V supply again The coupler indicates the set bau...

Page 25: ...stop bits 8 8 data bits no parity two stop bits 9 8 data bits even Parity two stop bits 10 8 data bits odd Parity two stop bits 11 7 data bits even Parity two stop bits Frame 2 12 1 7 data bits odd P...

Page 26: ...LRC END ASCII frame 1 charact er 2 charact ers 2 charact ers n charact ers 2 charact ers 2 charact ers CRLF RTU In RTU mode the protocol starts with a pause of 3 5 characters and finishes in the same...

Page 27: ...ta outputs GPRs GPR General Preset Register see Modbus Interface The functions are briefly described in the next section and clarified with the aid of an example Read Digital Outputs Function 1 READ C...

Page 28: ...0x0A 10 0x31 0x30 Error Check LRC CRC 0xF8 0xA7 E3 0x45 0x33 End of frame t1 t2 t3 CRLF 0xD 0xA Response The Bus Terminal Controller answers with byte count 2 i e 2 bytes of data are returned The quer...

Page 29: ...low byte 255 0xFF FF 0x46 0x46 Data 2 high byte 0 0x00 00 0x30 0x30 Data 2 low byte 0 0x00 00 0x30 0x30 Error Check LRC CRC 0xC6 0xC1 B0 0x42 0x30 End of frame t1 t2 t3 CRLF 0xD 0xA Read Analog Inputs...

Page 30: ...must contain 0x00 hex Query Byte Name Example RTU ASCII Start frame 0x3A Slave address 11 0x0B 0B 0x30 0x42 Function code 5 0x05 05 0x30 0x35 Start address high 0 0x00 00 0x30 0x30 Start address low 2...

Page 31: ...a low 255 0xFF FF 0x46 0x46 Error Check LRC CRC 0xDA 0xB0 A9 0x41 0x39 End of frame t1 t2 t3 CRLF 0xD 0xA Writing a Number of Digital Outputs Function 15 FORCE MULTIPLE COILS Function 15 can be used t...

Page 32: ...Start address low 0 0x00 00 0x30 0x30 Data high 0 0x00 00 0x30 0x30 Data low 20 0x14 14 0x30 0x34 Error Check LRC CRC 0xDA 0xB0 D2 0x44 0x32 End of frame t1 t2 t3 CRLF 0xD 0xA Writing a Number of Anal...

Page 33: ...th high 0 0x00 00 0x30 0x30 Length low 2 0x02 02 0x30 0x32 Error Check LRC CRC 0x43 0x02 DB 0x44 0x42 End of frame t1 t2 t3 CRLF 0xD 0xA Writing and Reading Analog Outputs and Inputs Function 23 READ...

Page 34: ...ount The data information follows In this example the first word contains 0x0038 hex while the second word contains 0x3F0B Byte Name Example RTU ASCII Start frame 0x3A Slave address 11 0x0B 0B 0x30 0x...

Page 35: ...ses the data that is sent to the slave by the master to be returned Bus Coupler Reset Sub Function 1 Sub function 1 re initialises the BC7300 Error counters are reset and the coupler executes a self t...

Page 36: ...nction 15 Contains the number of answers that the slave has not sent For example the slave does not send an answer to a broadcast message Sub function Data field query Data field response 00 0F 00 00...

Page 37: ...Invalid address or length 3 ILLEGAL DATA VALUE Invalid parameter Diagnostic functions Incorrect number of read write accesses to the register 4 SLAVE DEVICE ERROR Watchdog or K Bus error Example The...

Page 38: ...udes that required for the K Bus update This results in a connection between the number of terminals that are inserted and the cycle time Before initiating the program the Bus Terminal Controller exec...

Page 39: ...e same area as the Retain Variables and also start at MB0 You first have to enable Retain Variables in order to achieve a storage increase through the Persistent Data By default no Persistent Variable...

Page 40: ...bit is set to 1 if a write telegram has been processed and no new write telegram is sent to the Bus Terminal Controller within the watchdog time No other bits have any function K Bus diagnostics K Bus...

Page 41: ...e complex terminals and Bus Coupler registers can both be read or written using the 2 byte PLC interface The complex terminal registers are described in the associated terminal documentation The Bus C...

Page 42: ...KL9110 KL9160 KL9210 KL9260 List of references Modicon MODBUS Protocol Reference Guide http www modicon com Software Win TECH http www win tech com Firmware The label under the coupler will tell you...

Page 43: ...his is included when TwinCAT BC or KS2000 is supplied The first step is to create a program in the BC7300 For this purpose the address selection switch is set to 00 This it the programming mode for th...

Page 44: ...eate boot project The PLC LED flashes while the boot project is being created Now set the MODBUS slave address and switch the Bus Terminal Controller off and then on again Remove the programming cable...

Page 45: ...Controller answers with byte count 4 i e 4 bytes of data are returned The query was for 2 input words and these are now distributed over 4 bytes Byte Name Example RTU Description Start frame Slave add...

Page 46: ...QB0 QB7 in the memory The digital output terminal would now map to QX8 0 and QX8 1 As soon as you now plug another byte oriented Bus Terminal the process image of the digital Bus Terminal is moved to...

Page 47: ...000 8 List of references 40 Manufacturer s setting 44 Mapping of digital Bus Terminals 44 Mechanical structure 9 Parameterisation 22 Parameterisation Table 23 Persistent Data 37 PLC Cycle Time 36 PLC...

Page 48: ...mponents there Beckhoff Headquarters Beckhoff Automation GmbH Eiserstr 5 33415 Verl Germany phone 49 0 5246 963 0 fax 49 0 5246 963 198 e mail info beckhoff com web www beckhoff com Beckhoff Support S...

Reviews: