1. Overview
PROFIBUS-DP, where DP stands for Decentralized Periphery, is a type of computer electronic component. It features high speed and low cost, used for communication between device-level control systems and decentralized I/O. It, along with PROFIBUS-PA (Process Automation) and PROFIBUS-FMS (Fieldbus Message Specification), constitutes the PROFIBUS standard.
2. Basic Information
Specifications
The PROFIBUS-DP protocol clearly defines how user data is transmitted between stations on the bus, while the meaning of user data is specifically described in the PROFIBUS specifications. Additionally, the specifications detail how PROFIBUS-DP is used in application fields. By using the specifications, devices produced by different manufacturers can be interchangeable, and factory operators do not need to worry about the differences between them, as the meanings related to applications are precisely defined in the specifications. Below are the PROFIBUS-DP specifications, with the numbers in parentheses indicating the document numbers: (1) NC/RC Specification (3.052) (2) Encoder Specification (3.062) (3) Variable Speed Drive Specification (3.071) (4) Operator Control and Process Monitoring Specification (HMI)
Transmission Distance
The transmission rate of Profibus ranges from 9.6K to 12Mbps, with a maximum transmission distance of 1000m at 9.6K to 187.5Kbps, 400m at 500Kbps, 200m at 1500Kbps, and 100m at 3000K to 12000Kbps, which can be extended to 10km using repeaters. The transmission medium can be twisted pair cables or optical fibers, with a maximum of 127 stations connected.Profibus is recognized as the German national standard DIN 19245 and the European standard prEN 50170 for fieldbus systems. The ISO/OSI model also serves as its reference model. The Profibus series consists of Profibus-DP, Profibus-FMS, and Profibus-PA. The DP type is used for high-speed transmission between decentralized peripherals, suitable for applications in process automation. FMS stands for Fieldbus Message Specification, applicable to general automation such as textiles, building automation, programmable controllers, and low-voltage switches, while PA is a bus type used for process automation, adhering to the IEC1158-2 standard. This technology was jointly developed by Siemens and several other German companies and research institutes. It employs the physical layer and data link layer of the OSI model, forming a subset of the first part of its standard, with the DP type omitting layers 3 to 7, while adding direct data connection as a user interface. The FMS type only omits layers 3 to 6, using the application layer as the second part of the standard. The PA type standard is still under development, and its transmission technology adheres to the IEC1158-2 (1) standard, enabling bus power supply and intrinsic safety explosion-proof features.Profibus supports several transmission modes, including master-slave systems, pure master systems, and mixed multi-master and slave systems. The master station has control over the bus and can actively send information. In a multi-master system, information is passed between masters using a token method, where the station that receives the token has control of the bus for a predetermined time, with the maximum time for the token to circulate among the masters predefined. According to the Profibus communication specifications, the token is passed between masters in ascending address order.When the master station gains control, it can send or request information from the slave station in a master-slave manner, achieving point-to-point communication. The master station can broadcast to all stations (no acknowledgment required) or selectively broadcast to a group of stations.
Extended Functions
The DP extended functions supplement the basic DP functions and are compatible with them. (1) Non-cyclic data transmission between DPM1 and DP slaves. (2) Non-cyclic read/write functions with DDLM read and DDLM write, allowing reading and writing of any desired data from the slave. (3) Alarm response, where the basic DP function allows DP slaves to spontaneously transmit diagnostic information to the master station regarding events, while the newly added DDLM-ALAM-ACK function is used to directly respond to alarm data received from DP slaves. (4) Non-cyclic data transmission between DPM2 and slaves.
Data Files
To integrate PROFIBUS products from different manufacturers, manufacturers must store the functional parameters of these products (such as I/O point count, diagnostic information, baud rate, time monitoring, etc.) in GSD files (Generic Station Description files). Standard GSD data expands communication to the operator control level. Configuration tools based on GSD can integrate devices produced by different manufacturers into the same bus system.GSD files can be divided into three parts: (1) General specifications: including manufacturer and device names, hardware and software versions, baud rate, monitoring time intervals, and bus connector designated signals. (2) DP-related specifications: including parameters applicable to the master station, such as the number of allowed slaves and upload/download capabilities. (3) DP slave-related specifications: including all specifications related to the slave, such as input/output channel counts, types, diagnostic data, etc.3 GSD File FormatGSD files are ASCII files and can be edited with any ASCII text editor, such as Notepad, UltraEdit, etc., or using the editing program GSDEdit provided by the PROFIBUS user organization. A GSD file consists of several lines, each starting with a keyword, including both the keyword and parameters (unsigned numbers or strings). The keywords in a GSD file can be standard keywords (defined in the PROFIBUS standard) or custom keywords. Standard keywords can be recognized by any PROFIBUS configuration tool, while custom keywords can only be recognized by specific configuration tools.An example of a GSD file is as follows:#Profibus DP; All GSD files for DP devices begin with this keywordGSD Revision=1; GSD file versionVendorName=”Meglev”; Device manufacturerModel Name=”DP Slave”; Product nameRevision=”Version 01″; Product versionRevisionNumber=01; Product version number (optional)IdemNumber=0x01; Product identification numberProtocol Ident=0; Protocol type (indicating DP)StationType=0; Station type (0 indicates slave)FMS Supp=0; FMS not supported, pure DP slaveHardware Release=”HW1.0″; Hardware versionSoftware Release=”SW1.0″; Software version9.6 supp=1; Supports 9.6kbps baud rate19.2 supp=1; Supports 19.2kbps baud rateMaxTsdr 9.6=60; Maximum delay time at 9.6kbpsMaxTsdrl9.2=60; Maximum delay time at 19.2kbpsRepeaterCtrl sig=0; No RTS signal provided24VPins=0; No 24V voltage providedImplementation Type=”SPC3″; Solution adoptedFreezeMode Supp=0; Locking mode not supportedSyncMode Supp=0; Synchronization mode not supportedAutoBaud Supp=1; Supports automatic baud rate detectionSet SlaveAdd Supp=0; Slave address change not supportedFail Safe=0; Fail-safe mode typeMaxUser PrmDataLen=0; Maximum user parameter data length (0-237)User prmDataLen=0; User parameter lengthMin Slave Interval=22; Minimum slave response cycle intervalModular Station=1; Whether it is a modular stationMaxModule=1; Maximum number of modules for the slaveMaxInput Len=8; Maximum input data lengthMaxOutput Len=8; Maximum output data lengthMaxData Len=16; Maximum data length (sum of input and output)MaxDiagData Len=6; Maximum diagnostic data length (6-244) SlaveFamily=3; Slave typeModule=”Module1″0x23,0x13; Module 1, 4 bytes each for input and outputEndModuleModule=”Module2″0x27,0x17; Module 2, 8 bytes each for input and outputEndModule3. FunctionUsed for high-speed data transmission at the field level. The master station periodically reads input information from the slave and periodically sends output information to the slave. The bus cycle time must be shorter than the master (PLC) program cycle time. In addition to periodic user data transmission, PROFIBUS-DP also provides non-periodic communication required by intelligent devices for configuration, diagnostics, and alarm processing.① Transmission technology: RS-485 twisted pair, dual-line cable, or optical fiber. Baud rates range from 9.6K bit/s to 12M bit/s.② Bus access: Token passing between masters, master-slave transmission between master and slave. Supports single master or multi-master systems. The maximum number of stations (master-slave devices) on the bus is 126. The theoretical address range for Profibus is 0~127 (127 is the broadcast address). Up to 32 master stations can be used, with a total number of stations reaching 127 (multi-master).③ Communication: Point-to-point (user data transmission) or broadcast (control commands). Cyclic master-slave user data transmission and non-cyclic master-master data transmission.④ Operating modes: Run, Clear, Stop.⑤ Synchronization: Control commands allow input and output synchronization. Synchronization mode: output synchronization; locking mode: input synchronization.⑥ Functions: Cyclic user data transmission between DP master and DP slave. Dynamic activation and deactivation of each DP slave. Configuration checks of DP slaves. Powerful diagnostic functions with three levels of diagnostic information. Synchronization of inputs or outputs. Assigning addresses to DP slaves via the bus. Configuring DP master (DPM1) through the bus, with a maximum of 244 bytes for each DP slave’s input and output data.⑦ Reliability and protection mechanisms: All information transmission is monitored according to Hamming distance HD=4. DP slaves are equipped with watchdog timers. Access protection for DP slave inputs/outputs. User data transmission monitoring on DP master with variable timers.⑧ Device types: Class II DP master (DPM2) is programmable, configurable, and diagnostic equipment. Class I DP master (DPM1) is a central programmable controller, such as PLC, PC, etc. DP slaves are devices with binary or analog input/output, such as actuators, valves, etc.; they can also be intelligent slaves, meaning the slave supports programmability, generally another PLC master.
Rate Diagnostics
① Rate: In a distributed system with 32 stations, PROFIBUS-DP transmits 512 bit/s input and 512 bit/s output to all stations, requiring only 1 millisecond at 12Mbit/s.② Diagnostic functions: The extended PROFIBUS-DP diagnostics can quickly locate faults. Diagnostic information is transmitted on the bus and collected by the master station. Diagnostic information is divided into three levels:· Local station diagnostics: General operational status of the local device, such as high temperature, low pressure.· Module diagnostics: Faults in a specific I/O module of a station.· Through diagnostics: Faults in a single input/output bit.
System Composition
PROFIBUS-DP allows for the construction of single-master or multi-master systems. Up to 126 stations can be connected on the same bus. The system configuration description includes: number of stations, station addresses, input/output addresses, input/output data formats, diagnostic information formats, and the bus parameters used. Each PROFIBUS-DP system can include the following three different types of devices:① Class I DP master (DPM1): Class I DP master is the central controller that exchanges information with decentralized stations (such as DP slaves) within a predetermined cycle. Typical DPM1s include PLCs or PCs.② Class II DP master (DPM2): Class II DP master is a programmer, configuration device, or operator panel used during DP system configuration operations to achieve system operation and monitoring purposes.③ DP slave: DP slaves are peripheral devices (I/O devices, actuators, HMIs, valves, etc.) that collect and send input and output information.④ Single-master system: During the operation phase of the bus system, there is only one active master.⑤ Multi-master system: Multiple masters are connected to the bus. These masters and their respective slaves form independent subsystems. Each subsystem includes one DPM1, a specified number of slaves, and possibly DPM2 devices. Any master can read the input/output image of DP slaves, but only one DP master is allowed to write data to DP slaves.
System Behavior
System behavior mainly depends on the operational state of DPM1, which is controlled by local or bus configuration devices. There are three main states:· Stop: In this state, there is no data transmission between DPM1 and DP slaves.· Clear: In this state, DPM1 reads input information from DP slaves and keeps output information in a fail-safe state.· Run: In this state, DPM1 is in the data transmission phase, during cyclic data communication, DPM1 reads input information from DP stations and writes output information to slaves.① DPM1 periodically sends its local status to each relevant DP slave in a selective broadcast manner within a predetermined time interval.② If an error occurs during the data transmission phase of DPM1, DPM1 will immediately switch all relevant DP slaves’ output data to the clear state, and DP slaves will stop sending user data. After this, DPM1 will enter the clear state.
Cyclic Data
User data transmission between DPM1 and related DP slaves is automatically performed by DPM1 according to a predetermined recursive order. When configuring the bus system, the user specifies the relationship between DP slaves and DPM1, determining which DP slaves are included in the information exchange cycle and which are excluded.The data transfer between DPM1 and DP slaves occurs in three stages: parameter setting, configuration, and data exchange. In the parameter setting stage, each slave compares its actual configuration data with the configuration data received from DPM1. Only when the actual data matches the required configuration data will the DP slave enter the user data transmission phase. Therefore, the device type, data format, length, and input/output quantity must match the actual configuration.
Configuration Devices
In addition to master-slave functions, PROFIBUS-DP allows for data communication between masters, enabling configuration and diagnostic devices to configure the system via the bus.
Locking Mode
In addition to the cyclic user data transmission automatically performed by DPM1 devices, DP master devices can also send control commands simultaneously to individual DP slaves, a group of slaves, or all slaves. These commands are sent through selective broadcast commands. Using this function will activate the synchronization and locking modes of DP slaves for event control synchronization.After the master sends a synchronization command, the selected slaves enter synchronization mode. In this mode, the addressed slaves lock their output data in the current state. During subsequent user data transmission cycles, the slaves store the received output data, but their output state remains unchanged; the stored output data is only sent to peripheral devices when the next synchronization command is received. Users can exit synchronization mode through non-synchronization commands.The locking control command causes the addressed slaves to enter locking mode. Locking mode locks the input data of the slaves in the current state until the master sends the next locking command for updating. Users can exit locking mode through non-locking commands.
Protection Mechanisms
The DP master DPM1 uses data control timers to monitor data transmission from slaves. Each slave employs an independent control timer. If an error occurs during data transmission within the specified monitoring interval, the timer will time out. Once a timeout occurs, the user will be notified. If the automatic reaction function for errors is enabled, DPM1 will exit the operational state, set all associated slaves’ outputs to a fail-safe state, and enter the clear state.