[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN113890887A - Data forwarding method - Google Patents

Data forwarding method Download PDF

Info

Publication number
CN113890887A
CN113890887A CN202111130825.1A CN202111130825A CN113890887A CN 113890887 A CN113890887 A CN 113890887A CN 202111130825 A CN202111130825 A CN 202111130825A CN 113890887 A CN113890887 A CN 113890887A
Authority
CN
China
Prior art keywords
data
terminal
thread
forwarding
cache
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.)
Pending
Application number
CN202111130825.1A
Other languages
Chinese (zh)
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.)
Suzhou Zhonglian Sports Technology Co ltd
Original Assignee
Suzhou Zhonglian Sports Technology Co 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 Suzhou Zhonglian Sports Technology Co ltd filed Critical Suzhou Zhonglian Sports Technology Co ltd
Priority to CN202111130825.1A priority Critical patent/CN113890887A/en
Publication of CN113890887A publication Critical patent/CN113890887A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5016Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Programmable Controllers (AREA)

Abstract

The invention relates to the technical field of H04L, in particular to a data forwarding method. The invention provides a data forwarding method, which comprises the following steps: s1, acquiring data in a programmable logic controller through an acquisition thread and sending the data to an industrial personal computer; s2, storing the obtained data through different cache regions in the industrial personal computer; and S3, transmitting the data acquired from the cache region to the terminal through a transmission thread through network transmission. The method can continuously read the data from the programmable logic controller to the memory through the acquisition thread, and copy the data to the plurality of cache regions, then create the plurality of threads, and respectively forward the data in the cache regions to each terminal, thereby avoiding frequent io operation in a single thread and improving the data throughput of the system.

Description

Data forwarding method
Technical Field
The invention relates to the technical field of H04L, in particular to a data forwarding method.
Background
Chinese patent with patent application number CN201710941310.7 discloses a data forwarding method and device, which solves the problem of inconvenience and insecurity in communication, but does not disclose the problem of increasing the speed of sending data to different terminals.
In the traditional software system used at present, the io processing efficiency is always the bottleneck of the system, particularly, collected data needs to be forwarded to a plurality of terminals, and finally, data received by a certain terminal is too long in delay, and received sampling data are discontinuous, so that drawn curves are discontinuous, and the use experience of a user is influenced.
Disclosure of Invention
In order to solve the above problem, the present invention provides a data forwarding method, comprising the steps of:
s1, acquiring data in a programmable logic controller through an acquisition thread and sending the data to an industrial personal computer;
s2, storing the obtained data through different cache regions in the industrial personal computer;
and S3, transmitting the data acquired from the cache region to the terminal through a transmission thread through network transmission.
Preferably, the data is read out from the programmable logic controller to the memory by the acquisition thread and is copied to the plurality of buffer areas.
Preferably, the data obtained in the buffer area is forwarded to each terminal by creating a plurality of transmission threads.
The data are continuously read from the programmable logic controller to be stored in the memory through the acquisition thread and are copied to the plurality of cache regions, then the plurality of threads are established, the data in the cache regions are respectively forwarded to each terminal, more data are supported to be sent, the frequent io operation in a single thread is avoided, and the data throughput of the system is improved.
Preferably, the cache area in S2 includes a PC forwarding cache area, a tablet forwarding cache area, and a cloud forwarding cache area.
Preferably, the plurality of transmission threads in S3 include a PC forwarding thread, a tablet forwarding thread, and a cloud forwarding thread.
Preferably, the terminal in S3 includes a PC terminal, a tablet terminal, a mobile phone terminal, and a cloud terminal.
Preferably, the cloud is a cloud server.
Preferably, the acquiring data in the programmable logic controller is acquiring exercise training data generated by an exercise machine controlled by a servo motor.
Preferably, the obtained exercise training data is viewed in the terminal.
Preferably, the obtained exercise training data are checked in a PC (personal computer) end system, a tablet end APP (application) and a mobile phone end APP.
Preferably, the creating of the plurality of transfer threads realizes the task of data transfer to be distributed to multiple threads for execution.
Advantageous effects
The method can continuously read the data from the programmable logic controller to the memory through the acquisition thread, and copy the data to the plurality of cache regions, then create the plurality of threads, respectively forward the data in the cache regions to each terminal, support sending more data, avoid frequently performing io operation in a single thread, and improve the data throughput of the system.
The method can greatly improve the data throughput of the system, and disperse the time-consuming io operation into multiple threads for execution, so that the probability of communication delay is greatly reduced.
The method can support to send more data, and avoids the problem that when the number of the terminals is more, the time delay of the terminal receiving the data after the sequence is longer, which affects the user experience.
The method of the invention realizes that the data is transmitted to each terminal through multithreading at the same time after being collected, thereby fully playing the advantage of multi-core of the prior computer, avoiding the frequent io operation in a single thread and improving the data throughput of the system.
Drawings
FIG. 1 is a schematic flow diagram of the process of the present invention.
Detailed description of the invention
Fig. 1 provides a data forwarding method, which includes the following steps:
s1, acquiring data in a programmable logic controller through an acquisition thread and sending the data to an industrial personal computer;
s2, storing the obtained data through different cache regions in the industrial personal computer;
and S3, transmitting the data acquired from the cache region to the terminal through a transmission thread through network transmission.
In one embodiment, the data is read from the programmable logic controller to the memory by the collection thread and copied to the plurality of buffer areas.
In one embodiment, the data obtained in the buffer is forwarded to each terminal by creating a plurality of transmission threads.
The data are continuously read from the programmable logic controller to be stored in the memory through the acquisition thread and are copied to the plurality of cache regions, then the plurality of threads are established, the data in the cache regions are respectively forwarded to each terminal, more data are supported to be sent, the frequent io operation in a single thread is avoided, and the data throughput of the system is improved.
In one embodiment, the cache area in S2 includes a PC forwarding cache area, a tablet forwarding cache area, and a cloud forwarding cache area.
In one embodiment, the plurality of transmission threads in S3 include a PC forwarding thread, a tablet forwarding thread, and a cloud forwarding thread.
The data throughput of the system is greatly improved by setting a plurality of transmission threads, and the time-consuming io operation is dispersed into multiple threads for execution, so that the probability of communication delay is greatly reduced.
In one embodiment, the terminal in S3 includes a PC terminal, a tablet terminal, a mobile phone terminal, and a cloud terminal.
In one embodiment, the cloud is a cloud server.
In one embodiment, the acquiring data in the programmable logic controller is acquiring exercise training data generated by a servo motor controlled exercise machine.
In one embodiment, the exercise training data is exercise data obtained by exercising in different training modes.
In an embodiment, the obtained exercise training data is viewed in a PC end system, a tablet end APP and a mobile phone end APP.
In one embodiment, the creating of the multiple transfer threads enables the task of data transfer to be distributed among multiple threads for execution.
The method supports sending more data, and avoids the problem that when the number of the terminals is large, the time delay of receiving the data by the terminal after the sequence is large, and the user experience is influenced.
The method of the invention realizes that the data is transmitted to each terminal through multithreading at the same time after being collected, thereby fully playing the advantage of multi-core of the prior computer, avoiding the frequent io operation in a single thread and improving the data throughput of the system.

Claims (10)

1. A data forwarding method is characterized by comprising the following steps:
s1, acquiring data in a programmable logic controller through an acquisition thread and sending the data to an industrial personal computer;
s2, storing the obtained data through different cache regions in the industrial personal computer;
and S3, transmitting the data acquired from the cache region to the terminal through a transmission thread through network transmission.
2. The data forwarding method of claim 1 wherein the data is read from the programmable logic controller by the acquisition thread to be placed into the memory and copied to the plurality of buffer areas.
3. The data forwarding method according to claim 2, wherein the data obtained from the buffer is forwarded to each terminal by creating a plurality of transmission threads.
4. The data forwarding method of any one of claims 1-3, wherein the cache in S2 comprises a PC forwarding cache, a tablet forwarding cache, and a cloud forwarding cache.
5. The data forwarding method of claim 3, wherein the plurality of transmission threads in S3 comprise a PC forwarding thread, a tablet forwarding thread, and a cloud forwarding thread.
6. The data forwarding method of claim 1, wherein the terminal in S3 comprises a PC terminal, a tablet terminal, a mobile phone terminal, and a cloud terminal.
7. The data forwarding method of claim 6 wherein the cloud is a cloud server.
8. The method of claim 1, wherein the obtaining data in the programmable logic controller is obtaining exercise training data generated by a servo motor controlled exercise machine.
9. The data forwarding method of claim 8 wherein the obtained athletic training data is implemented for viewing in a terminal.
10. The data forwarding method of claim 3 wherein the creating of multiple transfer threads enables the task of data transfer to be distributed among multiple threads for execution.
CN202111130825.1A 2021-09-26 2021-09-26 Data forwarding method Pending CN113890887A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111130825.1A CN113890887A (en) 2021-09-26 2021-09-26 Data forwarding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111130825.1A CN113890887A (en) 2021-09-26 2021-09-26 Data forwarding method

Publications (1)

Publication Number Publication Date
CN113890887A true CN113890887A (en) 2022-01-04

Family

ID=79006736

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111130825.1A Pending CN113890887A (en) 2021-09-26 2021-09-26 Data forwarding method

Country Status (1)

Country Link
CN (1) CN113890887A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510085A (en) * 2009-03-13 2009-08-19 东华大学 Fluoroplastic film defect on-line detecting control system based on process control machine
CN103441937A (en) * 2013-08-21 2013-12-11 曙光信息产业(北京)有限公司 Sending method and receiving method of multicast data
CN106547495A (en) * 2015-09-21 2017-03-29 北大方正集团有限公司 Print processing method and device
CN106647615A (en) * 2016-12-22 2017-05-10 广州数控设备有限公司 Numerical-control machine tool servo adjustment method based on TCP/IP protocol
CN107995061A (en) * 2017-11-30 2018-05-04 北京卓讯科信技术有限公司 Collection and playback system and method when more specification 10Gbps network signals are long
CN110557251A (en) * 2019-09-27 2019-12-10 武汉控安融科技有限公司 Industrial data safety isolation acquisition system and internal and external network data one-way transmission method
CN113347158A (en) * 2021-05-17 2021-09-03 武汉中科通达高新技术股份有限公司 Streaming media data receiving and transmitting method and device and electronic equipment

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510085A (en) * 2009-03-13 2009-08-19 东华大学 Fluoroplastic film defect on-line detecting control system based on process control machine
CN103441937A (en) * 2013-08-21 2013-12-11 曙光信息产业(北京)有限公司 Sending method and receiving method of multicast data
CN106547495A (en) * 2015-09-21 2017-03-29 北大方正集团有限公司 Print processing method and device
CN106647615A (en) * 2016-12-22 2017-05-10 广州数控设备有限公司 Numerical-control machine tool servo adjustment method based on TCP/IP protocol
CN107995061A (en) * 2017-11-30 2018-05-04 北京卓讯科信技术有限公司 Collection and playback system and method when more specification 10Gbps network signals are long
CN110557251A (en) * 2019-09-27 2019-12-10 武汉控安融科技有限公司 Industrial data safety isolation acquisition system and internal and external network data one-way transmission method
CN113347158A (en) * 2021-05-17 2021-09-03 武汉中科通达高新技术股份有限公司 Streaming media data receiving and transmitting method and device and electronic equipment

Similar Documents

Publication Publication Date Title
CN113419824A (en) Data processing method, device, system and computer storage medium
WO2014082562A1 (en) Method, device, and system for information processing based on distributed buses
TWI786527B (en) User code operation method of programming platform, electronic equipment and computer-readable storage medium
CN105487990A (en) Method and device for transmitting information messages between CPU and chip
CN105025068A (en) Network data downloading method and apparatus
CN102891809A (en) Interface order-preserving method and system of messages of multi-core network device
CN106797557A (en) The method and terminal of data transfer
WO2023174184A1 (en) Virtual resource processing method and apparatus
CN113890887A (en) Data forwarding method
CN110995817B (en) Request callback method and device and client equipment
WO2021226781A1 (en) Firewall rule updating method and apparatus, server, and storage medium
CN104965810A (en) Method and device for rapidly processing data message in multi-core mode
CN111352657B (en) Method for reading x86 data by FPGA (field programmable gate array) in high-speed and high-efficiency pipelining manner
CN111131499A (en) Concurrent and asynchronous task processing method and device thereof
CN112367536B (en) RDMA (remote direct memory Access) mixed transmission method, system and medium for large data of video file
CN103905484A (en) Method of processing hyper text transport protocol (HTTP) requests and device
CN112057832B (en) Live-action riding training system based on mobile streaming media technology
WO2024156239A1 (en) Video streaming transmission method and apparatus, electronic device, and storage medium
CN103227816A (en) Data transmission method, data processing method, device and system
CN106657256A (en) Resource acquisition processing method and device
CN102902593A (en) Protocol distribution processing system based on cache mechanism
CN107846328B (en) Network rate real-time statistical method based on concurrent lock-free ring queue
CN113596325B (en) Method and device for capturing images, electronic equipment and storage medium
CN109656705A (en) A kind of method and apparatus of data processing
CN104901783B (en) Data transmission method and server system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination