CN110505655A - Data command processing method, storage medium and bluetooth shield - Google Patents

Data command processing method, storage medium and bluetooth shield Download PDF

Info

Publication number
CN110505655A
CN110505655A CN201811049384.0A CN201811049384A CN110505655A CN 110505655 A CN110505655 A CN 110505655A CN 201811049384 A CN201811049384 A CN 201811049384A CN 110505655 A CN110505655 A CN 110505655A
Authority
CN
China
Prior art keywords
data
data command
command
mobile terminal
processing
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
CN201811049384.0A
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.)
Shenzhen Excelsecu Data Technology Co Ltd
Original Assignee
Shenzhen Excelsecu Data 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 Shenzhen Excelsecu Data Technology Co Ltd filed Critical Shenzhen Excelsecu Data Technology Co Ltd
Priority to CN201811049384.0A priority Critical patent/CN110505655A/en
Publication of CN110505655A publication Critical patent/CN110505655A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/04Protocols for data compression, e.g. ROHC
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W28/00Network traffic management; Network resource management
    • H04W28/02Traffic management, e.g. flow control or congestion control
    • H04W28/06Optimizing the usage of the radio link, e.g. header compression, information sizing, discarding information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The present invention is suitable for field of communication technology, provides a kind of data command processing method, storage medium and bluetooth shield.This method comprises: receiving the first data command that user sends;When first data command meets the first preset condition, first data command is subjected to compression processing, obtains the second data command;Second data command is sent to target terminal equipment, so that the target terminal equipment unzips it processing to second data command;Receive the first response data generated based on the second data command after decompression that the target terminal equipment returns.The present invention can reduce the data interaction time between mobile terminal and target terminal equipment, and mobile terminal and target terminal equipment is made to complete data interaction before the deadline.

Description

Data command processing method, storage medium and bluetooth shield
Technical field
The invention belongs to field of communication technology more particularly to a kind of data command processing methods, storage medium and bluetooth shield.
Background technique
U-shield is a kind of equipment of offer safety identification authentication mechanism, is widely used in e-payment field.Bluetooth shield be Equipment made of being improved on the basis of U-shield, it can be understood as be a kind of U-shield for having Bluetooth function.Low-power consumption bluetooth shield is embedded Low-power consumption bluetooth chip has the advantages such as fast, the at low cost, super low-power consumption of connection speed.But the transmission of low-power consumption bluetooth shield is fast Rate is relatively low.Since the data interaction between mobile terminal and bluetooth shield has stringent time requirement, low-power consumption bluetooth shield is difficult to The data interaction between mobile terminal is completed in the desired time.
Summary of the invention
In view of this, the embodiment of the invention provides a kind of data command processing method, storage medium and bluetooth shield, with solution Certainly low-power consumption bluetooth shield is difficult to the problem of completing the data interaction between mobile terminal in the desired time in the prior art.
The first aspect of the embodiment of the present invention provides a kind of data command processing method, is applied to mobile terminal, described Method includes:
Receive the first data command that user sends;
When first data command meets the first preset condition, first data command is subjected to compression processing, Obtain the second data command;
Second data command is sent to target terminal equipment, so that the target terminal equipment is to described second Data command unzips it processing;
Receive the first number of responses generated based on the second data command after decompression that the target terminal equipment returns According to.
The second aspect of the embodiment of the present invention provides a kind of data command processing method, which comprises
Receive the second data command that mobile terminal is sent;Second data command is that the mobile terminal receives user After the first data command sent, when first data command meets the first preset condition, by first data command Carry out what compression processing obtained;
Second data command is unziped it into processing, and generates second according to the second data command after decompression Response data;
Second response data is subjected to compression processing, obtains the first response data, and by first response data It is sent to the mobile terminal.
The third aspect of the embodiment of the present invention provides a kind of mobile terminal, including memory, processor and is stored in In the memory and the computer program that can run on the processor, when the processor executes the computer program It realizes such as the step of first aspect of embodiment of the present invention the method.
The fourth aspect of the embodiment of the present invention provides a kind of terminal device, including memory, processor and is stored in In the memory and the computer program that can run on the processor, when the processor executes the computer program It realizes such as the step of second aspect of embodiment of the present invention the method.
5th aspect of the embodiment of the present invention provides a kind of computer readable storage medium, the computer-readable storage Media storage has computer program, which is characterized in that realizes that the present invention such as is implemented when the computer program is executed by processor The step of example first aspect the method;Alternatively, realizing such as the embodiment of the present invention when computer program is executed by processor The step of second aspect the method.
6th aspect of the embodiment of the present invention provides a kind of bluetooth shield, including Bluetooth chip and safety chip;
The Bluetooth chip is used to receive the second data command of mobile terminal transmission;Second data command is described It, will when first data command meets the first preset condition after mobile terminal receives the first data command that user sends First data command carries out what compression processing obtained;
The Bluetooth chip is also used to unzip it second data command processing, and by second after decompression Data command is sent to the safety chip;
The safety chip is used to generate the second response data according to the second data command after decompression, and by institute It states the second response data and is sent to the Bluetooth chip;
The Bluetooth chip is also used to second response data carrying out compression processing, obtains the first response data, and First response data is sent to the mobile terminal.
Existing beneficial effect is the embodiment of the present invention compared with prior art: the embodiment of the present invention is by by the first data Instruction retransmits the number that can reduce between mobile terminal and target terminal equipment to target terminal equipment after carrying out compression processing According to interaction time, mobile terminal and target terminal equipment is made to complete data interaction before the deadline.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to embodiment or description of the prior art Needed in attached drawing be briefly described, it should be apparent that, the accompanying drawings in the following description is only of the invention some Embodiment for those of ordinary skill in the art without any creative labor, can also be according to these Attached drawing obtains other attached drawings.
Fig. 1 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention one provides;
Fig. 2 is the implementation process schematic diagram of data command processing method provided by Embodiment 2 of the present invention;
Fig. 3 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention three provides;
Fig. 4 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention four provides;
Fig. 5 is the interaction flow schematic diagram for the data command processing method that the embodiment of the present invention five provides;
Fig. 6 is the schematic diagram for the mobile terminal that the embodiment of the present invention six provides;
Fig. 7 is the schematic diagram for the terminal device that the embodiment of the present invention seven provides;
Fig. 8 is the schematic diagram for the mobile terminal that the embodiment of the present invention eight provides;
Fig. 9 is the schematic diagram for the terminal device that the embodiment of the present invention nine provides;
Figure 10 is the schematic diagram for the bluetooth shield that the embodiment of the present invention ten provides.
Specific embodiment
In being described below, for illustration and not for limitation, the tool of such as particular system structure, technology etc is proposed Body details, to understand thoroughly the embodiment of the present invention.However, it will be clear to one skilled in the art that there is no these specific The present invention also may be implemented in the other embodiments of details.In other situations, it omits to well-known system, device, electricity The detailed description of road and method, in case unnecessary details interferes description of the invention.
In order to illustrate technical solutions according to the invention, the following is a description of specific embodiments.
Embodiment one
Referring to FIG. 1, Fig. 1 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention one provides, This method is applied to mobile terminal, comprising the following steps:
Step S101 receives the first data command that user sends.
In embodiments of the present invention, the first data command includes but is not limited to cipher instruction, confirmation instruction etc..User is moving Dynamic terminal inputs the first data command.
Step S102 carries out first data command when first data command meets the first preset condition Compression processing obtains the second data command.
In embodiments of the present invention, after mobile terminal receives the first data command, judge whether the first data command is full First data command is carried out compression processing, obtained by the first preset condition of foot when the first data command meets the first preset condition To the second data command, when the first data command is unsatisfactory for the first preset condition, the first data command is sent directly to mesh Mark terminal device.In one embodiment, mobile terminal judges whether the byte length of the first data command is greater than the first default threshold Value carries out compression processing to the first data command, specifically when the byte length of the first data command is greater than the first preset value , the lead data and/or redundancy in the first data command are removed, for example, there are identical in the first data command When data, only retain a copy of the data.By compression processing, the byte length of the first data command is decreased below Or it is equal to the first preset threshold.
Second data command is sent to target terminal equipment by step S103, so that the target terminal equipment Processing is unziped it to second data command.
In embodiments of the present invention, mobile terminal and target terminal equipment establish communication link, realize data interaction.Target Terminal device includes but is not limited to U-shield, bluetooth shield and other equipment for needing to carry out data interaction with mobile terminal.Mobile terminal Second data command is sent to target terminal equipment, target terminal equipment unzips it processing to the second data command, and The first response data is generated according to the second data command after decompression, the first response data is sent to mobile terminal.
Step S104, the generated based on the second data command after decompression for receiving that the target terminal equipment returns One response data.
In embodiments of the present invention, mobile terminal receives the first response data that target terminal equipment returns, completion and mesh Mark the data interaction between terminal device.
In embodiments of the present invention, when the first data command is unsatisfactory for preset condition, mobile terminal refers to the first data Order is sent to target terminal equipment, and receives the third number of responses of target terminal equipment return generated based on the first data command According to.
Optionally, further includes: when first response data meets the second preset condition, to second response data Unzip it processing.
In embodiments of the present invention, mobile terminal judges whether the first response data meets the second preset condition, is judging When first response data meets the second preset condition, processing is unziped it to the first response data.In a kind of implementation, move Dynamic terminal judges whether the first response data carries second identifier information, carries second identifier information in first response data When, processing is unziped it to the first response data.
It is full in the first data command after mobile terminal receives the first data command that user sends in the embodiment of the present invention When the first preset condition of foot, compression processing is carried out to the first data command, obtains the second data command, and by the second data command Be sent to target terminal equipment, target terminal equipment unzips it processing to the second data command, and based on decompression after Second data command generates the first response data, and the first response data is sent to mobile terminal.The embodiment of the present invention pass through by First data command retransmits after carrying out compression processing to target terminal equipment, can reduce mobile terminal and target terminal equipment Between the data interaction time, so that mobile terminal and target terminal equipment is completed data interaction before the deadline.
Embodiment two
Referring to FIG. 2, Fig. 2 is the implementation process schematic diagram of data command processing method provided by Embodiment 2 of the present invention, Method includes the following steps:
Step S201 receives the first data command that user sends.
In embodiments of the present invention, the first data command includes but is not limited to cipher instruction, confirmation instruction etc..User is moving Dynamic terminal inputs the first data command.
Step S202, when the byte length of first data command is greater than the first preset threshold, removal described first Lead data and/or redundancy in data command, obtain the second data command.
In embodiments of the present invention, mobile terminal judges whether the byte length of the first data command is greater than the first default threshold Value, the first data command byte length be greater than the first preset threshold when, remove the first data command in lead data and/ Or redundancy, the byte length of the first data command is reduced to less than or equal to the first preset threshold.For example, the first data When the byte length of instruction is greater than 20 byte, when removing identical data in the first data command, only retain one of the data Copy.
Step S203 adds first identifier information to second data command, will add the after first identifier information Two data commands are sent to target terminal equipment, so that the target terminal equipment judges need according to the first identifier information When unziping it processing to received second data command, then processing is unziped it to second data command.
In embodiments of the present invention, after adding first identifier information to the second data command, it is sent to target terminal equipment, When the second data command that the judgement of target terminal equipment receives carries first identifier information, the second data command is decompressed Contracting processing, specifically, restoring the lead data and/or redundancy in the second data command.
Step S204, the generated based on the second data command after decompression for receiving that the target terminal equipment returns One response data.
In embodiments of the present invention, after target terminal is to the second data command decompression, according to after decompression Two data commands generate the first response data, and the first response data is sent to mobile terminal, and mobile terminal receives the first sound Answer data.
Step S205 carries out first response data when first response data meets the second preset condition Decompression.
In embodiments of the present invention, after mobile terminal receives the first response data, judge whether the first response data meets Second preset condition unzips it processing to the first response data when the first response data meets the second preset condition.One In kind implementation, mobile terminal judges whether the first response data carries second identifier information, in first response data When carrying second identifier information, processing is unziped it to the first response data, during restoring the first response data of compression, is gone The lead data and/or redundancy removed.
It is full in the first data command after mobile terminal receives the first data command that user sends in the embodiment of the present invention When the first preset condition of foot, compression processing is carried out to the first data command, obtains the second data command, and by the second data command Be sent to target terminal equipment, target terminal equipment unzips it processing to the second data command, and based on decompression after Second data command generates the first response data, and the first response data is sent to mobile terminal.The embodiment of the present invention pass through by First data command retransmits after carrying out compression processing to target terminal equipment, can reduce mobile terminal and target terminal equipment Between the data interaction time, so that mobile terminal and target terminal equipment is completed data interaction before the deadline.
Embodiment three
Referring to FIG. 3, Fig. 3 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention three provides, Method includes the following steps:
Step S301 receives the second data command that mobile terminal is sent;Second data command is described mobile whole After end receives the first data command that user sends, when first data command meets the first preset condition, by described the One data command carries out what compression processing obtained.
In embodiments of the present invention, after mobile terminal receives the first data command that user sends, judge the first data Whether instruction meets the first preset condition, and when the first data command meets the first preset condition, the first data command is carried out Compression processing obtains the second data command, and the second data command is sent to target terminal equipment, and target terminal equipment receives Second data command.
Second data command is unziped it processing, and is referred to according to the second data after decompression by step S302 It enables and generates the second response data.
In embodiments of the present invention, the second data command is unziped it processing by target terminal equipment.A kind of realization side In formula, target terminal equipment judges whether the second data command carries first identifier information, carries first in the second data command When identification information, processing is unziped it to the second data command.After decompression, target terminal equipment according to decompression at The second data command after reason generates the second response data.
Second response data is carried out compression processing, obtains the first response data by step S303, and by described first Response data is sent to the mobile terminal.
In embodiments of the present invention, the second response data is carried out compression processing by target terminal, obtains the first response data, First response data is sent to mobile terminal, mobile terminal unzips it processing to the first response data.
In embodiments of the present invention, when the first data command is unsatisfactory for preset condition, target terminal equipment receives movement The first data command that terminal is sent, and third response data is generated according to the first data command, third response data is direct It is sent to mobile terminal, without compression processing.
It is full in the first data command after mobile terminal receives the first data command that user sends in the embodiment of the present invention When the first preset condition of foot, compression processing is carried out to the first data command, obtains the second data command, and by the second data command Be sent to target terminal equipment, target terminal equipment unzips it processing to the second data command, and based on decompression after Second data command generates the second response data, and second response data is carried out compression processing, obtains the first response data, First response data is sent to mobile terminal.The embodiment of the present invention is carried out the first data command at compression by mobile terminal It is retransmited after reason to target terminal equipment, target terminal equipment is sent to shifting after the second response data is instructed progress compression processing Dynamic terminal, can reduce the data interaction time between mobile terminal and target terminal, makes mobile terminal and target terminal equipment Data interaction is completed before the deadline.
Example IV
Referring to FIG. 4, Fig. 4 is the implementation process schematic diagram for the data command processing method that the embodiment of the present invention four provides, Method includes the following steps:
Step S401 receives the second data command that mobile terminal is sent;Second data command is described mobile whole After end receives the first data command that user sends, when first data command meets the first preset condition, by described the One data command carries out what compression processing obtained.
Second data command is unziped it processing, and is referred to according to the second data after decompression by step S402 It enables and generates the second response data.
In embodiments of the present invention, the step in the implementation of step S401 to step S402 and the embodiment of the present invention three The implementation of S301 to step S302 are identical, and the embodiment of the present invention repeats no more.
Step S403, when the byte length of second response data is greater than the second preset threshold, removal described second Lead data and/or redundancy in response data, obtain the first response data.
In embodiments of the present invention, it is pre- to judge whether the byte length of the second response data is greater than second for target terminal equipment If threshold value, when the byte length of the second response data is greater than the second preset threshold, the number of derivatives in the second response data are removed According to and/or redundancy, the byte length of the second response data is reduced to less than or equal to the second preset threshold.For example, the When the byte length of two response datas is greater than 20 byte, in the second response data when identical data, only retain the one of the data A copy.
Step S404 adds second identifier information to first response data, will add the after second identifier information One response data is sent to the mobile terminal, so that the mobile terminal judges whether need according to the second identifier information Processing is unziped it to received first response data.
In embodiments of the present invention, after adding second identifier information to the first response data, it is sent to mobile terminal, it is mobile When terminal judges that the first response data carries second identifier information, then processing is unziped it to the first response data, specifically, Restore the lead data and redundancy in the first response data.
It is full in the first data command after mobile terminal receives the first data command that user sends in the embodiment of the present invention When the first preset condition of foot, compression processing is carried out to the first data command, obtains the second data command, and by the second data command Be sent to target terminal equipment, target terminal equipment unzips it processing to the second data command, and based on decompression after Second data command generates the second response data, and second response data is carried out compression processing, obtains the first response data, First response data is sent to mobile terminal.The embodiment of the present invention is carried out the first data command at compression by mobile terminal It is retransmited after reason to target terminal equipment, target terminal equipment is sent to shifting after the second response data is instructed progress compression processing Dynamic terminal, can reduce the data interaction time between mobile terminal and target terminal, makes mobile terminal and target terminal equipment Data interaction is completed before the deadline.
Embodiment five
Referring to FIG. 5, Fig. 5 is the interaction flow schematic diagram for the data command processing method that the embodiment of the present invention five provides, The executing subject for participating in the interaction flow mainly includes mobile terminal 51 and target terminal equipment 52, and the realization of the interaction flow is former Reason is identical as the implementation method of principle described in embodiment one to example IV, only briefly describes the interaction flow, does not repeat:
Step S501, mobile terminal receives the first data command that user sends, and meets in first data command When the first preset condition, first data command is subjected to compression processing, obtains the second data command.
Second data command is sent to target terminal equipment by step S502, mobile terminal.
Step S503, target terminal equipment unzip it processing to the second data command, according to second after decompression Data command generates the second response data, and carries out compression processing to the second response data, obtains the first response data.
First response data is sent to mobile terminal by step S504, target terminal equipment.
Step S505, mobile terminal unzip it processing to the first response data.
It should be understood that the size of the serial number of each step is not meant that the order of the execution order in above-described embodiment, each process Execution sequence should be determined by its function and internal logic, the implementation process without coping with the embodiment of the present invention constitutes any limit It is fixed.
Embodiment six
Referring to FIG. 6, Fig. 6 is the schematic diagram for the mobile terminal that the embodiment of the present invention six provides, mobile terminal 6 includes: the One receiving module 601, the first compression module 602, the first sending module 603 and the second receiving module 604.Each module concrete function It is as follows:
First receiving module 601, for receiving the first data command of user's transmission;
First compression module 602, for when first data command meets the first preset condition, described first to be counted Compression processing is carried out according to instruction, obtains the second data command;
First sending module 603, for second data command to be sent to target terminal equipment, so that the mesh Mark terminal device unzips it processing to second data command;
Second receiving module 604, for receiving that the target terminal equipment returns based on the second data after decompression Instruct the first response data generated.
Optionally, it is pre- to be greater than first for the byte length in first data command for first compression module 602 If when threshold value, removing the lead data and/or redundancy in first data command, obtaining the second data command.
Optionally, further includes:
First adding module, for adding first identifier information to second data command;
Optionally, first sending module 603 is sent for that will add the second data command after first identifier information To target terminal equipment, so that the target terminal equipment is needed according to first identifier information judgement to received second When data command unzips it processing, then processing is unziped it to second data command.
Optionally, further includes:
First decompression module is used for when first response data meets the second preset condition, to first sound Data are answered to unzip it processing.
In the embodiment of the present invention, after the first receiving module 601 of mobile terminal receives the first data command that user sends, First compression module 602 carries out compression processing when the first data command meets the first preset condition, to the first data command, obtains To the second data command, the second data command is sent to target terminal equipment, target terminal equipment pair by the first sending module 603 Second data command unzips it processing, and generates the first response data based on the second data command after decompression, by the One response data is sent to mobile terminal, and the second receiving module 604 receives the first response data.The embodiment of the present invention is by by One data command retransmits after carrying out compression processing to target terminal equipment, can reduce mobile terminal and target terminal equipment it Between the data interaction time, so that mobile terminal and target terminal equipment is completed data interaction before the deadline.
Implement seven
Referring to FIG. 7, Fig. 7 is the schematic diagram for the terminal device that the embodiment of the present invention seven provides, terminal device 7 includes: the Three receiving modules 701, the second decompression module 702 and the second compression module 703, each module concrete function are as follows:
Third receiving module 701, for receiving the second data command of mobile terminal transmission;Second data command is After the mobile terminal receives the first data command that user sends, meet the first preset condition in first data command When, first data command progress compression processing is obtained;
Second decompression module 702, for second data command to be unziped it processing, and according to decompression after The second data command generate the second response data;
Second compression module 703, for obtaining the first response data for second response data progress compression processing, And first response data is sent to the mobile terminal.
Optionally, the second compression module 703 is greater than the second default threshold for the byte length in second response data When value, the lead data and/or redundancy in second response data are removed, obtains the first response data, and will be described First response data is sent to the mobile terminal.
It optionally, further include the first adding module, for adding second identifier information to first response data;
Optionally, the second compression module 703 is sent to institute for that will add the first response data after second identifier information Mobile terminal is stated, so that the mobile terminal judges whether to need to received first response according to the second identifier information Data unzip it processing.
It is full in the first data command after mobile terminal receives the first data command that user sends in the embodiment of the present invention When the first preset condition of foot, compression processing is carried out to the first data command, obtains the second data command, and by the second data command It is sent to target terminal equipment, the third receiving module 701 of target terminal equipment receives the second data command, the second decompression mould Block 702 unzips it processing to the second data command, and generates the second number of responses based on the second data command after decompression According to second response data is carried out compression processing by the second compression module 703, the first response data is obtained, by the first response Data are sent to mobile terminal.The embodiment of the present invention retransmits after the first data command is carried out compression processing by mobile terminal To target terminal equipment, target terminal equipment is sent to mobile terminal, energy after the second response data is instructed progress compression processing The data interaction time between mobile terminal and target terminal is enough reduced, makes mobile terminal and target terminal equipment when defined Interior completion data interaction.
Embodiment eight
Fig. 8 is the schematic diagram for the mobile terminal that the embodiment of the present invention eight provides.As shown in figure 8, the mobile end of the embodiment End 8 includes: processor 801, memory 802 and is stored in the memory 802 and can run on the processor 801 Computer program 803.The processor 801 realizes above-mentioned each data command processing when executing the computer program 803 Step in embodiment of the method, such as step S101 to S104 shown in FIG. 1.Alternatively, the processor 801 executes the calculating The function of each module/unit in above-mentioned each Installation practice, such as module 701 to 704 shown in Fig. 8 are realized when machine program 803 Function.
Illustratively, the computer program 803 can be divided into one or more module/units, it is one or Multiple module/the units of person are stored in the memory 802, and are executed by the processor 801, to complete the present invention.Institute Stating one or more module/units can be the series of computation machine program instruction section that can complete specific function, the instruction segment For describing implementation procedure of the computer program 803 in the mobile terminal 8.For example, the computer program 803 can To be divided into the first receiving module, the first compression module, the first sending module and the second receiving module.Each module concrete function It is as follows:
First receiving module, for receiving the first data command of user's transmission;
First compression module is used for when first data command meets the first preset condition, by first data Instruction carries out compression processing, obtains the second data command;
First sending module, for second data command to be sent to target terminal equipment, so that the target Terminal device unzips it processing to second data command;
Second receiving module, for receiving that the target terminal equipment returns based on the second data command after decompression The first response data generated.
Optionally, it is default to be greater than first for the byte length in first data command for first compression module When threshold value, the lead data and/or redundancy in first data command are removed, the second data command is obtained.
Optionally, further includes:
First adding module, for adding first identifier information to second data command;
Optionally, first sending module is sent to for that will add the second data command after first identifier information Target terminal equipment, so that the target terminal equipment is needed according to first identifier information judgement to received second number When unziping it processing according to instruction, then processing is unziped it to second data command.
Optionally, further includes:
Decompression module is used for when first response data meets the second preset condition, to first number of responses It is handled according to unziping it.
The mobile terminal 8 can be the calculating such as desktop PC, notebook, palm PC and cloud server and set It is standby.The mobile terminal may include, but be not limited only to, processor 801, memory 802.It will be understood by those skilled in the art that Fig. 8 is only the example of mobile terminal 8, does not constitute the restriction to mobile terminal 8, may include more more or fewer than illustrating Component, perhaps combines certain components or different components, for example, the mobile terminal 8 can also include input-output equipment, Network access equipment, bus etc..
Alleged processor 801 can be central processing unit (Central Processing Unit, CPU), can also be Other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor Deng.
The memory 802 can be the internal storage unit of the mobile terminal 8, for example, mobile terminal 8 hard disk or Memory.The memory 802 is also possible to the External memory equipment of the mobile terminal 8, such as is equipped on the mobile terminal 8 Plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, Flash card (Flash Card) etc..Further, the memory 802 can also have been deposited both the inside including the mobile terminal 8 Storage unit also includes External memory equipment.The memory 802 is for storing the computer program and the mobile terminal Other required programs and data.The memory 802, which can be also used for temporarily storing, have been exported or will export Data.
Embodiment nine
Fig. 9 is the schematic diagram for the terminal device that the embodiment of the present invention nine provides.As shown in figure 9, the terminal of the embodiment is set Standby 9 include: processor 901, memory 902 and are stored in the memory 902 and can run on the processor 901 Computer program 903.The processor 901 realizes above-mentioned each data command processing when executing the computer program 903 Step in embodiment of the method, such as step S301 to S303 shown in Fig. 3.Alternatively, the processor 901 executes the calculating The function of each module/unit in above-mentioned each Installation practice, such as module 701 to 703 shown in Fig. 7 are realized when machine program 903 Function.
Illustratively, the computer program 903 can be divided into one or more module/units, it is one or Multiple module/the units of person are stored in the memory 902, and are executed by the processor 901, to complete the present invention.Institute Stating one or more module/units can be the series of computation machine program instruction section that can complete specific function, the instruction segment For describing implementation procedure of the computer program 903 in the terminal device 9.For example, the computer program 903 can To be divided into third receiving module, the second decompression module and the second compression module, each module concrete function is as follows:
Third receiving module, for receiving the second data command of mobile terminal transmission;Second data command is institute After stating the first data command that mobile terminal receives user's transmission, when first data command meets the first preset condition, First data command progress compression processing is obtained;
Second decompression module, for second data command to be unziped it processing, and according to decompression after Second data command generates the second response data;
Second compression module obtains the first response data, and will for second response data to be carried out compression processing First response data is sent to the mobile terminal.
Optionally, the second compression module is greater than the second preset threshold for the byte length in second response data When, the lead data and/or redundancy in second response data are removed, obtains the first response data, and by described the One response data is sent to the mobile terminal.
It optionally, further include the first adding module, for adding second identifier information to first response data;
Optionally, the second compression module, for will add the first response data after second identifier information be sent to it is described Mobile terminal, so that the mobile terminal judges whether to need to received first number of responses according to the second identifier information It is handled according to unziping it.
The terminal device 9 can be the calculating such as desktop PC, notebook, palm PC and cloud server and set It is standby.The terminal device may include, but be not limited only to, processor 901, memory 902.It will be understood by those skilled in the art that Fig. 9 is only the example of terminal device 9, does not constitute the restriction to terminal device 9, may include more more or fewer than illustrating Component, perhaps combines certain components or different components, for example, the terminal device can also include input-output equipment, Network access equipment, bus etc..
Alleged processor 901 can be central processing unit (Central Processing Unit, CPU), can also be Other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor Deng.
The memory 902 can be the internal storage unit of the terminal device 9, for example, terminal device 9 hard disk or Memory.The memory 902 is also possible to the External memory equipment of the terminal device 9, such as is equipped on the terminal device 9 Plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, Flash card (Flash Card) etc..Further, the memory 902 can also have been deposited both the inside including the terminal device 9 Storage unit also includes External memory equipment.The memory 902 is for storing the computer program and the terminal device Other required programs and data.The memory 902, which can be also used for temporarily storing, have been exported or will export Data.
Embodiment ten
Referring to FIG. 10, Figure 10 is the schematic diagram for the bluetooth shield that the embodiment of the present invention ten provides, bluetooth shield 10 includes bluetooth Chip 1001 and safety chip 1002.
The Bluetooth chip 1001 is used to receive the second data command of mobile terminal transmission;Second data command is After the mobile terminal receives the first data command that user sends, meet the first preset condition in first data command When, first data command progress compression processing is obtained;
The Bluetooth chip 1001 is also used to unziping it second data command into processing, and will be after decompression Second data command is sent to the safety chip 1002;
The safety chip 1002 is used to generate the second response data according to the second data command after decompression, and Second response data is sent to the Bluetooth chip 1001;
The Bluetooth chip 1001 is also used to second response data carrying out compression processing, obtains the first number of responses According to, and first response data is sent to the mobile terminal.
Optionally, the Bluetooth chip 1001 is used to be greater than the second default threshold in the byte length of second response data When value, the lead data and/or redundancy in second response data are removed, the first response data is obtained.
Optionally, the Bluetooth chip 1001 is also used to add the first response data after second identifier information and is sent to The mobile terminal, so that the mobile terminal judges whether to need to received first sound according to the second identifier information Data are answered to unzip it processing.
Bluetooth chip 1001 in the embodiment of the present invention is low-power consumption bluetooth chip.In the embodiment of the present invention, mobile terminal After receiving the first data command that user sends, when the first data command meets the first preset condition, to the first data command Compression processing is carried out, obtains the second data command, and the second data command is sent to Bluetooth chip 1001, Bluetooth chip 1001 Processing is unziped it to the second data command, and the second data command after decompression is sent to safety chip 1002, is pacified Full chip 1002 generates the second response data based on the second data command after decompression, and the second response data is sent to bluetooth Second response data is carried out compression processing, the first response data is obtained, by the first sound by chip 1001, Bluetooth chip 1001 Data are answered to be sent to mobile terminal.The embodiment of the present invention is sent out again after the first data command is carried out compression processing by mobile terminal It sending to Bluetooth chip 1001, Bluetooth chip 1001 is sent to mobile terminal after second response data is instructed progress compression processing, It can reduce the data interaction time between mobile terminal and bluetooth shield, keep mobile terminal and bluetooth shield complete before the deadline At data interaction.
It is apparent to those skilled in the art that for convenience of description and succinctly, only with above-mentioned each function Can unit, module division progress for example, in practical application, can according to need and by above-mentioned function distribution by different Functional unit, module are completed, i.e., the internal structure of described device is divided into different functional unit or module, more than completing The all or part of function of description.Each functional unit in embodiment, module can integrate in one processing unit, can also To be that each unit physically exists alone, can also be integrated in one unit with two or more units, it is above-mentioned integrated Unit both can take the form of hardware realization, can also realize in the form of software functional units.In addition, each function list Member, the specific name of module are also only for convenience of distinguishing each other, the protection scope being not intended to limit this application.Above system The specific work process of middle unit, module, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, is not described in detail or remembers in some embodiment The part of load may refer to the associated description of other embodiments.
Those of ordinary skill in the art may be aware that list described in conjunction with the examples disclosed in the embodiments of the present disclosure Member and algorithm steps can be realized with the combination of electronic hardware or computer software and electronic hardware.These functions are actually It is implemented in hardware or software, the specific application and design constraint depending on technical solution.Professional technician Each specific application can be used different methods to achieve the described function, but this realization is it is not considered that exceed The scope of the present invention.
In embodiment provided by the present invention, it should be understood that disclosed device/terminal device and method, it can be with It realizes by another way.For example, device described above/terminal device embodiment is only schematical, for example, institute The division of module or unit is stated, only a kind of logical function partition, there may be another division manner in actual implementation, such as Multiple units or components can be combined or can be integrated into another system, or some features can be ignored or not executed.Separately A bit, shown or discussed mutual coupling or direct-coupling or communication connection can be through some interfaces, device Or the INDIRECT COUPLING or communication connection of unit, it can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme 's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated module/unit be realized in the form of SFU software functional unit and as independent product sale or In use, can store in a computer readable storage medium.Based on this understanding, the present invention realizes above-mentioned implementation All or part of the process in example method, can also instruct relevant hardware to complete, the meter by computer program Calculation machine program can be stored in a computer readable storage medium, the computer program when being executed by processor, it can be achieved that on The step of stating each embodiment of the method.Wherein, the computer program includes computer program code, the computer program generation Code can be source code form, object identification code form, executable file or certain intermediate forms etc..The computer-readable medium It may include: any entity or device, recording medium, USB flash disk, mobile hard disk, magnetic that can carry the computer program code Dish, CD, computer storage, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium etc..It should be noted that described The content that computer-readable medium includes can carry out increasing appropriate according to the requirement made laws in jurisdiction with patent practice Subtract, such as does not include electric carrier signal and electricity according to legislation and patent practice, computer-readable medium in certain jurisdictions Believe signal.
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although referring to aforementioned reality Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features;And these are modified Or replacement, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution should all It is included within protection scope of the present invention.

Claims (11)

1. a kind of data command processing method, which is characterized in that be applied to mobile terminal, which comprises
Receive the first data command that user sends;
When first data command meets the first preset condition, first data command is subjected to compression processing, is obtained Second data command;
Second data command is sent to target terminal equipment, so that the target terminal equipment is to second data Instruction unzips it processing;
Receive the first response data generated based on the second data command after decompression that the target terminal equipment returns.
2. data command processing method as described in claim 1, which is characterized in that described to meet in first data command When the first preset condition, first data command is subjected to compression processing, comprising:
When the byte length of first data command is greater than the first preset threshold, before removing in first data command Derivative evidence and/or redundancy.
3. data command processing method as described in claim 1, which is characterized in that further include:
First identifier information is added to second data command;
It is described that second data command is sent to target terminal equipment, so that the target terminal equipment is to described second Data command unzips it processing, comprising:
The second data command after addition first identifier information is sent to target terminal equipment, so that the target terminal is set It is standby when needing to unzip it processing to received second data command according to first identifier information judgement, then to described the Two data commands unzip it processing.
4. data command processing method as described in claim 1, which is characterized in that further include:
When first response data meets the second preset condition, processing is unziped it to first response data.
5. a kind of data command processing method, which is characterized in that be applied to target terminal equipment, which comprises
Receive the second data command that mobile terminal is sent;Second data command is that the mobile terminal receives user's transmission The first data command after, first data command meet the first preset condition when, will first data command progress What compression processing obtained;
Second data command is unziped it into processing, and the second response is generated according to the second data command after decompression Data;
Second response data is subjected to compression processing, obtains the first response data, and first response data is sent To the mobile terminal.
6. data command processing method as claimed in claim 5, which is characterized in that described to carry out second response data Compression processing, comprising:
When the byte length of second response data is greater than the second preset threshold, before removing in second response data Derivative evidence and/or redundancy.
7. data command processing method as claimed in claim 5, which is characterized in that further include:
Second identifier information is added to first response data;
It is described that first response data is sent to the mobile terminal, comprising:
The first response data after addition second identifier information is sent to the mobile terminal, so that the mobile terminal root Judge whether to need to unzip it processing to received first response data according to the second identifier information.
8. a kind of mobile terminal, including memory, processor and storage are in the memory and can be on the processor The computer program of operation, which is characterized in that the processor realizes such as Claims 1-4 when executing the computer program The step of any one the method.
9. a kind of terminal device, including memory, processor and storage are in the memory and can be on the processor The computer program of operation, which is characterized in that the processor realizes such as claim 5 to 7 when executing the computer program The step of any one the method.
10. a kind of computer readable storage medium, the computer-readable recording medium storage has computer program, and feature exists In when the computer program is executed by processor the step of any one of such as Claims 1-4 of realization the method;Alternatively, institute It states and is realized when computer program is executed by processor such as the step of any one of claim 5 to 7 the method.
11. a kind of bluetooth shield, which is characterized in that including Bluetooth chip and safety chip;
The Bluetooth chip is used to receive the second data command of mobile terminal transmission;Second data command is the movement It, will be described when first data command meets the first preset condition after terminal receives the first data command that user sends First data command carries out what compression processing obtained;
The Bluetooth chip is also used to unzip it second data command processing, and by the second data after decompression Instruction is sent to the safety chip;
The safety chip is used to generate the second response data according to the second data command after decompression, and by described the Two response datas are sent to the Bluetooth chip;
The Bluetooth chip is also used to second response data carrying out compression processing, obtains the first response data, and by institute It states the first response data and is sent to the mobile terminal.
CN201811049384.0A 2018-09-10 2018-09-10 Data command processing method, storage medium and bluetooth shield Pending CN110505655A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811049384.0A CN110505655A (en) 2018-09-10 2018-09-10 Data command processing method, storage medium and bluetooth shield

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811049384.0A CN110505655A (en) 2018-09-10 2018-09-10 Data command processing method, storage medium and bluetooth shield

Publications (1)

Publication Number Publication Date
CN110505655A true CN110505655A (en) 2019-11-26

Family

ID=68585143

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811049384.0A Pending CN110505655A (en) 2018-09-10 2018-09-10 Data command processing method, storage medium and bluetooth shield

Country Status (1)

Country Link
CN (1) CN110505655A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111542037A (en) * 2020-05-11 2020-08-14 Tcl移动通信科技(宁波)有限公司 Instruction transmission method, device and storage medium
CN113093992A (en) * 2021-03-24 2021-07-09 深圳大普微电子科技有限公司 Method and system for decompressing commands and solid state disk
CN115186306A (en) * 2022-09-13 2022-10-14 深圳市汇顶科技股份有限公司 Instruction processing method, instruction processing device, security unit, terminal device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102025737A (en) * 2010-12-09 2011-04-20 中兴通讯股份有限公司 Compression and transmission method of Ethernet data packet in microwave communication as well as compressor and system
CN103188247A (en) * 2011-12-31 2013-07-03 深圳市金蝶友商电子商务服务有限公司 Method and system of data transmission
CN105322969A (en) * 2015-12-09 2016-02-10 北京奇虎科技有限公司 Data compression and decompression method and device
CN106851733A (en) * 2016-12-29 2017-06-13 安徽网新恒天软件有限公司 A kind of adaptive H TTP message compression methods for mobile network's application
CN107318108A (en) * 2017-07-31 2017-11-03 努比亚技术有限公司 Data transmission system, method, external equipment and mobile terminal

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102025737A (en) * 2010-12-09 2011-04-20 中兴通讯股份有限公司 Compression and transmission method of Ethernet data packet in microwave communication as well as compressor and system
CN103188247A (en) * 2011-12-31 2013-07-03 深圳市金蝶友商电子商务服务有限公司 Method and system of data transmission
CN105322969A (en) * 2015-12-09 2016-02-10 北京奇虎科技有限公司 Data compression and decompression method and device
CN106851733A (en) * 2016-12-29 2017-06-13 安徽网新恒天软件有限公司 A kind of adaptive H TTP message compression methods for mobile network's application
CN107318108A (en) * 2017-07-31 2017-11-03 努比亚技术有限公司 Data transmission system, method, external equipment and mobile terminal

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111542037A (en) * 2020-05-11 2020-08-14 Tcl移动通信科技(宁波)有限公司 Instruction transmission method, device and storage medium
CN111542037B (en) * 2020-05-11 2023-07-21 深圳康盈半导体科技有限公司 Instruction transmission method, apparatus and storage medium
CN113093992A (en) * 2021-03-24 2021-07-09 深圳大普微电子科技有限公司 Method and system for decompressing commands and solid state disk
CN113093992B (en) * 2021-03-24 2024-09-10 深圳大普微电子科技有限公司 Command decompression method, system and solid state disk
CN115186306A (en) * 2022-09-13 2022-10-14 深圳市汇顶科技股份有限公司 Instruction processing method, instruction processing device, security unit, terminal device and storage medium
CN115186306B (en) * 2022-09-13 2023-05-16 深圳市汇顶科技股份有限公司 Instruction processing method, device, security unit, terminal equipment and storage medium

Similar Documents

Publication Publication Date Title
CN110363301B (en) Quantum line processing method, quantum line processing device, storage medium, and electronic device
CN110020620A (en) Face identification method, device and equipment under a kind of big posture
CN107632825A (en) A kind of business software development approach and device
CN110505655A (en) Data command processing method, storage medium and bluetooth shield
CN105264930B (en) Sending node and its reporting cached state method
CN107368272A (en) A kind of double screen is different to touch different aobvious method, apparatus and computer-readable recording medium
CN107438833A (en) A kind of data-updating method, device, system and server
CN109547574A (en) A kind of data transmission method and relevant apparatus
CN107122490A (en) The data processing method and system of aggregate function in a kind of Querying by group
CN109241357A (en) Chain structure model and its construction method, system and terminal device
CN108710531A (en) Method for writing data, device, terminal device and the storage medium of round-robin queue
CN107682441A (en) A kind of method of remote control, mobile terminal and PC ends
CN108762897A (en) Multitask management process and smartwatch
CN108228754A (en) flow generation method and terminal device
CN110147249A (en) A kind of calculation method and device of network model
CN108399136A (en) A kind of control method of serial line interface, device and host
CN110405750A (en) Motion control method and device of robot and robot
CN109741038A (en) Token processing method, computer readable storage medium and electronic equipment based on block chain account
CN108733799A (en) A kind of method for processing report data, device and terminal
CN109947531A (en) The expanding storage depth method, apparatus and storage medium of super fusion all-in-one machine
CN108965786A (en) A kind of electronic whiteboard content sharing method and device
CN108830596A (en) The acquisition device and terminal device of a kind of acquisition methods of information, information
CN105607913B (en) The operation processing method and device of interconnecting application
CN110515591A (en) Random digit generation method and device based on block chain
CN109783072A (en) Method for processing business, device, terminal device and computer readable storage medium

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20191126