CN103346943B - Data transmission method and system - Google Patents

Data transmission method and system Download PDF

Info

Publication number
CN103346943B
CN103346943B CN201310308529.5A CN201310308529A CN103346943B CN 103346943 B CN103346943 B CN 103346943B CN 201310308529 A CN201310308529 A CN 201310308529A CN 103346943 B CN103346943 B CN 103346943B
Authority
CN
China
Prior art keywords
profibus
data
slave station
module
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201310308529.5A
Other languages
Chinese (zh)
Other versions
CN103346943A (en
Inventor
武江涛
梁志超
曹亚猛
秦悦明
李小卿
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou Hollysys Automation Co Ltd
Hollysys Automation Technologies Ltd
Original Assignee
Hangzhou Hollysys Automation Co Ltd
Hollysys Automation Technologies Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou Hollysys Automation Co Ltd, Hollysys Automation Technologies Ltd filed Critical Hangzhou Hollysys Automation Co Ltd
Priority to CN201310308529.5A priority Critical patent/CN103346943B/en
Publication of CN103346943A publication Critical patent/CN103346943A/en
Application granted granted Critical
Publication of CN103346943B publication Critical patent/CN103346943B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Communication Control (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses a kind of data transmission method and system, the method is applied to data transmission system, this system includes the profibus-dp slave station including predetermined number inside main control module, modular converter and at least one single module and each single module, if predetermined number is N, namely N number of profibus-dp slave station is comprised in a single module, main control module carries out data transmission with N number of profibus-dp slave station respectively, it is at best able to transmission 244 × N byte, the transmission of 244 × N byte big data quantity therefore between main control module and single module, can be carried out. Present invention also offers a kind of data transmission method, data transmission system adopts data transmission method provided by the invention, thus realizing carrying out between single module and main control module the purpose of big data quantity transmission, and then meet and between main control module and single module, carry out the demand that big data quantity profibus-dp protocol data is mutual.

Description

Data transmission method and system
Technical field
The present invention relates to automation control area, be specifically related to a kind of data transmission method and system.
Background technology
Profibus be a kind of internationalization, open, do not rely on the standard for Fieldbus of equipment manufacturer, it is mainly used in the field bus technique of the monitoring of factory automation workshop level and scene equipment level data communication and control, is widely used in automated manufacturing, process industry automatization and the other field such as building, traffic power automatization. It is by profibus-dp(decentralizedperiphery), profibus-pa(processautomation), three compatible portion of profibus-fms (fieldbusmessagespecification) form.
Wherein profibus-dp is a kind of high speed low cost communication standard, it is used for the communication of apparatus control system distributing I/O, apparatus control system mainly includes main control module and single module, between main control module and single module, main use MS master-slave mode carries out communication, and main control module usually periodically carries out data interaction with single module. In actual applications, one main control module connects several single modules, and the principle that the agreement of profibus-dp is when carrying out data exchange is: within a cycle, main control module successively with single module 1, single module 2 ... carry out data interaction to last single module N, subsequently into next cycle continue carry out data interaction with each single module successively.
Single module comprises profibus-dp slave station, when main control module carries out data interaction according to profibus-dp agreement and single module, it is actually main control module and carries out data interaction with the profibus-dp slave station in single module, regulation according to profibus-dp agreement, when main control module and each profibus-dp slave station carry out a data interaction, can the maximum of transmitted data amount be 244 bytes, it mostly is what the foreign corporations such as Siemens provided due to existing single module, only one of which profibus-dp slave station in each of which single module, therefore when main control module and single module carry out a data interaction, the maximum of the data volume that can transmit is 244 bytes.
But continuous progressive along with the complicated change of on-the-spot applied environment and prior art, need to carry out the transmission of big data quantity between main control module and single module, the data volume of 244 bytes can not meet far away requirement, but it is limited to regulation and this body structure of single module of profibus-dp agreement, main control module is only capable of within a cycle and carries out the transmission of 244 bytes with single module, therefore main control module and single module need repeatedly to carry out data interaction in multiple cycles, this causes that the time realizing once data interaction needs completely between single module and main control module then can be very long, this transmission time having had a strong impact on data between main control module and single module and data subsequent use process.
Therefore independent research one single module now it is badly in need of, enable to carry out between single module and master control the transmission of big data quantity, profibus-dp consensus standard being met again, thus meeting, prior art carrying out between main control module and single module the demand that Volume data is mutual.
Summary of the invention
The invention provides a kind of data transmission method and system, after data transmission system uses this data transmission method, be capable of single module can and master control between carry out the purpose of transmission of big data quantity, thus meeting, prior art carries out between main control module and single module the demand that big data quantity profibus-dp protocol data is mutual.
To achieve these goals, the invention provides techniques below means:
A kind of data transmission method, it is applied to data transmission system, described data transmission system includes: main control module, the modular converter being connected with described main control module and at least one single module being connected with described modular converter, the profibus-dp slave station of predetermined number is included inside each single module, described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module, including:
At least one single module described is chosen a single module as target single module;
Internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtains the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station;
Predetermined number according to described target data, the data volume of described target data and described profibus-dp slave station, it is determined that the slave station data carried out data transmission with profibus-dp slave station each in described target single module;
Access data by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, adopt profibus-dp agreement to send to described target single module by described modular converter;
After the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, adopt profibus-dp agreement to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module.
A kind of data transmission method, it is applied to data transmission system, described data transmission system includes: main control module, the modular converter being connected with described main control module and at least one single module being connected with described modular converter, the profibus-dp slave station of predetermined number is included inside each single module, described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module, including:
After the described UART module of each profibus-dp slave station determines the baud rate that main control module sends described access data, lock described baud rate and receive access data, and after verification is correct, sends the described receiver module to this profibus-dp slave station;
Described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the described receiver module of each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then determine that this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data;
Described target slave data are stored in the memory module to described target profibus-dp slave station by the described control module in described target profibus-dp slave station;
Bus interactive interface module in described target profibus-dp slave station carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data feeds back to the UART module in described target profibus-dp slave station;
Described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, sending module feed back described reply data extremely described main control module;
Re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
A kind of data transmission system, including:
Main control module, for choosing a single module at least one single module described as target single module, internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtain the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station, according to described target data, the data volume of described target data and the predetermined number of described profibus-dp slave station, determine the slave station data carried out data transmission with each profibus-dp slave station in described target single module, data are accessed by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, profibus-dp agreement is adopted to send to described target single module by described modular converter, after the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, profibus-dp agreement is adopted to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module,
The modular converter being connected with described main control module;
At least one single module, the profibus-dp slave station of predetermined number is included inside each single module, described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module, at least one single module described, after determining, for the described UART module of each profibus-dp slave station, the baud rate that main control module sends described access data, lock described baud rate and receive access data, and at the correct rear described receiver module sent to this profibus-dp slave station of verification, described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the described receiver module of each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data, described target slave data are stored in the memory module to described target profibus-dp slave station by the described control module in described target profibus-dp slave station, bus interactive interface module in described target profibus-dp slave station carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data is fed back to the UART module in described target profibus-dp slave station, described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, described reply data extremely described main control module is fed back by sending module, re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
The invention discloses a kind of data transmission method, the method is applied to data transmission system, this system includes the profibus-dp slave station including predetermined number inside main control module, modular converter and at least one single module and each single module, if predetermined number is N.
When the present invention carries out data transmission between main control module and single module, it is sequentially carried out data transmission also according to profibus-dp agreement and profibus-dp slave station, from background technology, it is 244 bytes that one profibus-dp slave station and main control module carry out the maximum amount of data that a data interaction can transmit, but the present invention comprises in one single module N number of profibus-dp slave station, main control module carries out data transmission with N number of profibus-dp slave station respectively, it is at best able to transmission 244 × N byte, owing to N number of profibus-dp slave station broadly falls into single module, therefore the transmission of 244 × N byte big data quantity can be carried out between main control module and single module.
In the present invention, in the single module in data transmission system, the predetermined number N of profibus-dp slave station can set that, predetermined number N is more big, it is possible to the data volume of transmission is more big, thus realizing carrying out between single module and main control module the purpose of the transmission of big data quantity.
Because of the method that in prior art, main control module does not carry out data interaction with the single module comprising multiple profibus-dp slave station, therefore present invention also offers a kind of data transmission method, data transmission system adopts data transmission method provided by the invention, thus realizing carrying out between single module and main control module the purpose of the transmission of big data quantity, and then meet and between main control module and single module, carry out the demand that big data quantity profibus-dp protocol data is mutual.
Accompanying drawing explanation
In order to be illustrated more clearly that the embodiment of the present invention or technical scheme of the prior art, the accompanying drawing used required in embodiment or description of the prior art will be briefly described below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the premise not paying creative work, it is also possible to obtain other accompanying drawing according to these accompanying drawings.
Fig. 1 is the structural representation of data transmission system disclosed in the embodiment of the present invention;
Fig. 2 is the flow chart of the present count method for determination of amount of the profibus-dp slave station in data transmission system disclosed in the embodiment of the present invention in single module;
Fig. 3 is the flow chart of data transmission method disclosed in the embodiment of the present invention;
Fig. 4 is the flow chart of another data transmission method disclosed in the embodiment of the present invention;
Fig. 5 is the structural representation of memory module in data transmission system disclosed in the embodiment of the present invention;
Fig. 6 is the structural representation in RAM district in memory module disclosed in the embodiment of the present invention;
Fig. 7 is that in data transmission method disclosed in the embodiment of the present invention, target slave data store the flow chart to RAM district;
Fig. 8 is the structural representation of another data transmission system disclosed in the embodiment of the present invention;
Fig. 9 is the flow chart of another data transmission method disclosed in the embodiment of the present invention.
Detailed description of the invention
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only a part of embodiment of the present invention, rather than whole embodiments. Based on the embodiment in the present invention, the every other embodiment that those of ordinary skill in the art obtain under not making creative work premise, broadly fall into the scope of protection of the invention.
As it is shown in figure 1, the invention provides a kind of data transmission system, described data transmission system includes:
Main control module 100, the modular converter 200 being connected with described main control module 100 and at least one single module 300 being connected with described modular converter 200; In order to know the relation describing each single module and modular converter, the present embodiment is M, M in the quantity of Fig. 1 single module shown is natural number, and 1 < M < 127.
The internal profibus-dp slave station 400 including predetermined number of each single module 300, described profibus-dp slave station includes universal asynchronous receiving-transmitting transmitter (UniversalAsynchronousReceiver/Transmitter, UART) module 401, receiver module 402, sending module 403, controls module 404, memory module 405 and bus interactive interface module 406. In order to clearly show that profibus-dp slave station in FIG, in the present embodiment, predetermined number adopts N to represent, N is natural number and N > 1.
Wherein main control module for choosing a single module as target single module at least one single module described, internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtain the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station, according to described target data, the data volume of described target data and the predetermined number of described profibus-dp slave station, determine the slave station data carried out data transmission with each profibus-dp slave station in described target single module, data are accessed by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, profibus-dp agreement is adopted to send to described target single module by described modular converter, after the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, profibus-dp agreement is adopted to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module,
At least one single module, after determining, for the described UART module of each profibus-dp slave station, the baud rate that main control module sends described access data, lock described baud rate and receive access data, and at the correct rear described receiver module sent to this profibus-dp slave station of verification, described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the described receiver module of each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then determine that this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data, described target slave data are stored in the memory module to described target profibus-dp slave station by the described control module in described target profibus-dp slave station, bus interactive interface module in described target profibus-dp slave station carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data is fed back to the UART module in described target profibus-dp slave station, described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, described reply data extremely described main control module is fed back by sending module, re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
Below each ingredient of data transmission system is stated in detail, this system includes main control module 100, for choosing a single module at least one single module described as target single module, internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtain the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station, according to described target data, the data volume of described target data and the predetermined number of described profibus-dp slave station, determine the slave station data carried out data transmission with each profibus-dp slave station in described target single module, data are accessed by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, profibus-dp agreement is adopted to send to described target single module by described modular converter, after the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, profibus-dp agreement is adopted to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module, after single module structure change, the application program within main control module 100 also changes therewith, will main control module 100 be stated in detail in subsequent embodiment.
The modular converter 200 being connected by DP interface with main control module 100;
Modular converter 200 includes MAX485 electrical level transferring chip, send to single module for the differential signal that main control module 100 sends being converted to single-ended signal, or the single-ended signal that single module sends is converted to differential signal sends to main control module, because when main control module is to single module transmission access data, differential level transmission is adopted in order to strengthen anti-interference, single module in the present invention is only capable of receiving single-ended signal, so access data signals needed to be converted into single-ended signal before entering single module, in order to single module is able to receive that.
The invention discloses a kind of single module 300, single module of the prior art mostly is the profibus-dp slave station chip of standard, such as: the SPC3 of Siemens, the profibus-dp slave station chip internal of standard only has a profibus-dp slave station, the demand carrying out big data quantity transmission between main control module cannot be met, and the technology closing of the profibus-dp slave station chip internal of standard, other people cannot be carried out obtaining its internal technology.
Therefore the present inventor adopts field programmable gate array chip (FieldProgrammableGateArray, FPGA) mode of software program programming is adopted to develop a kind of single module 300 according to disclosed profibus-dp agreement, the internal profibus-dp slave station 400 including predetermined number of this single module 300, the size of predetermined number can need the data volume of transmission to determine according to main control module and single module, concrete, as in figure 2 it is shown, the determination process of predetermined number includes:
Step S101: the maximum amount of data that acquisition main control module and a single module carry out data transmission;
Main control module and single module periodically carry out data interaction, in each cycle, main control module and single module need to carry out the data interaction of certain data volume, do not need to carry out the data volume of data interaction not etc. each cycle, for making the target data in each cycle can both be transmitted within a cycle, the maximum amount of data therefore carrying out data interaction in choosing multiple cycle determines the predetermined number of profibus-dp slave station.
Step S102: the byte number of maximum amount of data and 244 bytes are divided by, obtain quotient and remainder;
According to profibus-dp agreement within a cycle, the data volume of transmission 244 bytes it is at best able between each profibus-dp slave station and main control module, the maximum amount of data obtained in above-mentioned steps and 244 bytes are obtained quotient and remainder as business, obtains the quantity of the profibus-dp slave station needed according to quotient and remainder.
Step S103: obtain the quantity of profibus-dp slave station according to quotient and remainder, including: if described remainder is zero, in single module, the numerical value of predetermined number is at least quotient, if described remainder is not zero, in single module, the numerical value of predetermined number is at least after quotient adds one and value;
Step S104: travel through each single module in described data transmission system by step S101-S103.
Above-mentioned steps gives the scope bottom line of profibus-dp slave station preset data amount in single module, in each module, the predetermined number of profibus-dp slave station maximum in the present embodiment is based on the resource of fpga chip and fixed, fpga chip resource is more big, it is possible to the quantity of the profibus-dp slave station of structure is more big.
If remainder is zero certainly, the predetermined number of profibus-dp slave station is equal to quotient, if remainder is not zero, the predetermined number of profibus-dp slave station is equal to quotient adds one and value, so meet most industry needs, neither waste resource, increase the burden of system, can meet again and be transmitted target data within a cycle.
Each single module of system is transmitted thus the predetermined number of the profibus-dp slave station obtained in each single module by above-mentioned steps ergodic data, so that engineer is according to predetermined number, in the single module that fpga chip builds, adopt the profibus-dp slave station that the mode of software programming obtains presetting. Between each slave station separate, and each profibus-dp slave station builds fully according to profibus-dp agreement, and the data transmission between main control module carries out fully according to profibus-dp agreement. Each profibus-dp slave station includes UART module 401, receiver module 402, sending module 403, controls module 404, memory module 405 and bus interactive interface module 406, annexation between modules is the connection in data, the module included in profibus-dp slave station can be described in detail by following embodiment, do not repeating at this.
The invention discloses a kind of data transmission system, this system includes the profibus-dp slave station including predetermined number inside main control module, modular converter and at least one single module and each single module, if predetermined number is N.
When the present invention carries out data transmission between main control module and single module, it is sequentially carried out data transmission also according to profibus-dp agreement and profibus-dp slave station, from background technology, it is 244 bytes that one profibus-dp slave station and main control module carry out the maximum amount of data that a data interaction can transmit, but the present invention comprises in one single module N number of profibus-dp slave station, main control module carries out data transmission with N number of profibus-dp slave station respectively, it is at best able to transmission 244 × N byte, owing to N number of profibus-dp slave station broadly falls into single module, therefore the transmission of 244 × N byte big data quantity can be carried out between main control module and single module, in the present invention, in the single module in data transmission system, the predetermined number N of profibus-dp slave station can set that, predetermined number N is more big, the data volume that can transmit is more big, thus realizing carrying out between single module and main control module the purpose of big data quantity profibus-dp protocol data transmission.
As it is shown on figure 3, embodiments provide a kind of data transmission method, it is applied to data transmission system, including:
Step S201: choose a single module at least one single module as target single module;
Data transmission system includes at least one single module and is up to 128, before performing this method, main control module needs to prestore the data volume of target data and the described target data carried out data transmission with each single module in internal memory, and the tributary address of the predetermined number of profibus-dp slave station and each profibus-dp slave station in described each single module.
The target data prestored and the data volume of target data are that engineer is fixed according to practical situation, engineer prepares main control module in advance needs multiple target datas of transmission and the data volume of multiple target data with each single module within multiple cycles, and the target data in multiple cycles and the data volume of target data is stored one to one to internal memory. Engineer's structure within the single module in data transmission system, obtain the predetermined number of profibus-dp slave station in each single module, and by external microprocessor, profibus-dp slave station in each single module is set tributary address, and the tributary address of profibus-dp slave station in each single module is stored one to one to the internal memory of main control module.
Step S202: obtain the content relevant with target single module, including: in internal memory, search the data volume of target data and the described target data carried out data transmission with described target single module, and obtain the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station;
In this period, according to the target single module chosen in above-mentioned steps, according to the content prestored in internal memory, search the quantity of profibus-dp slave station in the target data corresponding with target single module, the data volume of target data and described target single module, and the address of each slave station, in order to main control module carries out data interaction with each profibus-dp slave station in target single module.
Step S203: determine the slave station data that each profibus-dp slave station carries out data transmission with in target single module, predetermined number according to described target data, the data volume of described target data and described profibus-dp slave station, it is determined that the slave station data carried out data transmission with profibus-dp slave station each in described target single module;
According to determination process about predetermined number in step S101-S103, maximum amount of data that the predetermined number of profibus-dp slave station is based in multiple cycle main control module to carry out data transmission with single module and fixed, the data volume carried out data transmission within this cycle is not necessarily maximum amount of data, it is therefore desirable to calculate the slave station data carried out data transmission between main control module and each profibus-dp slave station.
If the predetermined number of profibus-dp slave station is A in target single module, the data volume of target data is B byte in this period, B byte and 244 bytes are divided by, obtain quotient C and remainder D, if remainder D is zero, then target data is divided into C part slave station data, every part of 244 bytes, if remainder D is not zero, then target data is divided into (C+1) part slave station data, every part of 244 bytes of front C part, last a D byte, by corresponding with A pofibus-dp slave station in target single module successively to C part slave station data or (C+1) part slave station data, if predetermined number A more than C or predetermined number A more than (C+1), the slave station data that then remaining pofibus-dp slave station is corresponding are empty. main control module need not carry out data interaction with it.
Step S204: send to target single module and access data;
Step S205: judge whether to be sent completely after receiving reply data, then obtaining next if not and accesses data, going to step S204, if then exiting.
Concrete includes: access data by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, adopts profibus-dp agreement to send to described target single module by described modular converter; After the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, adopt profibus-dp agreement to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module.
Wherein, accessing data is according to step S202 each tributary address obtained and the slave station data composition corresponding with each tributary address obtained in step S203, concrete, by the first tributary address and the first slave station data composition first access data corresponding with the first tributary address, by the second tributary address and corresponding with the second tributary address second slave station data composition the second access data, the like until having set up the access data of each slave station. Data instance is accessed with first, after first access data are converted to single-ended signal by modular converter, send to a profibus-dp slave station corresponding with the first tributary address, bus interactive interface module in oneth profibus-dp slave station accesses after data carry out data interaction with extraneous Man Machine Interface according to first and forms the first reply data, and the first reply data is fed back to main control module, concrete step will be described in following embodiment, does not repeat them here.
After main control module receives the first reply data that the first slave station sends, prove that data interaction between main control module and the first slave station completes in this period, below by with the second slave station carry out data interaction, first obtain second corresponding with the second tributary address according to the second tributary address of the second slave station and access data, and the second access converted module of data is sent to the 2nd profibus-dp slave station, then carried out data interaction by the bus interactive interface module of the 2nd profibus-dp slave station with extraneous Man Machine Interface and obtain the second reply data, and the second reply data is fed back to main control module, master control sends the 3rd access data to the 3rd profibus-dp slave station after receiving again, the like until traversal target single module in all profibus-dp slave stations, when being transferred to last profibus-dp slave station, when slave station data are empty, main control module can skip this slave station, continue to carry out data interaction with next slave station.
The present embodiment describes the process of the main execution in data transmission system within main control module in detail, transmit at notebook data and the basis of system sends, by main control module circulation, the process accessing data to the slave station in target single module, the processing procedure of access data that target single module for main control module send is described more fully below.
As shown in Figure 4, the invention provides a kind of data transmission method, be applied to data transmission system, including:
Step 301: each profibus-dp slave station receives and accesses data, and send to receiver module, concrete: after the described UART module of each profibus-dp slave station determines the baud rate that main control module sends described access data, lock described baud rate and receive access data, and after verification is correct, sends the receiver module to this profibus-dp slave station;
After main control module sends access data to target single module, the UART module of stating of all slave stations in target single module listens to baud rate, concrete: each UART module 12M, 6M, 3M, 1.5M, 500K, 187.5K, 45.45K, 19200 and 9600 several baud rates (unit is bps) contrast with the baud rate accessing data successively, general detecting baud rate starts to successively decrease successively to move in circles from 12M, until locking baud rate, be initially because the time required when high bit rate is detected is shorter from high bit rate, so detecting speed is very fast. After determining baud rate, lock baud rate receive access data, then the access data received are carried out even parity check, it may be judged whether correct, if correct words, send the receiver module to this profibus-dp slave station by accessing data.
Step 302: determine target profibus-dp slave station, and obtain target access data, described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the receiver module of concrete each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data,
The tributary address of all the other profibus-dp slave stations is inconsistent with target slave address, stops resolving, wait the arrival next time accessing data, if the tributary address of all profibus-dp slave stations is all inconsistent with target slave address, then prove that this target slave address is not the profibus-dp slave station in target single module, then jump to next single module and carry out the judgement of target slave address.
Receiver module in each slave station resolves accessing data according to profibus-dp agreement, first obtain accessing the target slave address in data, target slave address is contrasted by each profibus-dp slave station, judge that whether target slave address is consistent with this profibus-dp tributary address, if unanimously this profibus-dp slave station is target profibus-dp slave station, needs and main control module carry out the profibus-dp slave station of data interaction, and target profibus-dp slave station continues that access data are carried out data parsing and obtains target slave data.
Step 303: target profibus-dp slave station store access data, concrete, described target slave data are stored in the memory module to described target profibus-dp slave station by the control module in described target profibus-dp slave station;
As it is shown in figure 5, the memory module 405 in each profibus-dp slave station 400 includes:
Register section 501 and RAM district 502;
RAM district includes: a RAM district 5023 of RAM district the 5022, the 3rd of RAM district the 5021, the 2nd.
RAM district is also divided into reception area and sending area, and reception area is issued to the access data of single module for storing main control module, and sending area feeds back to the reply data of main control module for storing single module.
As shown in Figure 6, for the construction embodiment in RAM district.
The part that RAM district stores for data with regard to FPGA inside, 2 profibus-dp slave stations are comprised in single module, the RAM of each slave station divides into sending area and reception area, it is divided into 3 regions according to address, respective initial address is 0x0000 respectively, 0x1000 and 0x2000, each profibus-dp slave station has 3 RAM districts, oneth RAM district, 2nd RAM district, the address in the 3rd RAM district is all the enterprising line displacement in basis in base address, because each profibus-dp slave station transmits at most 244 bytes, therefore the data field being defined as each RAM district is 256 bytes and FF.
So the address in 3 RAM districts of the reception area of a profibus-dp slave station is RAM district a: 0x0000-0x00FF respectively, 2nd RAM district: 0x1000-0x10FF, 3rd RAM district: 0x2000-0x20FF, the address, sending area of the oneth profibus-dp slave station is divided respectively: RAM district a: 0x0100-0x01FF, 2nd RAM district: 0x1100-0x11FF, the 3rd RAM district: 0x2100-0x21FF; The address in 3 RAM districts of the reception area of the 2nd profibus-dp slave station is RAM district a: 0x0200-0x02FF respectively, 2nd RAM district: 0x1200-0x12FF, 3rd RAM district: 0x2200-0x22FF, the address, sending area of the oneth profibus-dp slave station is divided respectively: RAM district a: 0x0300-0x03FF, 2nd RAM district: 0x1300-0x13FF, the 3rd RAM district: 0x2300-0x23FF.
Memory area in the present invention is divided into register section and RAM district, register section mainly stores the parameters in slave station data, inputoutput data is deposited in RAM district, profibus-dp slave station data are classified, facilitate the follow-up use to the inputoutput data in slave station data, additionally, in the present invention, main control module needs to send and accesses data to the memory module in single module, single module needs to carry out data interaction with extraneous Man Machine Interface, then reply data is fed back to main control module by memory module, because both operations are asynchronous, therefore RAM is divided into sending area and reception area and is divided into three parts, to avoid colliding during the operation that the RAM district of same slave station carries out by single module and main control module, and this RAM district disclosure satisfy that and up-to-date data are transferred to use end as soon as possible, description in the step that concrete use procedure is as described below.
As it is shown in fig. 7, described target slave data are stored in the memory module to described target profibus-dp slave station by the control module in described target profibus-dp slave station, concrete includes:
Step S401: judge the data type of target slave data, concrete: the control module in target profibus-dp slave station judges in target slave data the type of byte data in data field, if parameter type then jumps to S402, if inputoutput data type then jumps to S403;
Slave station data are divided into the parts such as packet header, data field and check bit, the content for the data field part in slave station data that this step is primarily upon.
Step S402: if byte data is then stored to register section by parameter type;
Step S403: if inputoutput data type then byte data is stored to in a RAM district;
Step S404: judge whether to finish receiving, if then jumping to step S405, if it is not, then enter next byte data to jump to step S401.
Step S405: generate and receive successfully target knowledge signal, and the byte data in a RAM district is transferred to the 2nd RAM district.
By above-mentioned steps, target slave data are stored completely to memory module, generate and receive successfully target knowledge signal, and the byte data in a RAM district is transferred to the 2nd RAM district, and the first address being converted to Direct Transform RAM district in RAM district of the present invention, convenient and swift.
Step 304: target profibus-dp slave station obtains reply data, concrete: bus interactive interface module carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data feeds back to described UART module;
Bus interactive interface module needs to obtain the target slave data in RAM district, as it is shown in fig. 7, after meeting above-mentioned steps S405, the step obtaining data includes:
Step S406: send the id signal reading RAM district, concrete: the bus interactive interface module in target profibus-dp slave station sends the id signal reading RAM district to described memory module;
The byte data in just the 2nd RAM district of step S407:RAM district sends to the 3rd RAM district, concrete: the byte data in the 2nd RAM district, according to the id signal reading RAM district, is sent and calls for bus interface module to the 3rd RAM district by the memory module in target profibus-dp slave station.
Bus interactive interface module obtains slave station data from the 3rd RAM district, and slave station data are carried out data interaction with extraneous man-machine interface, obtain reply data, and reply data is sent to the 3rd RAM district, produce after being sent completely to be sent completely id signal, then the reply data in the 3rd RAM district is sent to the 2nd RAM district, when target single module needs to feed back reply data to main control module, reply data in 2nd RAM district is sent to a RAM district, and is sent to UART module by a RAM district.
Reply data is fed back to main control module by step S305: target profibus-dp slave station, concrete: described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, sending module feed back described reply data extremely described main control module;
Step S306: re-execute step S301-S305, until each profibus-dp slave station traveled through in described target single module.
Above-mentioned steps S301-S305 is the data interaction in main control module and target single module between a target profibus-dp slave station, main control module is by all slave stations in above-mentioned steps traversal target single module, the slave station data that wherein if slave station is corresponding are empty, then directly skip this slave station, the process that master control carries out data interaction with other profibus-dp slave stations in target single module is consistent with above-mentioned steps, does not repeat them here.
The present embodiment is the detailed content that target single module carries out data transmission in data transmission system, and this embodiment describes the process that target single module carries out data transmission with main control module in detail.
Foregoing providing a kind of data transmission system, this system includes main control module, modular converter and at least one single module, and includes the profibus-dp slave station of predetermined number inside each single module, if predetermined number is N. In the present invention, in the single module in data transmission system, the predetermined number N of profibus-dp slave station can set that, predetermined number N is more big, it is possible to the data volume of transmission is more big, thus realizing carrying out between single module and main control module the purpose of the transmission of big data quantity. A kind of data transmission method is present invention also offers for this, including the execution process within the internal execution process of main control module and single module, data transmission system basis adopts data transmission method provided by the invention, thus realizing carrying out between single module and main control module the purpose of the transmission of big data quantity, and then meet and between main control module and single module, carry out the demand that Volume data is mutual.
As shown in Figure 8, the embodiment of the present invention provides again a kind of data transmission system to include: main control module 100, the modular converter 200 being connected with described main control module and at least one single module 600 being connected with described modular converter, includes UART module 601, receiver module 602, sending module 603, control module 604, the profibus-dp memory module 605 of predetermined number and bus interactive interface module 606 inside each single module 600. The wherein predetermined number of the profibus-dp slave station in single module, the program write by engineer when being built single module by PFGA is determined, in each single module, the size of preset data amount is determined by above-mentioned steps S101-S103.
As shown in Figure 8, the one end also including in each slave station sharing is connected with UART module, the AB net redundancy handover module 607 that the other end is connected with receiver module, in single module, each slave station is AB net dual redundant pattern, availability is strong, reception pin in single module has two, the two pin receives the same signal of main control module transmission or the signal (identical signal) of redundant link simultaneously, then two UART modules are had all to carry out this baud rate receiving signal detecting and even parity check in single module, then pass through AB net redundant module to select, first acquiescence selects A net, when A net goes wrong, AB net redundant module controls data receiver and is switched to B net, proceed data transmit-receive, so can increase the availability of link. when after A/B net all faults, just think link failure. therefore AB net redundancy handover module carries out redundancy backup switching with regard to two receiving port signals of major control.
As shown in Figure 8, each profibus-dp slave station also includes the watchdog reset functional device 608 shared, for being monitored in the process of data receiver, it is ensured that when abnormal conditions, profibus-dp slave station can jump back to original state in time, from newly received data.
Owing to main control module 100 each moment can only carry out data interaction with a slave station in single module, similar time-sharing multiplex between each profibus-dp slave station and main control module, in order to save the application space within FPGA, notebook data transmission system is by the UART module of each profibus-dp slave station, receiver module, sending module, control module, AB net redundancy handover module, watchdog reset functional device and bus interactive interface module share, memory module is equivalent to independent profibus-dp slave station, each profibus-dp slave station has memory module individually corresponding with it.
Because the present invention adopts fpga chip to build single module, limited storage space within FPGA, therefore modules is shared by the system of the present embodiment, the space of PGGA can be saved, to reserve resource being supplied to other design requirement, original profibus-dp chip functions is single, single module provided by the invention is possible not only to realize the function of profibus-dp slave station, the basis of single module carries out the transmission of big quantity, but also it being capable of other design requirement and logical design, integrated level height is powerful.
Under this system is supported, as it is shown in figure 9, the present invention provides another data transmission method, including:
Step S501: in advance main control module and each single module are prepared work.
In above-mentioned data transmission system, profibus-dp slave station quantity in each single module it has been determined that, but profibus-dp slave station does not have corresponding identification information in each single module, therefore adopt tributary address as the identification information of each profibus-dp slave station, subsequent process to process, for target single module, engineer adopts the tributary address of each profibus-dp slave station in ppu target setting single module, so that each slave station has independent tributary address, and the tributary address of each profibus-dp slave station is stored in the internal memory of target single module, other single modules are also carried out same operation by engineer.
Engineer, according to by the predetermined number of profibus-dp slave station and the tributary address of each profibus-dp slave station in each single module in each single module, stores to the internal memory of main control module in units of single module. It addition, the data volume that engineer also needs to target data and target data main control module and each single module carried out data transmission stores to the internal memory of main control module in units of single module.
Step S502: choose a single module as target single module;
It is that main control module is according to single module order in real data are transmitted, carry out data transmission with single module successively, in order to represent the arbitrariness of the single module in the arbitrariness of the present invention, using a single module in each single module as target single module, with target single module as an example, the data transmission procedure between all the other single module with master controls is similar consistent.
Step S503: main control module obtains desired data in internal memory;
Internal memory is searched the data volume of target data and the target data carried out data transmission with target single module, and obtains the predetermined number of profibus-dp slave station in target single module and the tributary address of each profibus-dp slave station;
Step S504: main control module determines the slave station data carried out data transmission with each profibus-dp slave station;
The main control module predetermined number according to target data, the data volume of target data and profibus-dp slave station, it is determined that the slave station data carried out data transmission with profibus-dp slave station each in described target single module;
Step S505: main control module sends to target single module and accesses data,
The access data comprising a tributary address and the slave station data corresponding with this tributary address are sent to target single module by main control module;
Step 506: the UART module in target single module locks baud rate and receives access data;
After UART module in target single module determines that main control module sends the baud rate accessing data, lock described baud rate and receive access data, and after verification is correct, sends extremely described receiver module;
Step 507: the receiver module in target single module resolves and accesses data and obtain target slave data.
According to profibus-dp agreement, described access data are carried out protocol analysis and obtain the target slave address in described access data, if described target slave address is the profibus-dp slave station in target single module, then continues that described access data are carried out protocol analysis according to profibus-dp agreement and obtain target slave data;
Step S508: target slave data are stored to memory module by the control module in target single module;
Step S509: the bus interactive interface module in target single module obtains reply data, and feeds back to UART module;
Bus interactive interface module carries out data interaction according to target slave data with extraneous man-machine interface and obtains reply data, and reply data feeds back to UART module;
Step S510: the UART module feedback reply data in target single module is to main control module;
Reply data is sent to sending module by UART module, by sending module feedback reply data to main control module;
Step S511: after main control module receives the reply data of target single module feedback, goes to next tributary address, jumps to step S505.
Re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
The present invention discloses again a kind of data transmission system, this system includes main control module, modular converter and at least one single module, the UART module 601 of each profibus-dp slave station in single module in the present invention, receiver module 602, sending module 603, control module 604, AB net redundancy handover module, watchdog reset functional device and bus interactive interface module 606 share, memory module is equivalent to independent profibus-dp slave station, single module provided by the invention is possible not only to realize the function of profibus-dp slave station, the basis of single module carries out the transmission of big quantity, but also it is capable of other design requirement and logical design, integrated level height is powerful.
The present invention comprises in one single module N number of profibus-dp slave station, main control module carries out data transmission with N number of profibus-dp slave station respectively, it is at best able to transmission 244 × N byte, owing to N number of profibus-dp slave station broadly falls into single module, the transmission of 244 × N byte big data quantity therefore between main control module and single module, can be carried out. In the present invention, in the single module in data transmission system, the predetermined number N of profibus-dp slave station can set that, predetermined number N is more big, the data volume that can transmit is more big, thus realizing carrying out between single module and main control module the purpose of big data quantity profibus-dp protocol data transmission.
A kind of data transmission method is invention further provides for this, data transmission system adopts data transmission method provided by the invention, thus realizing carrying out between single module and main control module the purpose of the transmission of big data quantity, and then meet and between main control module and single module, carry out the demand that big data quantity profibus-dp protocol data is mutual.
If the function described in the present embodiment method is using the form realization of SFU software functional unit and as independent production marketing or use, it is possible to be stored in a computing equipment read/write memory medium. Based on such understanding, part or the part of this technical scheme that prior art is contributed by the embodiment of the present invention can embody with the form of software product, this software product is stored in a storage medium, including some instructions with so that a computing equipment (can be personal computer, server, mobile computing device or the network equipment etc.) perform all or part of step of method described in each embodiment of the present invention. And aforesaid storage medium includes: the various media that can store program code such as USB flash disk, portable hard drive, read only memory (ROM, Read-OnlyMemory), random access memory (RAM, RandomAccessMemory), magnetic disc or CDs.
In this specification, each embodiment adopts the mode gone forward one by one to describe, and what each embodiment stressed is the difference with other embodiments, between each embodiment same or similar part mutually referring to.
Described above to the disclosed embodiments, makes professional and technical personnel in the field be capable of or uses the present invention. The multiple amendment of these embodiments be will be apparent from for those skilled in the art, and generic principles defined herein can without departing from the spirit or scope of the present invention, realize in other embodiments. Therefore, the present invention is not intended to be limited to the embodiments shown herein, and is to fit to the widest scope consistent with principles disclosed herein and features of novelty.

Claims (10)

1. a data transmission method, it is characterized in that, it is applied to data transmission system, described data transmission system includes: main control module, the modular converter being connected with described main control module and at least one single module being connected with described modular converter, the profibus-dp slave station of predetermined number is included inside each single module, wherein, described profibus-dp slave station adopts software programming mode to realize; Described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module; Described method includes:
At least one single module described is chosen a single module as target single module;
Internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtains the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station;
Predetermined number according to described target data, the data volume of described target data and described profibus-dp slave station, it is determined that the slave station data carried out data transmission with profibus-dp slave station each in described target single module;
Access data by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, adopt profibus-dp agreement to send to described target single module by described modular converter;
After the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, adopt profibus-dp agreement to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module.
2. the method for claim 1, it is characterised in that include the determination process of predetermined number in the profibus-dp slave station of predetermined number inside described each single module and include:
Obtain described main control module and maximum amount of data that a single module carries out data transmission;
The byte number of described maximum amount of data and 244 bytes are divided by, obtain quotient and remainder;
If described remainder is zero, in single module, the numerical value of predetermined number is at least quotient, if described remainder is not zero, in single module, the numerical value of predetermined number is at least after quotient adds one and value;
The each single module in described data transmission system is traveled through by above-mentioned steps.
3. the method for claim 1, it is characterised in that also include:
Prestore the data volume of target data that described main control module and described each single module carry out data transmission and described target data, the tributary address of the predetermined number of profibus-dp slave station and each profibus-dp slave station in described each single module.
4. a data transmission method, it is characterized in that, it is applied to data transmission system, described data transmission system includes: main control module, the modular converter being connected with described main control module and at least one single module being connected with described modular converter, the profibus-dp slave station of predetermined number is included inside each single module, wherein, described profibus-dp slave station adopts software programming mode to realize; Described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module; Described method includes:
After the described UART module of each profibus-dp slave station determines that main control module sends the baud rate accessing data, lock described baud rate and receive access data, and after verification is correct, sends the described receiver module to this profibus-dp slave station;
Described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the described receiver module of each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then determine that this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data;
Described target slave data are stored in the memory module to described target profibus-dp slave station by the described control module in described target profibus-dp slave station;
Bus interactive interface module in described target profibus-dp slave station carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data feeds back to the UART module in described target profibus-dp slave station;
Described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, sending module feed back described reply data extremely described main control module;
Re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
5. method as claimed in claim 4, it is characterised in that described memory module includes:
Register section and RAM district;
Described RAM district includes: a RAM district, the 2nd RAM district, the 3rd RAM district.
6. method as claimed in claim 5, it is characterised in that described target slave data are stored in the memory module to described target profibus-dp slave station and include by the described control module in described target profibus-dp slave station:
Control module in described target profibus-dp slave station judges in described target slave data the type of each byte data in data field;
If byte data is then stored the register section to described target profibus-dp slave station by parameter type;
If inputoutput data type then stores in the RAM district to described target profibus-dp slave station;
Receive successful id signal by generating after the memory module that target slave data are stored to described target profibus-dp slave station by above-mentioned steps completely, and the byte data in a RAM district is transferred to the 2nd RAM district.
7. method as claimed in claim 6, it is characterised in that when the bus interactive interface module in described target profibus-dp slave station carries out including when data interaction obtains reply data according to described target slave data and extraneous man-machine interface:
Bus interactive interface module in described target profibus-dp slave station sends the id signal reading RAM district to the memory module in described target profibus-dp slave station;
The byte data in the 2nd RAM district, according to the id signal reading RAM district, is sent and calls for bus interface module to the 3rd RAM district by the memory module in described target profibus-dp slave station.
8. method as claimed in claim 4, it is characterised in that the profibus-dp slave station of each single module internal preset quantity is AB net redundant mode.
9. method as claimed in claim 4, it is characterised in that the profibus-dp slave station of each single module internal preset quantity shares UART module, receiver module, sending module, control module and bus interactive interface module.
10. a data transmission system, it is characterised in that including:
Main control module, for choosing a single module at least one single module as target single module, internal memory is searched the data volume of target data and the described target data carried out data transmission with described target single module, and obtain the predetermined number of profibus-dp slave station in described target single module and the tributary address of each profibus-dp slave station, according to described target data, the data volume of described target data and the predetermined number of described profibus-dp slave station, determine the slave station data carried out data transmission with each profibus-dp slave station in described target single module, data are accessed by comprise the first tributary address and the first slave station data corresponding with described first tributary address first, profibus-dp agreement is adopted to send to described target single module by modular converter, after the first reply data receiving described target single module feedback, next comprising next tributary address and next the slave station data corresponding with next tributary address described is accessed data, profibus-dp agreement is adopted to send to described target single module by described modular converter, the like until each profibus-dp slave station of traveling through in described target single module,
The modular converter being connected with described main control module;
At least one single module, includes the profibus-dp slave station of predetermined number inside each single module, wherein, described profibus-dp slave station adopts software programming mode to realize, described profibus-dp slave station includes UART module, receiver module, sending module, control module, memory module and bus interactive interface module, at least one single module described, after determining, for the described UART module of each profibus-dp slave station, the baud rate that main control module sends described access data, lock described baud rate and receive access data, and at the correct rear described receiver module sent to this profibus-dp slave station of verification, described access data are carried out protocol analysis according to profibus-dp agreement and obtain the target slave address in described access data by the described receiver module of each profibus-dp slave station, if the tributary address of a profibus-dp slave station is consistent with described target slave address, then this profibus-dp slave station is target profibus-dp slave station, according to profibus-dp agreement, described target profibus-dp slave station continues that described access data are carried out protocol analysis and obtains target slave data, described target slave data are stored in the memory module to described target profibus-dp slave station by the described control module in described target profibus-dp slave station, bus interactive interface module in described target profibus-dp slave station carries out data interaction according to described target slave data with extraneous man-machine interface and obtains reply data, and described reply data is fed back to the UART module in described target profibus-dp slave station, described reply data is sent the sending module to described target profibus-dp slave station by the UART module in described target profibus-dp slave station, described reply data extremely described main control module is fed back by sending module, re-execute above-mentioned steps, until each profibus-dp slave station traveled through in described target single module.
CN201310308529.5A 2013-07-18 2013-07-18 Data transmission method and system Active CN103346943B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310308529.5A CN103346943B (en) 2013-07-18 2013-07-18 Data transmission method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310308529.5A CN103346943B (en) 2013-07-18 2013-07-18 Data transmission method and system

Publications (2)

Publication Number Publication Date
CN103346943A CN103346943A (en) 2013-10-09
CN103346943B true CN103346943B (en) 2016-06-15

Family

ID=49281719

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310308529.5A Active CN103346943B (en) 2013-07-18 2013-07-18 Data transmission method and system

Country Status (1)

Country Link
CN (1) CN103346943B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105259853A (en) * 2015-11-09 2016-01-20 无锡华东电站自动化仪表厂 A redundant on-site bus I/O control device
CN110687854B (en) * 2019-11-05 2021-07-30 杭州和利时自动化有限公司 PA bus controller and PA bus control system
CN110941179B (en) * 2019-12-09 2023-03-31 杭州和利时自动化有限公司 Undisturbed downloading method, device and equipment and readable storage medium
CN111464419B (en) * 2020-04-13 2021-08-27 中国人民解放军国防科技大学 Data transmission control method based on bus network communication

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101221438A (en) * 2008-01-11 2008-07-16 四川航空工业川西机器厂 Electrical control workstation of macrotype isostatic pressing machine
CN101454731A (en) * 2006-06-01 2009-06-10 索尤若驱动有限及两合公司 Addressing device and method, and converter
CN201673398U (en) * 2010-05-14 2010-12-15 盛云科技有限公司 On site bus cluster curing barn centralized control system
CN202362658U (en) * 2011-11-28 2012-08-01 苏州普思自动化科技有限公司 High-speed field bus control system based on optical fiber

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101454731A (en) * 2006-06-01 2009-06-10 索尤若驱动有限及两合公司 Addressing device and method, and converter
CN101221438A (en) * 2008-01-11 2008-07-16 四川航空工业川西机器厂 Electrical control workstation of macrotype isostatic pressing machine
CN201673398U (en) * 2010-05-14 2010-12-15 盛云科技有限公司 On site bus cluster curing barn centralized control system
CN202362658U (en) * 2011-11-28 2012-08-01 苏州普思自动化科技有限公司 High-speed field bus control system based on optical fiber

Also Published As

Publication number Publication date
CN103346943A (en) 2013-10-09

Similar Documents

Publication Publication Date Title
CN109218352B (en) Consensus confirmation method and device for transaction information in blockchain network
CN103346943B (en) Data transmission method and system
CN101374093B (en) Communication interface of locale bus and real time transmission method for communication data
CN100524122C (en) Bus controller for numerical control system of full digital ring bus
CN201957057U (en) Distributed remote I/O (input/output) unit
CN100504688C (en) Private chip for implementing bus controller function in ring bus numerical control system
CN105224362A (en) Host computer carries out the method and system of program upgrade to slave computer
CN103279371A (en) Distributed control system multi-slave-computer program online synchronization upgrading method
CN101145052B (en) Real-time information interactive system between apparatuses and method
US9709963B2 (en) Control device for controlling safety-critical processes in an automated plant and method for parameterizing the control device
CN101013315A (en) General numerical control system based on full digital ring bus
CN106878131B (en) PROFIBUS coupler and data transmission method of PROFIBUS
CN104767665A (en) Ring communication network master station redundancy method, device and system
US8793417B2 (en) Integration of field devices in a distributed system
CN117076344A (en) Data sharing method, device and system and readable storage medium
JP5792866B2 (en) Profibus DP master device
US10268611B2 (en) Input/output (I/O) binding with automatic international electromechanical commission (IEC) address generation in remote terminal unit (RTU) configuration
CN101013314A (en) Integrated numerical control system based on full digital ring bus
JP5285461B2 (en) Wireless network structure
CN200997073Y (en) Universal digital-controlled system based on digital ring bus
CN105511815B (en) A kind of PLC based on segment table can operating file storing and resolving method and storage system
CN204463106U (en) UM-BUS bus run Failure Detection Controller
US8554966B2 (en) Method for data exchange
CN1798113A (en) Profibus bus - bridge of Ethernet network
CN112764385A (en) System and method for realizing small PLC bus

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant