TWI761846B - Data auto-transmitting method, apparatus, and storage medium thereof - Google Patents

Data auto-transmitting method, apparatus, and storage medium thereof Download PDF

Info

Publication number
TWI761846B
TWI761846B TW109118356A TW109118356A TWI761846B TW I761846 B TWI761846 B TW I761846B TW 109118356 A TW109118356 A TW 109118356A TW 109118356 A TW109118356 A TW 109118356A TW I761846 B TWI761846 B TW I761846B
Authority
TW
Taiwan
Prior art keywords
data
address
identification
module
preset
Prior art date
Application number
TW109118356A
Other languages
Chinese (zh)
Other versions
TW202147120A (en
Inventor
宋大成
Original Assignee
鴻海精密工業股份有限公司
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 鴻海精密工業股份有限公司 filed Critical 鴻海精密工業股份有限公司
Priority to TW109118356A priority Critical patent/TWI761846B/en
Publication of TW202147120A publication Critical patent/TW202147120A/en
Application granted granted Critical
Publication of TWI761846B publication Critical patent/TWI761846B/en

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The present disclosure relates to a data auto-transmitting method, an apparatus, and a storage medium thereof. The method includes: a storage with storage modules receives data from a processor and acquires identification information of the data; the data corresponds to one of the storage modules the storage; the storage searches a starting address based on the identification information; the storage sets the storage module corresponding to the data as a target storage module, and sets a target control module corresponding to the data; a pointer of the target control module transmits the data from the starting address; the storage tums off an outputting function of the storage when an interrupt command is received and the current pointer points to an end address, thus a transmitting speed of the data is improved based on the auto-acquiring operation of starting address and the determining operation of the interrupt command.

Description

自動資料傳輸方法、裝置及存儲介質 Automatic data transmission method, device and storage medium

本發明涉及一種自動資料傳輸方法、裝置及存儲介質。 The present invention relates to an automatic data transmission method, device and storage medium.

隨著通訊技術的發展,在終端設備中產生的資料量變的日益龐大。終端設備中通常包括中央處理器(Central processing unit,CPU)、動態隨機記憶體(Dynamic random access memory,DRAM)、靜態隨機記憶體(Static random access memory,SRAM)以及其他功能模組。終端設備中產生的資料通常需要先在記憶體中進行暫存並經過一些處理後再發送給對應的功能模組,以使得對應的功能模組接收到需求資料。現有技術中,CPU需要先將目標資料從DRAM中讀出並分析資料以確定傳輸順序,上述過程耗時較長,且佔用CPU處理其他指令的時間,無法實現資料在傳輸過程中的快速回應。 With the development of communication technology, the amount of data generated in terminal equipment becomes increasingly huge. A terminal device usually includes a central processing unit (CPU), a dynamic random access memory (DRAM), a static random access memory (SRAM), and other functional modules. The data generated in the terminal device usually needs to be temporarily stored in the memory and sent to the corresponding functional module after some processing, so that the corresponding functional module can receive the required data. In the prior art, the CPU needs to first read out the target data from the DRAM and analyze the data to determine the transmission sequence. The above process takes a long time, and takes up the time of the CPU to process other instructions, so that the rapid response of the data during the transmission process cannot be achieved.

本發明的主要目的是提供一種自動資料傳輸方法、裝置及存儲介質,旨在解決現有技術中無法實現傳輸過程中的快速回應的問題。 The main purpose of the present invention is to provide an automatic data transmission method, device and storage medium, aiming at solving the problem that the prior art cannot realize the quick response in the transmission process.

一種自動資料傳輸方法,應用於與處理器進行通訊的記憶體中;所述記憶體包括第一存儲模組和第二存儲模組;所述自動資料傳輸方法包括: 在偵測到接收指令時,記憶體接收由處理器傳送的資料並獲取所述資料的標識資訊;其中,所述資料將所述第一存儲模組和所述第二存儲模組中的一者作為預設存儲模組;所述標識資訊用於標識所述資料的在目標記憶體內是否具有指定的起始位址;在偵測到查詢指令時,所述記憶體根據標識資訊查詢所述資料對應的起始位址;在偵測到設定指令時,將所述資料對應的預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組;在偵測到傳送指令時,控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送;在偵測到檢測指令時,判斷是否接收到中斷指令;在接收到中斷指令時,判斷當前所述指針對應的位址是否為末位位址;在當前所述指針對應的位址為所述末位位址時,關閉所述記憶體的輸出功能。 An automatic data transmission method is applied to a memory that communicates with a processor; the memory includes a first storage module and a second storage module; the automatic data transmission method includes: When the receiving instruction is detected, the memory receives the data transmitted by the processor and obtains the identification information of the data; wherein, the data is one of the first storage module and the second storage module. as a default storage module; the identification information is used to identify whether the data has a specified starting address in the target memory; when a query command is detected, the memory queries the The starting address corresponding to the data; when the setting instruction is detected, the preset storage module corresponding to the data is set as the target storage module, and the target control module is set according to the predetermined operation corresponding to the data; in When detecting the transmission command, control the pointer of the target control module to start from the starting address to transmit the multi-segment data segments corresponding to the data; when detecting the detection command, determine whether an interrupt command is received When receiving the interrupt instruction, judge whether the address corresponding to the current pointer is the last address; when the address corresponding to the current pointer is the last address, close the output function of the memory .

優選地,所述標識資訊包括預設標識ID和指定標識ID;所述根據標識資訊查詢所述資料對應的起始位址以及目標記憶體的步驟包括:判斷所述標識資訊是否為所述預設標識ID;在所述標識資訊不是所述預設標識ID時,獲取與所述指定標識ID對應的指定位址作為起始位址;在所述標識資訊是所述預設標識ID時,獲取與所述預設標識ID對應的預設位址作為起始位址。 Preferably, the identification information includes a preset identification ID and a designated identification ID; the step of querying the starting address and target memory corresponding to the data according to the identification information includes: judging whether the identification information is the preset identification information. Set the identification ID; when the identification information is not the preset identification ID, obtain the designated address corresponding to the designated identification ID as the starting address; when the identification information is the preset identification ID, A preset address corresponding to the preset identifier ID is acquired as a starting address.

優選地,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 Preferably, the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476.

優選地,所述將所述資料對應的預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組的步驟包括:將所述資料對應的所述預設存儲模組設定為目標存儲模組;判斷所述預定操作資訊是否為讀取操作;在所述預定操作資訊為讀取操作時,設定所述記憶體內的讀取控制模組作為目標控制模組;在所述預定操作資訊為寫入操作時,設定所述記憶體內的寫入控制模組作為目標控制模組。 Preferably, the step of setting a preset storage module corresponding to the data as a target storage module, and setting a target control module according to a predetermined operation corresponding to the data comprises: setting the preset storage module corresponding to the data Set the storage module as the target storage module; determine whether the predetermined operation information is a read operation; when the predetermined operation information is a read operation, set the read control module in the memory as the target control module group; when the predetermined operation information is a write operation, set the write control module in the memory as the target control module.

優選地,在未接收到中斷指令且所述目標控制模組完成從所述起點至所述末位位址的傳送後,所述目標控制模組返回目標存儲模組的起始位址繼續進行對應的多段資料段的傳送。 Preferably, after the interrupt instruction is not received and the target control module completes the transmission from the starting point to the last address, the target control module returns to the starting address of the target storage module to continue the process. The transmission of the corresponding multi-segment data segment.

此外,為了實現上述目的,本發明還提出一種自動資料傳輸裝置,所述自動資料傳輸裝置包括:處理器;記憶體,接收所述處理器輸出的資料,且包括第一存儲模組和第二存儲模組;所述記憶體包括:接收模組,用於在偵測到接收指令時接收由所述處理器傳送的資料並獲取所述資料的標識資訊;其中,所述資料將所述第一存儲模組和所述第二存儲模組中的一者作為預設存儲模組;所述標識資訊用於標識所述資料的在目標記憶體內是否具有指定的起始位址;標識檢測模組,用於在偵測到查詢指令時所述記憶體根據標識資訊查詢所述資料對應的起始位址; 所述接收模組進一步地用於在偵測到設定指令時將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組;所述接收模組進一步地在偵測到傳送指令時控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送;所述接收模組進一步地在偵測到檢測指令時判斷是否接收到中斷指令;末位位址檢測模組,用於在接收到中斷指令時判斷當前所述指針對應的位址是否為末位位址;在當前所述指針對應的位址為所述末位位址時,所述末位位址檢測模組關閉所述記憶體的輸出功能。 In addition, in order to achieve the above object, the present invention also provides an automatic data transmission device, the automatic data transmission device includes: a processor; a memory, which receives the data output by the processor, and includes a first storage module and a second storage module a storage module; the memory includes: a receiving module for receiving the data transmitted by the processor and acquiring the identification information of the data when a receiving instruction is detected; wherein, the data converts the first One of a storage module and the second storage module is used as a default storage module; the identification information is used to identify whether the data has a specified starting address in the target memory; identification detection module group, used for the memory to query the starting address corresponding to the data according to the identification information when the query command is detected; The receiving module is further configured to set the preset storage module corresponding to the data as a target storage module when a setting instruction is detected, and set a target control module according to a predetermined operation corresponding to the data The receiving module further controls the pointer of the target control module to transmit the corresponding multi-segment data segments from the starting address when the transmission instruction is detected; the receiving module is further When the detection command is detected, it is judged whether the interrupt command is received; the last address detection module is used to judge whether the address corresponding to the current pointer is the last address when the interrupt command is received; When the address corresponding to the pointer is the last address, the last address detection module turns off the output function of the memory.

優選地,所述標識檢測模組進一步地判斷所述標識資訊是否為所述預設標識ID;在所述標識資訊不是所述預設標識ID時,所述標識檢測模組進一步地獲取與所述指定標識ID對應的指定位址作為起始位址;在所述標識資訊是所述預設標識ID時,所述標識檢測模組進一步地獲取與所述預設標識ID對應的預設位址作為起始位址。 Preferably, the identification detection module further determines whether the identification information is the preset identification ID; when the identification information is not the preset identification ID, the identification detection module further obtains and The designated address corresponding to the designated identification ID is used as the starting address; when the identification information is the preset identification ID, the identification detection module further obtains the preset position corresponding to the preset identification ID. address as the starting address.

優選地,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 Preferably, the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476.

優選地,所述接收模組進一步地將所述資料對應的所述預設存儲模組設定為目標存儲模組並判斷所述預定操作資訊是否為讀取操作;在所述預定操作資訊為讀取操作時,所述接收模組進一步地設定讀取控制模組作為目標控制模組;在所述預定操作資訊為寫入操作時,所述接收模組進一步地設定寫入控制模組作為目標控制模組。 Preferably, the receiving module further sets the preset storage module corresponding to the data as a target storage module and determines whether the predetermined operation information is a read operation; if the predetermined operation information is a read operation During the fetch operation, the receiving module further sets the read control module as the target control module; when the predetermined operation information is the write operation, the receiving module further sets the write control module as the target control module.

此外,為了實現上述目的,本發明還提出一種存儲介質,所述存儲介質為電腦可讀存儲介質,存儲有至少一個指令,所述至少一個指令被處理器執行時實現如下步驟:在偵測到接收指令時,記憶體接收由處理器傳送的資料並獲取所述資料的標識資訊;其中,所述資料將第一存儲模組和第二存儲模組中的一者作為預設存儲模組;所述標識資訊用於標識所述資料的在目標記憶體內是否具有指定的起始位址;在偵測到查詢指令時,所述記憶體根據標識資訊查詢所述資料對應的起始位址;在偵測到設定指令時,將所述資料對應的預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組;在偵測到傳送指令時,控制所述目標控制模組的指針從所述起點開始將所述資料對應的多段資料段進行傳送;在偵測到檢測指令時,判斷是否接收到中斷指令;在接收到中斷指令時,判斷當前所述指針對應的位址是否為末位位址;在當前所述指針對應的位址為所述末位位址時,關閉所述記憶體的輸出功能。 In addition, in order to achieve the above object, the present invention also proposes a storage medium, the storage medium is a computer-readable storage medium, and stores at least one instruction. When the at least one instruction is executed by the processor, the following steps are implemented: when detecting When receiving the instruction, the memory receives the data transmitted by the processor and obtains the identification information of the data; wherein, the data uses one of the first storage module and the second storage module as a default storage module; The identification information is used to identify whether the data has a specified starting address in the target memory; when a query instruction is detected, the memory queries the starting address corresponding to the data according to the identification information; When the setting instruction is detected, the preset storage module corresponding to the data is set as the target storage module, and the target control module is set according to the predetermined operation corresponding to the data; when the transmission instruction is detected, control The pointer of the target control module starts to transmit the multi-segment data segments corresponding to the data from the starting point; when a detection command is detected, it is judged whether an interrupt command is received; when an interrupt command is received, it is judged that the current whether the address corresponding to the pointer is the last address; when the current address corresponding to the pointer is the last address, the output function of the memory is turned off.

上述自動資料傳輸方法、裝置及存儲介質,記憶體可自動根據輸入的資料或指令進行資料起始位址的確定以及傳輸操作,減少了資料傳輸對處理器佔用,進而提升在資料傳輸過程中記憶體的回應速度;並在偵測到中斷指令時進一步檢測末位位址,以保證資料傳輸過程中資料的完整性。 In the above-mentioned automatic data transmission method, device and storage medium, the memory can automatically determine the starting address of the data and the transmission operation according to the input data or instructions, which reduces the occupation of the processor for the data transmission, thereby improving the memory during the data transmission process. The response speed of the body; and when the interrupt command is detected, the last bit address is further detected to ensure the integrity of the data during the data transmission process.

100:自動資料傳輸裝置 100: Automatic data transmission device

10:處理器 10: Processor

20:記憶體 20: Memory

30:通信匯流排 30: Communication bus

201:接收模組 201: Receive module

202:標識檢測模組 202: Identification detection module

203:寫入控制模組 203: Write control module

204:讀取控制模組 204: Read control module

205:第一存儲模組 205: The first storage module

206:第二存儲模組 206: Second storage module

207:末位位址檢測模組 207: Last bit address detection module

208:第一緩存模組 208: The first cache module

209:第二緩存模組 209: Second cache module

210:輸出控制模組 210: Output control module

211:輸出模組 211: Output module

S10-S16:步驟 S10-S16: Steps

圖1為本發明自動資料傳輸方法的示意圖。 FIG. 1 is a schematic diagram of an automatic data transmission method of the present invention.

圖2為圖1中步驟S11的細化流程示意圖。 FIG. 2 is a schematic diagram of the refinement flow of step S11 in FIG. 1 .

圖3為圖1中步驟S12的細化流程示意圖。 FIG. 3 is a schematic diagram of the refinement flow of step S12 in FIG. 1 .

圖4為本發明資料傳輸裝置的功能模組圖。 FIG. 4 is a functional module diagram of the data transmission device of the present invention.

為了使本技術領域的人員更好地理解本發明方案,下面將結合本發明實施例中的附圖,對本發明實施例中的技術方案進行清楚、完整地描述,顯然,所描述的實施例僅僅是本發明一部分的實施例,而不是全部的實施例。基於本發明中的實施例,本領域普通技術人員在沒有做出創造性勞動前提下所獲得的所有其他實施例,都應當屬於本發明保護的範圍。 In order to make those skilled in the art better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only Embodiments are part of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

本發明的說明書及上述附圖中的術語「第一」、「第二」和「第三」等是用於區別不同物件,而非用於描述特定順序。此外,術語「包括」以及它們任何變形,意圖在於覆蓋不排他的包含。例如包含了一系列步驟或模組的過程、方法、系統、產品或設備沒有限定於已列出的步驟或模組,而是可選地還包括沒有列出的步驟或模組,或可選地還包括對於這些過程、方法、產品或設備固有的其它步驟或模組。 The terms "first", "second" and "third" in the description of the present invention and the above-mentioned drawings are used to distinguish different items, rather than to describe a specific order. Furthermore, the term "comprising" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or modules is not limited to the listed steps or modules, but may optionally also include unlisted steps or modules, or alternatively It also includes other steps or modules inherent to these processes, methods, products or devices.

下面結合附圖對本發明自動資料傳輸方法的具體實施方式進行說明。 The specific embodiments of the automatic data transmission method of the present invention will be described below with reference to the accompanying drawings.

本發明的至少一個實施例中,所述自動資料傳輸方法應用於資料傳輸系統。所述資料傳輸系統包括處理器10(參見圖4)以及至少一個記憶體20(參見圖4)。所述資料傳輸系統提供一視覺化介面。所述視覺化介面用於向使用者提供人機交互介面,使用者可以在藉由手機或電腦等電子設備連接到所述資料傳輸系統。所述自動資料傳輸方法用於所述記憶體20可根據所述處理器10的資料自動進行傳輸以及中斷檢測。 In at least one embodiment of the present invention, the automatic data transmission method is applied to a data transmission system. The data transmission system includes a processor 10 (see FIG. 4 ) and at least one memory 20 (see FIG. 4 ). The data transmission system provides a visual interface. The visual interface is used to provide the user with a human-computer interaction interface, and the user can connect to the data transmission system through electronic equipment such as a mobile phone or a computer. The automatic data transmission method is used for the memory 20 to automatically perform transmission and interruption detection according to the data of the processor 10 .

所述處理器10可以包括一個或者多個微處理器、數位處理器。所述處理器10可調用所述記憶體20中存儲的程式碼以執行相關的功能。例如,圖4中所述的各個模組是存儲在所述記憶體20中的程式碼,並由所述處理器10所執行,以實現一種自動資料傳輸方法。所述處理器10又稱中央處理器(CPU,Central Processing Unit),是一塊超大規模的積體電路,是運算核心(Core)和控制核心(Control Unit)。 The processor 10 may include one or more microprocessors, digital processors. The processor 10 can call the program codes stored in the memory 20 to execute related functions. For example, each module described in FIG. 4 is a program code stored in the memory 20 and executed by the processor 10 to implement an automatic data transmission method. The processor 10, also known as a central processing unit (CPU, Central Processing Unit), is an ultra-large-scale integrated circuit, and is a computing core (Core) and a control core (Control Unit).

所述記憶體20用於存儲資料以及程式碼。所述記憶體20可以是積體電路中沒有實物形式的具有存儲功能的電路,或者,所述記憶體20也可以是具有實物形式的記憶體,如記憶體條、TF卡(Trans-flash Card)、智慧媒體卡(smart media card)、安全數位卡(secure digital card)、快閃記憶體卡(flash card)等儲存設備。所述記憶體20可藉由通信匯流排30與處理器10進行資料通信。所述記憶體20中可以包括作業系統、網路通信模組以及資料傳輸程式。作業系統是管理和控制資料傳輸裝置100硬體和軟體資源的程式,支援資料傳輸程式以及其它軟體和/或程式的運行。網路通信模組用於實現所述記憶體20內部各元件之間的通信,以及與電子設備100中其它硬體和軟體之間通信。 The memory 20 is used for storing data and program codes. The memory 20 may be a circuit with a storage function that does not have a physical form in an integrated circuit, or the memory 20 may also be a memory with a physical form, such as a memory stick, a TF card (Trans-flash Card). ), smart media card (smart media card), secure digital card (secure digital card), flash memory card (flash card) and other storage devices. The memory 20 can communicate data with the processor 10 through the communication bus 30 . The memory 20 may include an operating system, a network communication module and a data transfer program. The operating system is a program that manages and controls the hardware and software resources of the data transfer device 100, and supports the operation of the data transfer program and other software and/or programs. The network communication module is used to realize the communication between the various components in the memory 20 and communicate with other hardware and software in the electronic device 100 .

請參閱圖1,其為自動資料傳輸方法的流程圖。 Please refer to FIG. 1 , which is a flowchart of an automatic data transmission method.

S10、在偵測到接收指令時,記憶體接收由處理器傳送的資料並獲取所述資料的標識資訊。 S10. When the receiving instruction is detected, the memory receives the data transmitted by the processor and obtains the identification information of the data.

本發明的至少一個實施例中,所述資料包括多段資訊段、預定存儲模組資訊、預定操作指令資訊以及標識資訊。其中,所述預定存儲模組資訊和所述操作指令資訊可以藉由使用者的自訂設定指定的符號指代。在本發明的至少一個實施例中,所述屬性資訊為數位和符號的組合。例如,所述屬性資訊可以為0×2,其中,「0」指代第一存儲模組205為預定存儲模 組,「2」指代讀取操作為預定操作指令。所述標識資訊用於標識所述資料的在目標存儲模組內是否具有指定起始位址。所述標識資訊為正整數。所述標識資訊包括預設標識ID和指定標識ID。其中,所述預設標識ID用於表示所述資料對應預設起始位址;所述指定標識ID用於表示所述資料對應指定起始位址。在本發明的至少一個實施例中,所述預設標識ID為0,所述指定標識ID可以為1、2或3等數位。在所述第一存儲模組205和所述第二存儲模組206中可存儲有預設標識ID、指定標識ID、預設起始位址以及指定起始位址之間對應關係的列表。 In at least one embodiment of the present invention, the data includes multiple pieces of information, predetermined storage module information, predetermined operation instruction information, and identification information. Wherein, the predetermined storage module information and the operation instruction information may be designated by symbols designated by the user's custom settings. In at least one embodiment of the present invention, the attribute information is a combination of digits and symbols. For example, the attribute information may be 0×2, wherein “0” indicates that the first storage module 205 is a predetermined storage module group, "2" indicates that the read operation is a predetermined operation command. The identification information is used to identify whether the data has a specified start address in the target storage module. The identification information is a positive integer. The identification information includes a preset identification ID and a designated identification ID. Wherein, the preset identification ID is used to indicate that the data corresponds to a preset starting address; the specified identification ID is used to indicate that the data corresponds to a designated starting address. In at least one embodiment of the present invention, the preset identification ID is 0, and the specified identification ID may be 1, 2, or 3 digits. The first storage module 205 and the second storage module 206 may store a list of preset identification IDs, designated identification IDs, preset starting addresses, and corresponding relationships among designated starting addresses.

S11、在偵測到查詢指令時,所述記憶體根據標識資訊查詢所述資料對應的起始位址。 S11. When a query command is detected, the memory queries the starting address corresponding to the data according to the identification information.

請一併參閱圖2,本發明的至少一個實施例中,所述記憶體根據標識資訊資訊查詢所述資料對應的起始位址的步驟包括:S110、判斷所述標識資訊是否為所述預設標識ID;S111、在所述標識資訊不是所述預設標識ID時,獲取與所述指定標識ID對應的指定位址作為起始位址;S112、在所述標識資訊是所述預設標識ID時,獲取與所述預設標識ID對應的預設位址作為起始位址。 Please also refer to FIG. 2. In at least one embodiment of the present invention, the step of querying the memory for the starting address corresponding to the data according to the identification information includes: S110, judging whether the identification information is the preset address. Set an identification ID; S111, when the identification information is not the default identification ID, obtain a designated address corresponding to the designated identification ID as a starting address; S112, when the identification information is the default identification ID When identifying the ID, the preset address corresponding to the preset identification ID is obtained as the starting address.

本發明的至少一個實施例中,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 In at least one embodiment of the present invention, the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476.

S12、在偵測到設定指令時,將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組。 S12. When a setting instruction is detected, set the preset storage module corresponding to the data as a target storage module, and set a target control module according to a predetermined operation corresponding to the data.

請一併參閱圖3,本發明的至少一個實施例中,所述將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組的步驟包括: S121、將所述資料對應的所述預設存儲模組設定為目標存儲模組;S122、判斷所述預定操作資訊是否為讀取操作;S123、在所述預定操作資訊為讀取操作時,設定所述記憶體內的讀取控制模組作為目標控制模組;S124,在所述預定操作資訊為寫入操作時,設定所述記憶體內的寫入控制模組作為目標控制模組。 Please also refer to FIG. 3. In at least one embodiment of the present invention, the preset storage module corresponding to the data is set as the target storage module, and the target control is set according to the predetermined operation corresponding to the data The steps of the mod include: S121. Set the default storage module corresponding to the data as a target storage module; S122. Determine whether the predetermined operation information is a read operation; S123. When the predetermined operation information is a read operation, Set the read control module in the memory as the target control module; S124, when the predetermined operation information is a write operation, set the write control module in the memory as the target control module.

S13、在偵測到傳送指令時,控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送。 S13. When a transfer instruction is detected, control the pointer of the target control module to transfer the multi-segment data segments corresponding to the data from the start address.

本發明的至少一個實施例中,所述記憶體20還進一步包括與所述第一存儲模組205對應的第一緩存模組以及與所述第二存儲模組206對應的第二緩存模組。在所述操作資訊為讀取操作時,所述傳送操作為所述讀取控制模組將所述起點開始將所述目標存儲模組對應的資料傳送給所述第一緩存模組。在所述操作資訊為寫入操作時,所述傳送操作為所述寫入控制模組將來自所述處理器10的所述資料從所述目標存儲模組內的所述起始位址開始存儲。 In at least one embodiment of the present invention, the memory 20 further includes a first cache module corresponding to the first storage module 205 and a second cache module corresponding to the second storage module 206 . When the operation information is a read operation, the transmission operation is that the read control module starts to transmit the data corresponding to the target storage module to the first cache module from the starting point. When the operation information is a write operation, the transfer operation is for the write control module to start the data from the processor 10 from the start address in the target storage module storage.

S14、在偵測到檢測指令時,判斷是否接收到中斷指令。 S14, when the detection instruction is detected, determine whether an interrupt instruction is received.

S15、在接收到中斷指令時,判斷當前所述指針對應的位址是否為末位位址。 S15. When receiving the interrupt instruction, determine whether the address corresponding to the current pointer is the last address.

S16、在當前所述指針對應的位址為所述末位位址時,關閉所述記憶體20的輸出功能。 S16 , when the address corresponding to the current pointer is the last address, turn off the output function of the memory 20 .

在未接收到中斷指令時,返回步驟S13。 When the interrupt command is not received, the process returns to step S13.

本發明的至少一個實施例中,在未接收到中斷指令且所述目標控制模組完成從所述起點至末位位址的傳送後,所述目標控制模組返回目標存儲模組的起始位址繼續進行對應的多段資料段的傳送。 In at least one embodiment of the present invention, after the interrupt instruction is not received and the target control module completes the transfer from the start to the end address, the target control module returns to the start of the target storage module The address continues to transmit the corresponding multi-segment data segment.

本發明的至少一個實施例中,藉由控制所述記憶體20的輸出模組211(參見圖4)關閉實現關閉所述記憶體20的輸出功能。 In at least one embodiment of the present invention, the output function of the memory 20 is turned off by controlling the output module 211 (see FIG. 4 ) of the memory 20 to turn off.

在當前所述指針對應的位址不是所述末位位址時,返回步驟S14。 When the address corresponding to the current pointer is not the last address, return to step S14.

本發明的至少一個實施例中,在未接收到中斷指令且所述目標控制模組完成從所述起點至末位位址的傳送後,所述目標控制模組返回目標存儲模組的首位位址繼續進行對應的多段資料段的傳送。 In at least one embodiment of the present invention, after the interrupt instruction is not received and the target control module completes the transmission from the starting point to the last bit address, the target control module returns to the first bit of the target storage module The address continues to transmit the corresponding multi-segment data segment.

本發明的至少一個實施例中,上述所有指令可以是藉由電子設備接收的資料請求指令。所述電子設備可以包括鍵盤、觸控式螢幕等,但是本公開的示例實施例中的使用者輸入方式不限於此,可以為使用者在視覺化介面上藉由特定的操作產生。具體地,所述用戶的操作包括,但不限於:滑動操作、點擊操作(如:按一下操作、按兩下操作等等)。具體地,所述預設按鍵可以是所述電子設備上的實體按鍵,也可以是所述電子設備上的虛擬按鍵等等(例如:所述虛擬按鍵可以是所述電子設備的顯示器上的一個虛擬圖示等),本發明在此不做限制。 In at least one embodiment of the present invention, all the above-mentioned instructions may be data request instructions received by an electronic device. The electronic device may include a keyboard, a touch screen, etc., but the user input method in the exemplary embodiment of the present disclosure is not limited thereto, and may be generated by a user through a specific operation on a visual interface. Specifically, the user's operation includes, but is not limited to, a sliding operation, a click operation (eg, a single-click operation, a double-click operation, etc.). Specifically, the preset button may be a physical button on the electronic device, or a virtual button on the electronic device, etc. (for example, the virtual button may be a button on the display of the electronic device. virtual diagrams, etc.), the present invention is not limited herein.

上述自動資料傳輸方法,記憶體20可自動根據輸入的資料或指令進行資料起始位址的確定以及傳輸操作,減少了資料傳輸對處理器10佔用,進而提升在資料傳輸過程中記憶體20的回應速度;並在偵測到中斷指令時進一步檢測末位位址,以保證資料傳輸過程中資料的完整性。 In the above-mentioned automatic data transmission method, the memory 20 can automatically determine the starting address of the data and the transmission operation according to the input data or instructions, which reduces the occupation of the processor 10 for data transmission, and further improves the memory 20 during the data transmission process. response speed; and further detect the last bit address when the interrupt command is detected to ensure the integrity of the data during the data transmission process.

請參照圖4,本發明提供一種自動資料傳輸裝置100包括處理器10、記憶體20及通信匯流排30。 Referring to FIG. 4 , the present invention provides an automatic data transmission device 100 including a processor 10 , a memory 20 and a communication bus 30 .

所述處理器10可以包括一個或者多個微處理器、數文書處理器。所述處理器10可調用所述記憶體20中存儲的程式碼以執行相關的功能。例如,圖4中所述的各個模組是存儲在所述記憶體20中的程式碼,並由所述處理器10所執行,以實現一種自動資料傳輸方法。所述處理器10又稱中央處 理器(CPU,Central Processing Unit),是一塊超大規模的積體電路,是運算核心(Core)和控制核心(Control Unit)。 The processor 10 may include one or more microprocessors, digital word processors. The processor 10 can call the program codes stored in the memory 20 to execute related functions. For example, each module described in FIG. 4 is a program code stored in the memory 20 and executed by the processor 10 to implement an automatic data transmission method. The processor 10 is also called the central The CPU (Central Processing Unit) is a large-scale integrated circuit, which is the computing core (Core) and the control core (Control Unit).

所述記憶體20用於存儲資料以及程式碼。所述記憶體20可以是積體電路中沒有實物形式的具有存儲功能的電路,或者,所述記憶體20也可以是具有實物形式的記憶體,如記憶體條、TF卡(Trans-flash Card)、智慧媒體卡(smart media card)、安全數位卡(secure digital card)、快閃記憶體卡(flash card)等儲存設備。所述記憶體20可藉由通信匯流排30與處理器10進行資料通信。所述記憶體20中可以包括作業系統、網路通信模組以及資料傳輸程式。作業系統是管理和控制所述資料傳輸裝置100硬體和軟體資源的程式,支援資料傳輸程式以及其它軟體和/或程式的運行。網路通信模組用於實現所述記憶體20內部各元件之間的通信,以及與所述資料傳輸裝置100中其它硬體和軟體之間通信。在本發明的至少一個實施例中,所述記憶體20包括第一存儲模組205以及第二存儲模組206。 The memory 20 is used for storing data and program codes. The memory 20 may be a circuit with a storage function that does not have a physical form in an integrated circuit, or the memory 20 may also be a memory with a physical form, such as a memory stick, a TF card (Trans-flash Card). ), smart media card (smart media card), secure digital card (secure digital card), flash memory card (flash card) and other storage devices. The memory 20 can communicate data with the processor 10 through the communication bus 30 . The memory 20 may include an operating system, a network communication module and a data transfer program. The operating system is a program that manages and controls the hardware and software resources of the data transfer device 100, and supports the operation of the data transfer program and other software and/or programs. The network communication module is used to realize the communication between various components in the memory 20 and communicate with other hardware and software in the data transmission device 100 . In at least one embodiment of the present invention, the memory 20 includes a first storage module 205 and a second storage module 206 .

在本發明的一個實施例中,所述記憶體20包括:接收模組201,用於在偵測到接收指令時接收由所述處理器10傳送的資料並獲取所述資料的標識資訊。 In one embodiment of the present invention, the memory 20 includes: a receiving module 201, configured to receive the data transmitted by the processor 10 and obtain the identification information of the data when a receiving command is detected.

本發明的至少一個實施例中,所述資料包括多段資訊段、預定存儲模組資訊、預定操作指令資訊以及標識資訊。其中,所述預定存儲模組資訊和所述操作指令資訊可以藉由使用者的自訂設定指定的符號指代。在本發明的至少一個實施例中,所述屬性資訊為數位和符號的組合。例如,所述屬性資訊可以為0×2,其中,「0」指代第一存儲模組205為預定存儲模組,「2」指代讀取操作為預定操作指令。所述標識資訊用於標識所述資料的在目標存儲模組內是否具有指定起始位址。所述標識資訊為正整數。所述標識資訊包括預設標識ID和指定標識ID。其中,所述預設標識ID用於表 示所述資料對應預設起始位址;所述指定標識ID用於表示所述資料對應指定起始位址。在本發明的至少一個實施例中,所述預設標識ID為0,所述指定標識ID可以為1、2或3等數位。在所述第一存儲模組205和所述第二存儲模組206中可存儲有預設標識ID、指定標識ID、預設起始位址以及指定起始位址之間對應關係的列表。 In at least one embodiment of the present invention, the data includes multiple pieces of information, predetermined storage module information, predetermined operation instruction information, and identification information. Wherein, the predetermined storage module information and the operation instruction information may be designated by symbols designated by the user's custom settings. In at least one embodiment of the present invention, the attribute information is a combination of digits and symbols. For example, the attribute information may be 0×2, wherein “0” indicates that the first storage module 205 is a predetermined storage module, and “2” indicates that the read operation is a predetermined operation command. The identification information is used to identify whether the data has a specified start address in the target storage module. The identification information is a positive integer. The identification information includes a preset identification ID and a designated identification ID. Wherein, the preset identification ID is used for the table Indicates that the data corresponds to a preset start address; the designated identifier ID is used to indicate that the data corresponds to a designated start address. In at least one embodiment of the present invention, the preset identification ID is 0, and the specified identification ID may be 1, 2, or 3 digits. The first storage module 205 and the second storage module 206 may store a list of preset identification IDs, designated identification IDs, preset starting addresses, and corresponding relationships among designated starting addresses.

標識檢測模組202,用於在偵測到查詢指令時所述記憶體根據標識資訊查詢所述資料對應的起始位址。 The identification detection module 202 is used for inquiring the memory according to the identification information for the starting address corresponding to the data when the inquiry command is detected.

請一併參閱圖2,本發明的至少一個實施例中,所述標識檢測模組202進一步地判斷所述標識資訊是否為所述預設標識ID。在所述標識資訊不是所述預設標識ID時,所述標識檢測模組202進一步地獲取與所述指定標識ID對應的指定位址作為起始位址。在所述標識資訊是所述預設標識ID時,所述標識檢測模組202進一步地獲取與所述預設標識ID對應的預設位址作為起始位址。 Please also refer to FIG. 2. In at least one embodiment of the present invention, the identification detection module 202 further determines whether the identification information is the default identification ID. When the identification information is not the default identification ID, the identification detection module 202 further acquires a designated address corresponding to the designated identification ID as a starting address. When the identification information is the preset identification ID, the identification detection module 202 further acquires a preset address corresponding to the preset identification ID as a starting address.

本發明的至少一個實施例中,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 In at least one embodiment of the present invention, the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476.

所述接收模組201進一步地用於在偵測到設定指令時將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組。所述接收模組201進一步地將所述資料對應的所述預設存儲模組設定為目標存儲模組並判斷所述預定操作資訊是否為讀取操作。在所述預定操作資訊為讀取操作時,所述接收模組201進一步地設定讀取控制模組204作為目標控制模組。在所述預定操作資訊為寫入操作時,所述接收模組201進一步地設定寫入控制模組203作為目標控制模組。 The receiving module 201 is further configured to set the default storage module corresponding to the data as a target storage module when a setting instruction is detected, and set a target control module according to a predetermined operation corresponding to the data. Group. The receiving module 201 further sets the default storage module corresponding to the data as a target storage module and determines whether the predetermined operation information is a read operation. When the predetermined operation information is a reading operation, the receiving module 201 further sets the reading control module 204 as a target control module. When the predetermined operation information is a writing operation, the receiving module 201 further sets the writing control module 203 as a target control module.

所述接收模組201進一步地在偵測到傳送指令時控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送。 The receiving module 201 further controls the pointer of the target control module to transmit the multi-segment data segments corresponding to the data from the starting address when detecting the transmission instruction.

本發明的至少一個實施例中,所述記憶體20還進一步包括與所述第一存儲模組205對應的第一緩存模組208以及與所述第二存儲模組206對應的第二緩存模組209。在所述預定操作資訊為讀取操作時,所述傳送操作為所述讀取控制模組204將所述起點開始將所述起始位址對應的資料傳送給所述第一緩存模組208。在所述預定操作資訊為寫入操作時,所述傳送操作為所述寫入控制模組203將來自所述處理器10的所述資料從所述起始位址進行存儲。所述第一緩存模組208以及所述第二緩存模組209可藉由輸出控制模組210提供給輸出模組211進行輸出。 In at least one embodiment of the present invention, the memory 20 further includes a first cache module 208 corresponding to the first storage module 205 and a second cache module corresponding to the second storage module 206 Group 209. When the predetermined operation information is a read operation, the transmission operation is that the read control module 204 starts to transmit the data corresponding to the start address to the first cache module 208 from the start point. . When the predetermined operation information is a write operation, the transfer operation is for the write control module 203 to store the data from the processor 10 from the start address. The first cache module 208 and the second cache module 209 can be provided by the output control module 210 to the output module 211 for output.

所述接收模組201進一步地在偵測到檢測指令時判斷是否接收到中斷指令。 The receiving module 201 further determines whether an interrupt command is received when the detection command is detected.

末位位址檢測模組207,用於在接收到中斷指令時判斷當前所述指針對應的位址是否為末位位址。在當前所述指針對應的位址為所述末位位址時,所述末位位址檢測模組207關閉所述記憶體20的輸出功能。 The last-bit address detection module 207 is used for determining whether the address corresponding to the current pointer is the last-bit address when the interrupt instruction is received. When the address corresponding to the current pointer is the last address, the last address detection module 207 turns off the output function of the memory 20 .

本發明的至少一個實施例中,藉由控制所述記憶體20的輸出模組211關閉實現關閉所述記憶體20的輸出功能。 In at least one embodiment of the present invention, the output function of the memory 20 is turned off by controlling the output module 211 of the memory 20 to turn off.

本發明的至少一個實施例中,在未接收到中斷指令且所述目標控制模組完成從所述起點至末位位址的傳送後,所述目標控制模組返回目標存儲模組的首位位址繼續進行對應的多段資料段的傳送。 In at least one embodiment of the present invention, after the interrupt instruction is not received and the target control module completes the transmission from the starting point to the last bit address, the target control module returns to the first bit of the target storage module The address continues to transmit the corresponding multi-segment data segment.

上述自動資料傳輸裝置,記憶體20可自動根據輸入的資料或指令進行資料起始位址的確定以及傳輸操作,減少了資料傳輸對處理器10佔用,進而提升在資料傳輸過程中記憶體20的回應速度;並在偵測到中斷指令時進一步檢測末位位址,以保證資料傳輸過程中資料的完整性。 In the above-mentioned automatic data transmission device, the memory 20 can automatically determine the starting address of the data and the transmission operation according to the input data or instructions, which reduces the occupation of the processor 10 for data transmission, and further improves the memory 20 during the data transmission process. response speed; and further detect the last bit address when the interrupt command is detected to ensure the integrity of the data during the data transmission process.

本發明還提供一種存儲介質。所述存儲介質為電腦可讀存儲介質。所述電腦可讀存儲介質上存儲有電腦指令。所述電腦指令可被存儲於記憶體20上,且當被一個或多個處理器10執行時從而實現以下步驟: The present invention also provides a storage medium. The storage medium is a computer-readable storage medium. Computer instructions are stored on the computer-readable storage medium. The computer instructions may be stored on memory 20 and, when executed by one or more processors 10, perform the following steps:

S10、在偵測到接收指令時,記憶體接收由處理器傳送的資料並獲取所述資料的標識資訊。 S10. When the receiving instruction is detected, the memory receives the data transmitted by the processor and obtains the identification information of the data.

本發明的至少一個實施例中,所述資料包括多段資訊段、預定存儲模組資訊、預定操作指令資訊以及標識資訊。其中,所述預定存儲模組資訊和所述操作指令資訊可以藉由使用者的自訂設定指定的符號指代。在本發明的至少一個實施例中,所述屬性資訊為數位和符號的組合。例如,所述屬性資訊可以為0×2,其中,「0」指代第一存儲模組205為預定存儲模組,「2」指代讀取操作為預定操作指令。所述標識資訊用於標識所述資料的在目標存儲模組內是否具有指定起始位址。所述標識資訊為正整數。所述標識資訊包括預設標識ID和指定標識ID。其中,所述預設標識ID用於表示所述資料對應預設起始位址;所述指定標識ID用於表示所述資料對應指定起始位址。在本發明的至少一個實施例中,所述預設標識ID為0,所述指定標識ID可以為1、2或3等數位。在所述第一存儲模組205和所述第二存儲模組206中可存儲有預設標識ID、指定標識ID、預設起始位址以及指定起始位址之間對應關係的列表。 In at least one embodiment of the present invention, the data includes multiple pieces of information, predetermined storage module information, predetermined operation instruction information, and identification information. Wherein, the predetermined storage module information and the operation instruction information may be designated by symbols designated by the user's custom settings. In at least one embodiment of the present invention, the attribute information is a combination of digits and symbols. For example, the attribute information may be 0×2, wherein “0” indicates that the first storage module 205 is a predetermined storage module, and “2” indicates that the read operation is a predetermined operation command. The identification information is used to identify whether the data has a specified start address in the target storage module. The identification information is a positive integer. The identification information includes a preset identification ID and a designated identification ID. Wherein, the preset identification ID is used to indicate that the data corresponds to a preset starting address; the specified identification ID is used to indicate that the data corresponds to a designated starting address. In at least one embodiment of the present invention, the preset identification ID is 0, and the specified identification ID may be 1, 2, or 3 digits. The first storage module 205 and the second storage module 206 may store a list of preset identification IDs, designated identification IDs, preset starting addresses, and corresponding relationships among designated starting addresses.

S11、在偵測到查詢指令時,所述記憶體根據標識資訊查詢所述資料對應的起始位址。 S11. When a query command is detected, the memory queries the starting address corresponding to the data according to the identification information.

請一併參閱圖2,本發明的至少一個實施例中,所述記憶體根據標識資訊資訊查詢所述資料對應的起始位址以及目標存儲模組的步驟包括:S110、判斷所述標識資訊是否為所述預設標識ID; S111、在所述標識資訊不是所述預設標識ID時,獲取與所述指定標識ID對應的指定位址作為起始位址;S112、在所述標識資訊是所述預設標識ID時,獲取與所述預設標識ID對應的預設位址作為起始位址。 Please also refer to FIG. 2. In at least one embodiment of the present invention, the step of querying the memory for the starting address and target storage module corresponding to the data according to the identification information includes: S110, determining the identification information Whether it is the preset identification ID; S111, when the identification information is not the default identification ID, obtain a designated address corresponding to the designated identification ID as a starting address; S112, when the identification information is the default identification ID, A preset address corresponding to the preset identifier ID is acquired as a starting address.

本發明的至少一個實施例中,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 In at least one embodiment of the present invention, the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476.

S12、在偵測到設定指令時,將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組。 S12. When a setting instruction is detected, set the preset storage module corresponding to the data as a target storage module, and set a target control module according to a predetermined operation corresponding to the data.

請一併參閱圖3,本發明的至少一個實施例中,所述將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組的步驟包括:S121、將所述資料對應的所述預設存儲模組設定為目標存儲模組;S122、判斷所述預定操作資訊是否為讀取操作;S123、在所述預定操作資訊為讀取操作時,設定所述記憶體內的讀取控制模組作為目標控制模組;S124,在所述預定操作資訊為寫入操作時,設定所述記憶體內的寫入控制模組作為目標控制模組。 Please also refer to FIG. 3. In at least one embodiment of the present invention, the preset storage module corresponding to the data is set as the target storage module, and the target control is set according to the predetermined operation corresponding to the data The steps of the module include: S121, setting the default storage module corresponding to the data as a target storage module; S122, judging whether the predetermined operation information is a read operation; S123, in the predetermined operation information When it is a read operation, set a read control module in the memory as a target control module; S124, when the predetermined operation information is a write operation, set a write control module in the memory as a target control module.

S13、在偵測到傳送指令時,控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送。 S13. When a transfer instruction is detected, control the pointer of the target control module to transfer the multi-segment data segments corresponding to the data from the start address.

本發明的至少一個實施例中,所述記憶體20還進一步包括與所述第一存儲模組205對應的第一緩存模組以及與所述第二存儲模組206對應的第二緩存模組。在所述操作資訊為讀取操作時,所述傳送操作為所述讀取控制模組將所述起點開始將所述目標存儲模組對應的資料傳送給所述第一緩存模組。在所述操作資訊為寫入操作時,所述傳送操作為所述寫入控制 模組將來自所述處理器10的所述資料從所述目標存儲模組內的所述起始位址開始存儲。 In at least one embodiment of the present invention, the memory 20 further includes a first cache module corresponding to the first storage module 205 and a second cache module corresponding to the second storage module 206 . When the operation information is a read operation, the transmission operation is that the read control module starts to transmit the data corresponding to the target storage module to the first cache module from the starting point. When the operation information is a write operation, the transfer operation is the write control The module stores the data from the processor 10 starting from the starting address in the target storage module.

S14、在偵測到檢測指令時,判斷是否接收到中斷指令。 S14, when the detection instruction is detected, determine whether an interrupt instruction is received.

S15、在接收到中斷指令時,判斷當前所述指針對應的位址是否為末位位址。 S15. When receiving the interrupt instruction, determine whether the address corresponding to the current pointer is the last address.

S16、在當前所述指針對應的位址為所述末位位址時,關閉所述記憶體20的輸出功能。 S16 , when the address corresponding to the current pointer is the last address, turn off the output function of the memory 20 .

本發明的至少一個實施例中,藉由控制所述記憶體20的輸出模組211(參見圖4)關閉實現關閉所述記憶體20的輸出功能。 In at least one embodiment of the present invention, the output function of the memory 20 is turned off by controlling the output module 211 (see FIG. 4 ) of the memory 20 to turn off.

在當前所述指針對應的位址不是所述末位位址時,返回步驟S14。 When the address corresponding to the current pointer is not the last address, return to step S14.

在未接收到中斷指令時,返回步驟S13。 When the interrupt command is not received, the process returns to step S13.

本發明的至少一個實施例中,在未接收到中斷指令且所述目標控制模組完成從所述起點至末位位址的傳送後,所述目標控制模組返回目標存儲模組的首位位址繼續進行對應的多段資料段的傳送。 In at least one embodiment of the present invention, after the interrupt instruction is not received and the target control module completes the transmission from the starting point to the last bit address, the target control module returns to the first bit of the target storage module The address continues to transmit the corresponding multi-segment data segment.

上述自動資料傳輸方法,記憶體可自動根據輸入的資料或指令進行資料起始位址的確定以及傳輸操作,減少了資料傳輸對CPU佔用,進而提升在資料傳輸過程中記憶體的回應速度;並在偵測到中斷指令時進一步檢測末位位址,以保證資料傳輸過程中資料的完整性。 In the above-mentioned automatic data transmission method, the memory can automatically determine the starting address of the data and the transmission operation according to the input data or instructions, which reduces the CPU usage of the data transmission, thereby improving the response speed of the memory during the data transmission process; and When the interrupt command is detected, the last bit address is further detected to ensure the integrity of the data during the data transmission.

需要說明的是,對於前述的各方法實施例,為了簡單描述,故將其都表述為一系列的動作組合,但是本領域技術人員應該知悉,本發明並不受所描述的動作順序的限制,因為依據本發明,某些步驟可以採用其他順序或者同時進行。其次,本領域技術人員也應該知悉,說明書中所描述的實施例均屬於優選實施例,所涉及的動作和模組並不一定是本發明所必須的。 It should be noted that, for the sake of simple description, the foregoing method embodiments are all expressed as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence. As in accordance with the present invention, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.

在本申請所提供的幾個實施例中,應該理解到,所揭露的裝置,可藉由其它的方式實現。例如,以上所描述的裝置實施例僅僅是示意性的,例如所述模組的劃分,僅僅為一種邏輯功能劃分,實際實現時可以有另外的劃分方式,例如多個模組或元件可以結合或者可以集成到另一個系統,或一些特徵可以忽略,或不執行。另一點,所顯示或討論的相互之間的耦合或直接耦合或通信連接可以是藉由一些介面,裝置或模組的間接耦合或通信連接,可以是電性或其它的形式。 In the several embodiments provided in this application, it should be understood that the disclosed apparatus may be implemented in other manners. For example, the device embodiments described above are only illustrative. For example, the division of the modules is only a logical function division. In actual implementation, there may be other division methods. For example, multiple modules or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or modules, and may be electrical or other forms.

所述作為分離部件說明的模組可以是或者也可以不是物理上分開的,作為模組顯示的部件可以是或者也可以不是物理模組,即可以位於一個地方,或者也可以分佈到多個網路模組上。可以根據實際的需要選擇其中的部分或者全部模組來實現本實施例方案的目的。 The modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, that is, they may be located in one place, or may be distributed to multiple networks. on the road module. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

另外,在本發明的各個實施例中的各功能模組可以集成在一個處理器中,也可以是各個模組單獨物理存在,也可以兩個或兩個以上模組集成在一個模組中。上述集成的模組既可以採用硬體的形式實現,也可以採用軟體功能模組的形式實現。 In addition, each functional module in each embodiment of the present invention may be integrated into one processor, or each module may exist physically alone, or two or more modules may be integrated into one module. The above-mentioned integrated modules can be implemented in the form of hardware, or can be implemented in the form of software function modules.

所述集成的模組如果以軟體功能模組的形式實現並作為獨立的產品銷售或使用時,可以存儲在一個電腦可讀取存儲介質中。基於這樣的理解,本發明的技術方案本質上或者說對現有技術做出貢獻的部分或者該技術方案的全部或部分可以以軟體產品的形式體現出來,該電腦軟體產品存儲在一個存儲介質中,包括若干指令用以使得一台電腦設備(可為個人電腦、伺服器或者網路設備等)執行本發明各個實施例所述方法的全部或部分步驟。 If the integrated module is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, Several instructions are included to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.

還需要說明的是,在本文中,術語「包括」、「包含」或者其任何其他變體意在涵蓋非排他性的包含,從而使得包括一系列要素的過程、 方法、物品或者裝置不僅包括那些要素,而且還包括沒有明確列出的其他要素,或者是還包括為這種過程、方法、物品或者裝置所固有的要素。在沒有更多限制的情況下,由語句「包括一個......」限定的要素,並不排除在包括該要素的過程、方法、物品或者裝置中還存在另外的相同要素。 It should also be noted that, herein, the terms "comprising", "comprising" or any other variation thereof are intended to encompass a non-exclusive inclusion such that a process including a series of elements, A method, article, or apparatus includes not only those elements, but also other elements not expressly listed, or that are inherent to such a process, method, article, or apparatus. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in a process, method, article or apparatus that includes the element.

以上所述,以上實施例僅用以說明本發明的技術方案,而非對其限制;儘管參照前述實施例對本發明進行了詳細的說明,本領域的普通技術人員應當理解:其依然可以對前述各實施例所記載的技術方案進行修改,或者對其中部分技術特徵進行等同替換;而這些修改或者替換,並不使相應技術方案的本質脫離本發明各實施例技術方案的範圍。 As mentioned above, the above embodiments are only used to illustrate the technical solutions of the present invention, but not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand: The technical solutions described in the embodiments are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

綜上所述,本發明符合發明專利要件,爰依法提出專利申請。惟,以上所述者僅為本發明之較佳實施方式,舉凡熟悉本案技藝之人士,在爰依本案創作精神所作之等效修飾或變化,皆應包含於以下之申請專利範圍內。 To sum up, the present invention complies with the requirements of an invention patent, and a patent application can be filed in accordance with the law. However, the above descriptions are only the preferred embodiments of the present invention, and for those who are familiar with the techniques of this case, equivalent modifications or changes made in accordance with the creative spirit of this case should be included within the scope of the following patent application.

S10-S16:步驟 S10-S16: Steps

Claims (10)

一種自動資料傳輸方法,應用於與處理器進行通訊的記憶體中;所述記憶體包括第一存儲模組和第二存儲模組;其中,所述自動資料傳輸方法包括:在偵測到接收指令時,所述記憶體接收由所述處理器傳送的資料並獲取所述資料的標識資訊;其中,所述資料將所述第一存儲模組和所述第二存儲模組中的一者作為預設存儲模組;所述標識資訊用於標識所述資料的在目標記憶體內是否具有指定的起始位址;在偵測到查詢指令時,所述記憶體根據標識資訊查詢所述資料對應的起始位址;在偵測到設定指令時,將所述資料對應的預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組;在偵測到傳送指令時,控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送;在偵測到檢測指令時,判斷是否接收到中斷指令;在接收到中斷指令時,判斷當前所述指針對應的位址是否為末位位址;在當前所述指針對應的位址為所述末位位址時,關閉所述記憶體的輸出功能。 An automatic data transmission method is applied to a memory that communicates with a processor; the memory includes a first storage module and a second storage module; wherein, the automatic data transmission method When instructed, the memory receives the data transmitted by the processor and obtains the identification information of the data; wherein the data is one of the first storage module and the second storage module As a default storage module; the identification information is used to identify whether the data has a specified starting address in the target memory; when a query command is detected, the memory queries the data according to the identification information The corresponding starting address; when detecting the setting instruction, the preset storage module corresponding to the data is set as the target storage module, and the target control module is set according to the predetermined operation corresponding to the data; When the transmission instruction is detected, the pointer that controls the target control module starts to transmit the multi-segment data segments corresponding to the data from the start address; when the detection instruction is detected, it is judged whether an interrupt instruction is received; When an interrupt instruction is received, it is judged whether the address corresponding to the current pointer is the last address; when the current address corresponding to the pointer is the last address, the output function of the memory is turned off. 如請求項1所述的自動資料傳輸方法,其中,所述標識資訊包括預設標識ID和指定標識ID;所述根據標識資訊查詢所述資料對應的起始位址以及目標記憶體的步驟包括:判斷所述標識資訊是否為所述預設標識ID;在所述標識資訊不是所述預設標識ID時,獲取與所述指定標識ID對應的指定位址作為起始位址; 在所述標識資訊是所述預設標識ID時,獲取與所述預設標識ID對應的預設位址作為起始位址。 The automatic data transmission method according to claim 1, wherein the identification information includes a preset identification ID and a designated identification ID; the step of querying the starting address and target memory corresponding to the data according to the identification information includes the following steps: : determine whether the identification information is the default identification ID; when the identification information is not the default identification ID, obtain the designated address corresponding to the designated identification ID as the starting address; When the identification information is the preset identification ID, a preset address corresponding to the preset identification ID is acquired as a starting address. 如請求項2所述的自動資料傳輸方法,其中,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 The automatic data transmission method according to claim 2, wherein the preset address corresponding to the preset identifier ID is 468, and the designated address corresponding to the designated identifier ID is 476. 如請求項1所述的自動資料傳輸方法,其中,所述將所述資料對應的預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組的步驟包括:將所述資料對應的所述預設存儲模組設定為目標存儲模組;判斷所述預定操作資訊是否為讀取操作;在所述預定操作資訊為讀取操作時,設定所述記憶體內的讀取控制模組作為目標控制模組;在所述預定操作資訊為寫入操作時,設定所述記憶體內的寫入控制模組作為目標控制模組。 The automatic data transmission method according to claim 1, wherein the step of setting a preset storage module corresponding to the data as a target storage module, and setting a target control module according to a predetermined operation corresponding to the data Including: setting the preset storage module corresponding to the data as a target storage module; judging whether the predetermined operation information is a reading operation; when the predetermined operation information is a reading operation, setting the memory The read control module in the body is used as the target control module; when the predetermined operation information is a write operation, the write control module in the memory is set as the target control module. 如請求項1所述的自動資料傳輸方法,其中,在未接收到中斷指令且所述目標控制模組完成從所述起始位址至所述末位位址的傳送後,所述目標控制模組返回目標存儲模組的首位位址繼續進行對應的多段資料段的傳送。 The automatic data transmission method according to claim 1, wherein after the target control module has not received an interrupt command and the target control module completes the transmission from the start address to the end address, the target control The module returns to the first address of the target storage module and continues to transmit the corresponding multi-segment data segment. 一種自動資料傳輸裝置,其中,所述自動資料傳輸裝置包括:處理器;記憶體,接收所述處理器輸出的資料;所述記憶體包括:接收模組,用於在偵測到接收指令時接收由所述處理器傳送的資料並獲取所述資料的標識資訊;其中,所述資料將第一存儲模組和第二存儲模組中的一者作為預設存儲模組;所述標識資訊用於標識所述資料的在目標記憶體內是否具有指定的起始位址; 標識檢測模組,用於在偵測到查詢指令時所述記憶體根據標識資訊查詢所述資料對應的起始位址;所述接收模組進一步地用於在偵測到設定指令時將所述資料對應的所述預設存儲模組設定為目標存儲模組,並根據所述資料對應的預定操作設定目標控制模組;所述接收模組進一步地在偵測到傳送指令時控制所述目標控制模組的指針從所述起始位址開始將所述資料對應的多段資料段進行傳送;所述接收模組進一步地在偵測到檢測指令時判斷是否接收到中斷指令;末位位址檢測模組,用於在接收到中斷指令時判斷當前所述指針對應的位址是否為末位位址;在當前所述指針對應的位址為所述末位位址時,所述末位位址檢測模組關閉所述記憶體的輸出功能。 An automatic data transmission device, wherein the automatic data transmission device comprises: a processor; a memory, for receiving data output by the processor; Receive the data transmitted by the processor and obtain the identification information of the data; wherein, the data uses one of the first storage module and the second storage module as a default storage module; the identification information Whether there is a specified start address in the target memory for identifying the data; The identification detection module is used to query the starting address corresponding to the data according to the identification information when the memory is detected when the query command is detected; the receiving module is further used to detect the setting command The preset storage module corresponding to the data is set as a target storage module, and a target control module is set according to a predetermined operation corresponding to the data; the receiving module further controls the The pointer of the target control module starts to transmit the multi-segment data segments corresponding to the data from the starting address; the receiving module further judges whether an interrupt command is received when detecting the detection command; the last bit The address detection module is used to judge whether the address corresponding to the current pointer is the last address when receiving the interrupt instruction; when the address corresponding to the current pointer is the last address, the last address The bit address detection module turns off the output function of the memory. 如請求項6所述的自動資料傳輸裝置,其中,所述標識資訊包括預設標識ID和指定標識ID;所述標識檢測模組進一步地判斷所述標識資訊是否為所述預設標識ID;在所述標識資訊不是所述預設標識ID時,所述標識檢測模組進一步地獲取與所述指定標識ID對應的指定位址作為起始位址;在所述標識資訊是所述預設標識ID時,所述標識檢測模組進一步地獲取與所述預設標識ID對應的預設位址作為起始位址。 The automatic data transmission device according to claim 6, wherein the identification information includes a preset identification ID and a designated identification ID; the identification detection module further determines whether the identification information is the preset identification ID; When the identification information is not the default identification ID, the identification detection module further acquires a designated address corresponding to the designated identification ID as a starting address; when the identification information is the default identification ID When identifying the ID, the identification detection module further acquires a preset address corresponding to the preset identification ID as a starting address. 如請求項7所述的自動資料傳輸裝置,其中,所述預設標識ID對應的預設位址為468,所述指定標識ID對應的指定位址為476。 The automatic data transmission device according to claim 7, wherein the preset address corresponding to the preset identification ID is 468, and the designated address corresponding to the designated identification ID is 476. 如請求項6所述的自動資料傳輸裝置,其中,所述接收模組進一步地將所述資料對應的所述預設存儲模組設定為目標存儲模組並判斷所述預定操作資訊是否為讀取操作;在所述預定操作資訊為讀取操作時,所述接收模組進一步地設定讀取控制模組作為目標控制模組;在所述預定操 作資訊為寫入操作時,所述接收模組進一步地設定寫入控制模組作為目標控制模組。 The automatic data transmission device according to claim 6, wherein the receiving module further sets the preset storage module corresponding to the data as a target storage module and determines whether the predetermined operation information is read when the predetermined operation information is a reading operation, the receiving module further sets the reading control module as the target control module; in the predetermined operation When the information is a writing operation, the receiving module further sets the writing control module as the target control module. 一種存儲介質,其中,所述存儲介質為電腦可讀存儲介質,存儲有至少一個指令,所述至少一個指令被處理器執行時實現如請求項1至5中任意一項所述自動資料傳輸方法。 A storage medium, wherein the storage medium is a computer-readable storage medium and stores at least one instruction, and when the at least one instruction is executed by a processor, the automatic data transmission method described in any one of request items 1 to 5 is realized .
TW109118356A 2020-06-01 2020-06-01 Data auto-transmitting method, apparatus, and storage medium thereof TWI761846B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW109118356A TWI761846B (en) 2020-06-01 2020-06-01 Data auto-transmitting method, apparatus, and storage medium thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW109118356A TWI761846B (en) 2020-06-01 2020-06-01 Data auto-transmitting method, apparatus, and storage medium thereof

Publications (2)

Publication Number Publication Date
TW202147120A TW202147120A (en) 2021-12-16
TWI761846B true TWI761846B (en) 2022-04-21

Family

ID=80783998

Family Applications (1)

Application Number Title Priority Date Filing Date
TW109118356A TWI761846B (en) 2020-06-01 2020-06-01 Data auto-transmitting method, apparatus, and storage medium thereof

Country Status (1)

Country Link
TW (1) TWI761846B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5535417A (en) * 1993-09-27 1996-07-09 Hitachi America, Inc. On-chip DMA controller with host computer interface employing boot sequencing and address generation schemes
TW502211B (en) * 2000-02-29 2002-09-11 Virata Ltd Method and apparatus for DMA data transfer
US7457896B1 (en) * 1999-08-25 2008-11-25 Seagate Technology Llc Automated register data transfer to reduce processing burden on a processing device
CN101556565A (en) * 2009-01-22 2009-10-14 杭州中天微系统有限公司 High performance DMA on embedded type processor chip
TWI582609B (en) * 2014-09-02 2017-05-11 英特爾股份有限公司 Method and apparatus for performing remote memory access(rma) data transfers between a remote node and a local node

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5535417A (en) * 1993-09-27 1996-07-09 Hitachi America, Inc. On-chip DMA controller with host computer interface employing boot sequencing and address generation schemes
US7457896B1 (en) * 1999-08-25 2008-11-25 Seagate Technology Llc Automated register data transfer to reduce processing burden on a processing device
TW502211B (en) * 2000-02-29 2002-09-11 Virata Ltd Method and apparatus for DMA data transfer
CN101556565A (en) * 2009-01-22 2009-10-14 杭州中天微系统有限公司 High performance DMA on embedded type processor chip
TWI582609B (en) * 2014-09-02 2017-05-11 英特爾股份有限公司 Method and apparatus for performing remote memory access(rma) data transfers between a remote node and a local node

Also Published As

Publication number Publication date
TW202147120A (en) 2021-12-16

Similar Documents

Publication Publication Date Title
CN107181858B (en) Method and terminal for displaying notification message
US11310066B2 (en) Method and apparatus for pushing information
WO2015035842A1 (en) Application control method, terminal device and remote control system
CN102968338A (en) Method and device for classifying application program of electronic equipment and electronic equipment
WO2020113941A1 (en) Data access method, apparatus and system based on mining computer, and readable storage medium
JP6153919B2 (en) Method and apparatus for processing input information
US20170289243A1 (en) Domain name resolution method and electronic device
CN110244963B (en) Data updating method and device and terminal equipment
KR101023631B1 (en) Usb interrupt endpoint sharing
US20230412742A1 (en) Apparatus, method, and system for monitoring image-forming apparatus, and storage medium
WO2020168763A1 (en) Data classification and storage method and apparatus of application program, device, and storage medium
TWI761846B (en) Data auto-transmitting method, apparatus, and storage medium thereof
WO2020097873A1 (en) Floating window control method and related product
TWI649981B (en) Wireless communication device and method for communication matching thereof
CN109271266B (en) File transmission method and device and terminal equipment
CN108536512B (en) Interface switching method and device and terminal equipment
US20140297953A1 (en) Removable Storage Device Identity and Configuration Information
CN112100092A (en) Information caching method, device, equipment and medium
CN113486025B (en) Data storage method, data query method and device
CN110245016B (en) Data processing method, system, device and terminal equipment
CN109558387B (en) Method and device for processing identity card number, storage medium and terminal
CN113760793A (en) Automatic data transmission method, device and storage medium
TWI758778B (en) Data read-write processing method, apparatus, and computer readable storage medium thereof
CN110874723A (en) Electronic red packet detection method, electronic red packet detection device and mobile terminal
US11663335B2 (en) Anti-virus chip and anti-virus method