CN116112911A - AT instruction processing method, device, terminal equipment and storage medium - Google Patents

AT instruction processing method, device, terminal equipment and storage medium Download PDF

Info

Publication number
CN116112911A
CN116112911A CN202310114043.1A CN202310114043A CN116112911A CN 116112911 A CN116112911 A CN 116112911A CN 202310114043 A CN202310114043 A CN 202310114043A CN 116112911 A CN116112911 A CN 116112911A
Authority
CN
China
Prior art keywords
communicated
instruction
operation information
communication module
priority
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
CN202310114043.1A
Other languages
Chinese (zh)
Inventor
饶坤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Maipu Communication Technology Co Ltd
Original Assignee
Maipu Communication 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 Maipu Communication Technology Co Ltd filed Critical Maipu Communication Technology Co Ltd
Priority to CN202310114043.1A priority Critical patent/CN116112911A/en
Publication of CN116112911A publication Critical patent/CN116112911A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/22Processing or transfer of terminal data, e.g. status or physical capabilities
    • H04W8/24Transfer of terminal data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/02Terminal devices
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)

Abstract

The embodiment of the application provides an AT instruction processing method, an AT instruction processing device, terminal equipment and a storage medium, and relates to the technical field of communication. The terminal equipment receives AT instructions sent by each process to be communicated through a corresponding virtual channel, adds a plurality of AT instructions into a transmission chain table according to a preset ordering rule, and sequentially processes the AT instructions in the transmission chain table to the communication module, and the communication module processes the received AT instructions. By the method, the processes to be communicated can send the AT instructions in parallel, the terminal equipment can directly and sequentially send the received instructions to the corresponding communication modules without waiting for operation information of the communication modules, so that waiting time between the processes can be reduced, and the sending performance and the sending efficiency of the AT instructions of each process are improved.

Description

AT instruction processing method, device, terminal equipment and storage medium
Technical Field
The present invention relates to the field of communications technologies, and in particular, to an AT instruction processing method, an apparatus, a terminal device, and a storage medium.
Background
With the rapid development of network communication, various types of communication modules, such as a WIFI (Wireless Fidelity ) module, a 4/5G module, a GPRS (General Packet Radio Services, general packet radio service) module, etc., are layered endlessly.
In the prior art, an AT instruction always follows a receiving and sending mode, that is, after one process sends the AT instruction to the communication module and receives a reply, the other process can send the AT instruction to the communication module, so that the problem that the processing performance of the AT instruction of each process is poor and the sending efficiency is low exists.
Disclosure of Invention
In view of the foregoing, an object of the present application is to provide an AT instruction processing method, apparatus, terminal device, and storage medium, so as to solve the problems in the prior art that the AT instruction processing performance of each process is poor and the transmission efficiency is low.
In order to achieve the above purpose, the technical solution adopted in the embodiment of the present application is as follows:
in a first aspect, the present application provides an AT instruction processing method, applied to a terminal device, where the terminal device includes a communication module, a plurality of processes to be communicated are set in the terminal device, and each process to be communicated corresponds to a virtual channel, and the method includes:
receiving AT instructions sent by each process to be communicated through a corresponding virtual channel;
adding a plurality of AT instructions to a transmission linked list according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission linked list to the communication module;
and the communication module processes the received AT command.
In an optional implementation manner, the ordering rule includes a priority order and a receiving time order, and the terminal device stores the priority of each process to be communicated; the adding a plurality of AT instructions to a transmission linked list according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission linked list to the communication module, including:
determining the priority of each AT instruction according to the priority of each process to be communicated, and adding each AT instruction into the transmission linked list according to the priority of each AT instruction;
and if the priority of the AT command is the same as that of other AT commands in the transmission linked list, adding the AT command into the transmission linked list according to the receiving time sequence of the AT command.
In an optional embodiment, a channel identifier of a corresponding virtual channel is set in each AT instruction, and the method further includes:
the communication module obtains the operation information corresponding to the AT command and determines whether the AT command is operated;
if the AT instruction is finished in operation, the communication module adds a channel identifier and a finishing identifier corresponding to the AT instruction in the operation information, and sends the operation information to the terminal equipment;
and if the AT command is not operated, adding a channel identifier corresponding to the AT command in the operation information by the communication module, and sending the operation information to the terminal equipment.
In an alternative embodiment, the method further comprises:
receiving operation information sent by the communication module, and adding the operation information into a receiving linked list according to the ordering rule;
determining a virtual channel corresponding to the operation information according to the channel identifier corresponding to each operation information in the receiving linked list in turn, and sending the operation information to a corresponding process to be communicated through the virtual channel, so that the process to be communicated determines whether an ending identifier exists in the operation information, and stopping acquiring the operation information under the condition that the ending identifier exists in the operation information.
In an alternative embodiment, the method further comprises:
under the condition that registration parameters sent by a process are received, generating a corresponding virtual channel for the process, and determining the priority of the process according to preset priority determination conditions and the registration parameters;
and adding the process identification of the process into a preset process management table to determine the process as a process to be communicated.
In an alternative embodiment, the method further comprises:
and under the condition that loading completion information sent by the communication module is received, sending channel available signals to all the processes to be communicated according to the process management table, so that all the processes to be communicated send AT instructions through corresponding virtual channels.
In a second aspect, the present application provides an AT instruction processing apparatus, applied to a terminal device, where the terminal device includes a communication module, a plurality of processes to be communicated are provided in the terminal device, and each process to be communicated corresponds to a virtual channel, and the apparatus includes:
the receiving module is used for receiving AT instructions sent by each process to be communicated through the corresponding virtual channel;
the sending module is used for adding a plurality of AT instructions to a sending chain table according to a preset ordering rule and sequentially sending the AT instructions in the sending chain table to the communication module;
and the operation module is used for processing the received AT command.
In an optional implementation manner, the ordering rule includes a priority order and a receiving time order, and the terminal device stores the priority of each process to be communicated;
the sending module is further configured to determine a priority of each AT instruction according to a priority of each process to be communicated, and add each AT instruction to the sending linked list according to the priority of each AT instruction; and if the priority of the AT command is the same as that of other AT commands in the transmission linked list, adding the AT command into the transmission linked list according to the receiving time sequence of the AT command.
In a third aspect, the present application provides a terminal device comprising a processor and a memory, the memory storing a computer program executable by the processor, the processor being executable to implement the method of any of the preceding embodiments.
In a fourth aspect, the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements a method as in any of the preceding embodiments.
According to the AT instruction processing method, the device, the terminal equipment and the storage medium, the terminal equipment is provided with the communication module, meanwhile, the terminal equipment is also provided with a plurality of processes to be communicated, each process to be communicated corresponds to one virtual channel, the terminal equipment can receive AT instructions sent by each process to be communicated through the corresponding virtual channel, then the plurality of AT instructions are added into the sending linked list according to a preset ordering rule, the AT instructions in the sending linked list are sequentially sent to the communication module, and the communication module can operate the received AT instructions. By the method, the processes to be communicated can send the AT instructions in parallel, the terminal equipment can directly and sequentially send the received instructions to the corresponding communication modules without waiting for operation information of the communication modules, so that waiting time between the processes can be reduced, and the sending performance and the sending efficiency of the AT instructions of each process are improved.
In order to make the above objects, features and advantages of the present application more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered limiting the scope, and that other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 shows a block schematic diagram of a terminal device provided in an embodiment of the present application;
fig. 2 is a schematic flow chart of an AT instruction processing method according to an embodiment of the present application;
fig. 3 is a schematic flow chart of another method for processing AT instructions according to an embodiment of the present application;
fig. 4 shows a functional block diagram of an AT instruction processing apparatus according to an embodiment of the present application.
Icon: 10-terminal equipment; 100-memory; 110-a processor; 120-a communication module; 300-a receiving module; 310-a transmitting module; 320-run module.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. The components of the embodiments of the present application, which are generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, as provided in the accompanying drawings, is not intended to limit the scope of the application, as claimed, but is merely representative of selected embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, are intended to be within the scope of the present application.
It is noted that relational terms such as "first" and "second", and the like, are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
With the rapid development of network communication, various types of communication modules are layered endlessly, such as WIFI (Wireless Fidelity ) modules, 4/5G modules, GPRS ((General Packet Radio Services, general packet radio service) modules, and the like.
AT present, a hardware interface-to-serial port mode is generally adopted to control a network communication module, an AT instruction is a key for realizing the control method, a standard serial port mode is adopted in the command language, the module control is greatly simplified, the simple serial port programming can be realized, the function is comprehensive, and the control of calling, short messages, phonebooks, data services, faxes and the like of the module can be realized through a group of commands.
In the prior art, a process can send an AT instruction to a communication module through an AT channel, and the communication module can often return corresponding operation information based on the received AT instruction. AT present, the use of an AT channel is generally limited in a locking mode, when a process uses the AT channel, the process can apply for mutex lock protection resources, AT this time, other processes cannot use the AT channel, and only the process which uses the AT channel can release the mutex lock after receiving operation information, and the other processes can use the channel.
Under the condition, the AT command follows a receiving and sending mode, namely, after one process sends the AT command to the communication module and receives the operation information, the other process can send the AT command to the communication module, so that the processes have receiving waiting, the AT command processing performance of each process is poor, and the sending efficiency is low; meanwhile, two programs based on different programming logic cannot use the same set of locking protection logic.
Based on this, the embodiment of the application provides an AT instruction processing method to solve the above problems. Specifically, fig. 1 is a block diagram of a terminal device 10, which includes a memory 100, a processor 110, and a communication module 120. The memory 100, the processor 110, and the communication module 120 are electrically connected directly or indirectly to each other to realize data transmission or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines.
Wherein the memory 100 is used for storing programs or data. The Memory 100 may be, but is not limited to, random access Memory (Random Access Memory, RAM), read Only Memory (ROM), programmable Read Only Memory (Programmable Read-Only Memory, PROM), erasable Read Only Memory (Erasable Programmable Read-Only Memory, EPROM), electrically erasable Read Only Memory (Electric Erasable Programmable Read-Only Memory, EEPROM), etc.
The processor 110 is used to read/write data or programs stored in the memory and perform corresponding functions.
The communication module 120 is used for establishing a communication connection between a server and other communication terminals through a network, and for transceiving data through the network.
It should be understood that the structure shown in fig. 1 is merely a schematic diagram of a structure of a terminal device, and the terminal device may further include more or fewer components than shown in fig. 1, or have a different configuration than shown in fig. 1. The components shown in fig. 1 may be implemented in hardware, software, or a combination thereof.
Optionally, the terminal device 10 is further provided with a communication module and a channel management module, where the channel management module may send AT instructions of each process to the communication module through an AT channel, and receive operation information sent by the communication module.
Optionally, a plurality of processes to be communicated are further provided in the terminal device 10, and each process to be communicated corresponds to a virtual channel, and each process to be communicated can be connected with the channel management module through a corresponding virtual channel.
Optionally, the channel management module is configured to manage a virtual channel corresponding to each process to be communicated, receive an AT instruction sent by each process to be communicated, send the AT instruction to the communication module through the AT channel, receive operation information sent by the communication module, send the operation information to each process to be communicated, and so on. Next, the method for processing the AT instruction provided in the embodiment of the present application will be exemplarily described with reference to the flowchart with the terminal device 10 in fig. 1 as an execution body. Specifically, fig. 2 is a schematic flow chart of an AT instruction processing method provided in an embodiment of the present application, please refer to fig. 2, and the method includes:
step S20, receiving AT instructions sent by each process to be communicated through the corresponding virtual channel.
Optionally, the process to be communicated refers to a process with a requirement of interacting with the communication module, and the virtual channel can be generated by a channel management module on the terminal device when the process has an interaction requirement, and can also be generated in advance for each process.
In this embodiment, after generating the AT instruction, each process to be communicated may send the AT instruction to the channel management module on the terminal device through the virtual channel.
And S21, adding a plurality of AT instructions into a transmission chain table according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission chain table to a communication module.
Optionally, in order to facilitate the channel management module to send each AT instruction to the communication module, a sending linked list may be set in advance, for temporarily storing and sending the AT instructions.
Optionally, the preset ordering rule may be set in the channel management module in advance, so as to add the AT instruction to the transmit chain table.
In this embodiment, the channel management module in the terminal device may add the received AT instruction to the transmit chain table according to a preset ordering rule, and meanwhile, the channel management module may sequentially transmit the AT instruction in the transmit chain table to the communication module, where it can be understood that, in this case, each process to be communicated may send the AT instruction to the controller concurrently, and the channel management module may also send the AT instruction to the communication module continuously through the AT channel.
In step S22, the communication module processes the received AT command.
In this embodiment, the communication module may process the AT command after receiving the AT command.
According to the AT instruction processing method provided by the embodiment of the application, the terminal equipment is provided with the communication module, meanwhile, the terminal equipment is also provided with a plurality of processes to be communicated, each process to be communicated corresponds to one virtual channel, the terminal equipment can receive AT instructions sent by each process to be communicated through the corresponding virtual channel, then the plurality of AT instructions are added into the sending linked list according to the preset ordering rule, the AT instructions in the sending linked list are sequentially sent to the communication module, and the communication module can operate the received AT instructions. By the method, the processes to be communicated can send the AT instructions in parallel, the terminal equipment can directly and sequentially send the received instructions to the corresponding communication modules without waiting for operation information of the communication modules, so that waiting time between the processes can be reduced, and the sending performance and the sending efficiency of the AT instructions of each process are improved.
Optionally, when the AT command is added to the transmit chain table, the terminal device may refer to the priority of each AT command preferentially, if the priority of the AT commands is the same, refer to the receiving time of the AT commands again, and on this basis, the ordering rule includes a priority order and a receiving time order, and the priority of each process to be communicated may be stored in the terminal device in advance.
Specifically, fig. 3 is another flow chart of the AT instruction processing method provided in the embodiment of the present application on the basis of fig. 2, please refer to fig. 3, and the step S21 may be further implemented by:
step S21-1, determining the priority of each AT instruction according to the priority of each process to be communicated, and adding each AT instruction into a transmission linked list according to the priority of each AT instruction;
in step S21-2, if the priority of the AT command is the same as that of other AT commands in the transmission linked list, the AT command is added to the transmission linked list according to the receiving time sequence of the AT command.
In this embodiment, it may be understood that the priority of each AT instruction is consistent with the priority of the process to be communicated that generates the AT instruction, so that the channel management module on the terminal device may determine the priority of each received AT instruction according to the priority of each process to be communicated stored in advance.
Alternatively, the channel management module may first add the AT instruction to the transmit chain table based on the priority order, and if the AT instruction having the same priority as the AT instruction already exists in the transmit chain table, the AT instruction may be added according to the receiving time order.
In one possible implementation, higher priority AT instructions may be ordered before lower priority AT instructions, and early-received AT instructions may be ordered before late-received AT instructions.
Optionally, there are multiple processes in the terminal device, but not every process is a process to be communicated, and the channel management module in the terminal device may determine the priority of the process in determining the process as the process to be communicated, and generate a corresponding virtual channel for the process.
Alternatively, the channel management module in the terminal device may determine the priority of each process to be communicated in advance according to the parameters of the process to be communicated and store the priority. In one possible implementation manner, each process may send a registration parameter to the channel management module in the presence of an interaction requirement, and then the channel management module may generate a corresponding virtual channel for the process in the case of receiving the registration parameter sent by the process, determine a condition and the registration parameter according to a preset priority, determine the priority of the process, and then add a process identifier of the process to a preset process management table to determine the process as a process to be communicated.
Optionally, the registration parameter refers to a parameter of the process to be communicated, such as a task type, a process identifier, a task emergency degree, and the like of the process to be communicated; the priority determination condition may be stored in the terminal device in advance, and is used to instruct how to determine the priority of the process to be communicated according to the registration parameter of the process to be communicated, for example, the priority determination condition may be to determine the priority of the process to be communicated according to the task type of the process, or determine the priority of the process to be communicated according to the task urgency of the process.
Alternatively, the process management table is used for managing the information of the process to be communicated, and may be generated in advance and stored in the terminal device, where the information of the process identifier, the priority, the corresponding virtual channel, and the like of the process to be communicated may be recorded.
In one possible implementation manner, the process may register as a process to be communicated before the communication module is completely loaded, but since the communication module is not completely loaded AT this time, the process to be communicated cannot send an AT instruction, in this case, the channel management module may send a channel available signal to all the processes to be communicated according to the process management table when receiving the loading completion information sent by the communication module, so that each process to be communicated sends the AT instruction through a corresponding virtual channel.
It can be understood that the loading completion information is sent to the channel management module by the communication module after loading is completed, and the channel management module can send the channel available signal to all the processes to be communicated recorded in the process management table in a broadcast mode.
In another possible implementation manner, the process registers as a process to be communicated after the communication module is loaded, and the channel management module may directly send loading completion information to the process to be communicated, so that the process to be communicated sends an AT instruction.
Optionally, the communication module may be unloaded, when the communication module is unloaded, unloading information may be sent to the channel management module in advance, and then the channel management module may send a channel unavailable signal to all the processes to be communicated according to the process management table when receiving the unloading information sent by the communication module, so that each process to be communicated stops sending the AT instruction.
Optionally, considering that the AT channel can only pass through one AT instruction or running information AT the same time, if a plurality of processes send AT instructions to the communication module, there may be a problem of instruction conflict, so that running information is misplaced in return, so in order to prevent the running information returned by the communication module from being misplaced, each AT instruction may be provided with a channel identifier of a corresponding virtual channel, and then the communication module may add the channel identifier of the corresponding virtual channel to the obtained running information, so that the channel management module returns the running information to the corresponding communication process according to the channel identifier.
In this embodiment, the communication module may obtain the operation information in the operation process according to the AT instruction, and it can be understood that, for some AT instructions, the communication module may obtain the corresponding operation information only when the AT instruction is completed, and for some AT instructions, the communication module may obtain the operation information in the operation process of the AT instruction, and on this basis, the communication module may return the operation information multiple times until the AT instruction is completed.
However, the current process immediately stops receiving after receiving the running information of the communication module, so that the problem that the running information of some processes is not completely received exists, so that in order to ensure that the process to be communicated can not stop receiving before receiving the complete running information, an ending identifier can be added in the running information by the communication module under the condition that the AT instruction running is ended, so that the process to be communicated always keeps a receiving state when the process to be communicated does not add the ending identifier in the running information.
On the basis, the method further comprises the following steps:
the communication module obtains the operation information corresponding to the AT instruction and determines whether the AT instruction is operated; if the AT instruction is finished, the communication module adds a channel identifier and a finishing identifier corresponding to the AT instruction in the operation information, and sends the operation information to the terminal equipment; if the AT command is not operated, the communication module adds a channel identifier corresponding to the AT command in the operation information and sends the operation information to the terminal equipment.
Optionally, the operation information is information obtained by the communication module executing the AT instruction, and in a possible implementation manner, the operation information may be an operation parameter, data to be obtained pointed by the AT instruction, and so on; in another possible implementation, the execution information may be an execution success flag, an execution failure flag, or the like.
In this embodiment, the communication module may operate according to the received AT instruction, so as to obtain operation information, and after obtaining the operation information, the communication module may determine whether the AT instruction has been completed.
In this embodiment, the communication module may add, in the running information, a channel identifier of a corresponding virtual channel when the AT instruction has been executed and ended, and simultaneously add the ending identifier, and send the ending identifier to the channel management module; and under the condition that the AT instruction is not executed, adding the channel identification of the corresponding virtual channel in the running information, and then sending the channel identification to the channel management module.
On this basis, the terminal device can receive the operation information sent by the communication module and add the operation information to the receiving linked list according to the ordering rule; and determining a virtual channel corresponding to the operation information according to the channel identifier corresponding to each operation information in the receiving linked list, and sending the operation information to a corresponding process to be communicated through the virtual channel, so that the process to be communicated determines whether an ending identifier exists in the operation information, and stopping acquiring the operation information under the condition that the ending identifier exists in the operation information.
Optionally, the channel management module may add the operation information to the receiving linked list according to a preset ordering rule when receiving the operation information sent by the communication module.
It will be appreciated that the channel management module may first add the operation information to the receiving linked list based on the priority order, and if the operation information having the same priority as the operation information already exists in the receiving linked list, the operation information may be added according to the receiving time order.
Optionally, the channel management module may sequentially send the running information in the receiving chain table to the corresponding process to be communicated through the corresponding virtual channel.
In this embodiment, since the channel identifier of the corresponding virtual channel is added to the running information, the channel management module may determine the virtual channel corresponding to the running information according to the channel identifier, so that the running information is directly sent to the corresponding process to be communicated through the virtual channel.
It can be understood that by the method, the channel management module in the terminal device can accurately send the operation information to the corresponding process to be communicated, so that the problem of dislocation of operation information return is avoided.
Optionally, after receiving the corresponding running information, the process to be communicated may determine whether an end identifier exists in the running information, so as to determine whether to stop acquiring the running information at this time. It can be appreciated that if the running information includes the end identifier, it can be determined that the running information is completely acquired, so as to stop receiving; if the running information does not include the end identifier, it can be determined that the running information is not completely acquired, and some running information is not acquired, so that the receiving is not stopped, and the process to be communicated can be ensured to receive the complete running information.
In order to perform the corresponding steps in the above embodiments and in each possible way, an implementation of an AT instruction processing apparatus is given below. Further, referring to fig. 4, fig. 4 is a functional block diagram of an AT instruction processing apparatus according to an embodiment of the present application. It should be noted that, the basic principle and the technical effects of the AT instruction processing apparatus provided in this embodiment are the same as those of the foregoing embodiments, and for brevity, reference may be made to the corresponding contents of the foregoing embodiments. The AT instruction processing device comprises: a receiving module 300, a transmitting module 310 and an operating module 320.
The receiving module 300 is configured to receive an AT instruction sent by each process to be communicated through a corresponding virtual channel.
It will be appreciated that the receiving module 300 may also be used to perform step S20 described above.
The sending module 310 is configured to add a plurality of AT instructions to a sending linked list according to a preset ordering rule, and send the AT instructions in the sending linked list to the communication module in sequence.
It will be appreciated that the transmitting module 310 may be configured to perform step S21 described above.
The operation module 320 is configured to process the received AT instruction.
It is understood that the operation module 320 may also be used to perform the above step S22.
Optionally, the sending module 310 is further configured to determine a priority of each AT instruction according to a priority of each process to be communicated, and add each AT instruction to a sending linked list according to the priority of each AT instruction; if the priority of the AT command is the same as that of other AT commands in the transmission linked list, the AT command is added into the transmission linked list according to the receiving time sequence of the AT command.
It will be appreciated that the transmitting module 310 may be configured to perform steps S21-1 to S21-2 described above.
Optionally, the operation module 320 is further configured to obtain operation information corresponding to the AT instruction by using the communication module, and determine whether the AT instruction is operated; if the AT instruction is finished, the communication module adds a channel identifier and a finishing identifier corresponding to the AT instruction in the operation information, and sends the operation information to the terminal equipment; if the AT command is not operated, the communication module adds a channel identifier corresponding to the AT command in the operation information and sends the operation information to the terminal equipment.
Optionally, the sending module 310 is further configured to receive the operation information sent by the communication module, and add the operation information to a receiving linked list according to a sorting rule; and determining a virtual channel corresponding to the operation information according to the channel identifier corresponding to each operation information in the receiving linked list in turn, and sending the operation information to a corresponding process to be communicated through the virtual channel, so that the process to be communicated determines whether an end identifier exists in the operation information, and stopping acquiring the operation information under the condition that the end identifier exists in the operation information.
Optionally, the receiving module 300 is further configured to generate a corresponding virtual channel for the process under the condition that the registration parameter sent by the process is received, and determine the priority of the process according to a preset priority determining condition and the registration parameter; and adding the process identification of the process into a preset process management table to determine the process as the process to be communicated.
Optionally, the receiving module 300 is further configured to send a channel available signal to all processes to be communicated according to the process management table under the condition that the loading completion information sent by the communication module is received, so that each process to be communicated sends an AT instruction through a corresponding virtual channel.
According to the AT instruction processing device provided by the embodiment of the application, the receiving module is used for receiving the AT instructions sent by each process to be communicated through the corresponding virtual channel; adding a plurality of AT instructions into a transmission chain table through a transmission module according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission chain table to a communication module; and operating according to the received AT command through an operation module. Through the device, the processes to be communicated can send AT instructions in parallel, and the terminal equipment can directly and sequentially send the received instructions to the corresponding communication modules without waiting for operation information of the communication modules, so that waiting time between the processes can be reduced, and the sending performance and the sending efficiency of the AT instructions of each process are improved.
Alternatively, the above modules may be stored in the memory shown in fig. 1 in the form of software or Firmware (Firmware) or solidified in an Operating System (OS) of the terminal device, and may be executed by the processor in fig. 1. Meanwhile, data, codes of programs, and the like required to execute the above-described modules may be stored in the memory.
Optionally, the embodiment of the present application further provides a computer readable storage medium, on which a computer program is stored, where the computer program may be executed by a processor to implement the AT instruction processing method provided by the embodiment of the present application.
In the several embodiments provided in this application, it should be understood that the disclosed apparatus and method may be implemented in other manners as well. The apparatus embodiments described above are merely illustrative, for example, flow diagrams and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, the functional modules in the embodiments of the present application may be integrated together to form a single part, or each module may exist alone, or two or more modules may be integrated to form a single part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The foregoing description is only of the preferred embodiments of the present application and is not intended to limit the same, but rather, various modifications and variations may be made by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.

Claims (10)

1. An AT instruction processing method is characterized by being applied to terminal equipment, wherein the terminal equipment comprises a communication module, a plurality of processes to be communicated are arranged in the terminal equipment, and each process to be communicated corresponds to a virtual channel, and the method comprises the following steps:
receiving AT instructions sent by each process to be communicated through a corresponding virtual channel;
adding a plurality of AT instructions to a transmission linked list according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission linked list to the communication module;
and the communication module processes the received AT command.
2. The method according to claim 1, wherein the ordering rule includes a priority order and a reception time order, and the priority of each of the processes to be communicated is stored in the terminal device; the adding a plurality of AT instructions to a transmission linked list according to a preset ordering rule, and sequentially transmitting the AT instructions in the transmission linked list to the communication module, including:
determining the priority of each AT instruction according to the priority of each process to be communicated, and adding each AT instruction into the transmission linked list according to the priority of each AT instruction;
and if the priority of the AT command is the same as that of other AT commands in the transmission linked list, adding the AT command into the transmission linked list according to the receiving time sequence of the AT command.
3. The method of claim 1, wherein each AT instruction has a channel identifier of a corresponding virtual channel, the method further comprising:
the communication module obtains the operation information corresponding to the AT command and determines whether the AT command is operated;
if the AT instruction is finished in operation, the communication module adds a channel identifier and a finishing identifier corresponding to the AT instruction in the operation information, and sends the operation information to the terminal equipment;
and if the AT command is not operated, adding a channel identifier corresponding to the AT command in the operation information by the communication module, and sending the operation information to the terminal equipment.
4. A method according to claim 3, characterized in that the method further comprises:
receiving operation information sent by the communication module, and adding the operation information into a receiving linked list according to the ordering rule;
determining a virtual channel corresponding to the operation information according to the channel identifier corresponding to each operation information in the receiving linked list in turn, and sending the operation information to a corresponding process to be communicated through the virtual channel, so that the process to be communicated determines whether an ending identifier exists in the operation information, and stopping acquiring the operation information under the condition that the ending identifier exists in the operation information.
5. The method according to claim 1, wherein the method further comprises:
under the condition that registration parameters sent by a process are received, generating a corresponding virtual channel for the process, and determining the priority of the process according to preset priority determination conditions and the registration parameters;
and adding the process identification of the process into a preset process management table to determine the process as a process to be communicated.
6. The method of claim 5, wherein the method further comprises:
and under the condition that loading completion information sent by the communication module is received, sending channel available signals to all the processes to be communicated according to the process management table, so that all the processes to be communicated send AT instructions through corresponding virtual channels.
7. An AT instruction processing apparatus, which is applied to a terminal device, wherein the terminal device includes a communication module, a plurality of processes to be communicated are provided in the terminal device, and each process to be communicated corresponds to a virtual channel, and the apparatus includes:
the receiving module is used for receiving AT instructions sent by each process to be communicated through the corresponding virtual channel;
the sending module is used for adding a plurality of AT instructions to a sending chain table according to a preset ordering rule and sequentially sending the AT instructions in the sending chain table to the communication module;
and the operation module is used for processing the received AT command.
8. The apparatus of claim 7, wherein the ordering rule comprises a priority order and a reception time order, and wherein the priority of each of the processes to be communicated is stored in the terminal device;
the sending module is further configured to determine a priority of each AT instruction according to a priority of each process to be communicated, and add each AT instruction to the sending linked list according to the priority of each AT instruction; and if the priority of the AT command is the same as that of other AT commands in the transmission linked list, adding the AT command into the transmission linked list according to the receiving time sequence of the AT command.
9. A terminal device comprising a processor and a memory, the memory storing a computer program executable by the processor, the processor being executable to implement the method of any one of claims 1-6.
10. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the method according to any of claims 1-6.
CN202310114043.1A 2023-02-10 2023-02-10 AT instruction processing method, device, terminal equipment and storage medium Pending CN116112911A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310114043.1A CN116112911A (en) 2023-02-10 2023-02-10 AT instruction processing method, device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310114043.1A CN116112911A (en) 2023-02-10 2023-02-10 AT instruction processing method, device, terminal equipment and storage medium

Publications (1)

Publication Number Publication Date
CN116112911A true CN116112911A (en) 2023-05-12

Family

ID=86255834

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310114043.1A Pending CN116112911A (en) 2023-02-10 2023-02-10 AT instruction processing method, device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN116112911A (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101227469A (en) * 2008-01-23 2008-07-23 中兴通讯股份有限公司 Method for implementing mobile terminal parallel business processing
CN101883345A (en) * 2010-06-30 2010-11-10 青岛海信移动通信技术股份有限公司 Method and device for processing AT command
CN103391325A (en) * 2013-07-30 2013-11-13 李想 Network operating system device and method for Internet of Things
CN103914281A (en) * 2012-12-29 2014-07-09 重庆重邮信科通信技术有限公司 Mobile software system application request parallel processing method and system
CN111722938A (en) * 2020-05-08 2020-09-29 深圳市广和通无线股份有限公司 AT instruction processing method, AT instruction processing device, computer equipment and storage medium
CN113179227A (en) * 2021-04-26 2021-07-27 哈尔滨铁路科研所科技有限公司 AT instruction control method based on queue
CN113297084A (en) * 2021-05-27 2021-08-24 上海移远通信技术股份有限公司 Test method, test system, electronic equipment and storage medium
CN113672284A (en) * 2021-10-25 2021-11-19 北京中天星控科技开发有限公司 Instruction execution method, system, electronic equipment and storage medium
CN114124750A (en) * 2021-11-10 2022-03-01 重庆芯讯通无线科技有限公司 Test method, system, equipment and storage medium of communication module
CN115695592A (en) * 2022-10-28 2023-02-03 成都爱旗科技有限公司 AT command processing method, device and equipment

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101227469A (en) * 2008-01-23 2008-07-23 中兴通讯股份有限公司 Method for implementing mobile terminal parallel business processing
CN101883345A (en) * 2010-06-30 2010-11-10 青岛海信移动通信技术股份有限公司 Method and device for processing AT command
CN103914281A (en) * 2012-12-29 2014-07-09 重庆重邮信科通信技术有限公司 Mobile software system application request parallel processing method and system
CN103391325A (en) * 2013-07-30 2013-11-13 李想 Network operating system device and method for Internet of Things
CN111722938A (en) * 2020-05-08 2020-09-29 深圳市广和通无线股份有限公司 AT instruction processing method, AT instruction processing device, computer equipment and storage medium
CN113179227A (en) * 2021-04-26 2021-07-27 哈尔滨铁路科研所科技有限公司 AT instruction control method based on queue
CN113297084A (en) * 2021-05-27 2021-08-24 上海移远通信技术股份有限公司 Test method, test system, electronic equipment and storage medium
CN113672284A (en) * 2021-10-25 2021-11-19 北京中天星控科技开发有限公司 Instruction execution method, system, electronic equipment and storage medium
CN114124750A (en) * 2021-11-10 2022-03-01 重庆芯讯通无线科技有限公司 Test method, system, equipment and storage medium of communication module
CN115695592A (en) * 2022-10-28 2023-02-03 成都爱旗科技有限公司 AT command processing method, device and equipment

Similar Documents

Publication Publication Date Title
CN109831338B (en) Vehicle machine system upgrading method, cloud server and mobile terminal
CN109600769B (en) Communication method and device
CN110543321A (en) OTA (over the air) upgrading method, device, terminal and computer readable storage medium
CN110737681B (en) Locking processing method and device for processing request, computer equipment and storage medium
CN113254075B (en) Instruction execution method, instruction execution device, electronic device, and storage medium
CN114244917B (en) Data transmission method, device and system
CN116112911A (en) AT instruction processing method, device, terminal equipment and storage medium
CN117472627A (en) Task repetition management system, method and device, electronic equipment and storage medium
CN113806035B (en) Distributed scheduling method and service server
CN112637121B (en) Data port updating method and device, electronic equipment and readable storage medium
CN110113181B (en) Node configuration method, node configuration device, computer device, and readable storage medium
CN112988339B (en) Data management method and device
KR20220069113A (en) Data structures, storage means and devices
CN112766486A (en) Searching method of neural network structure, terminal, server and readable storage medium
JP5502051B2 (en) Method for processing step execution results in software application control managed objects
CN112055058A (en) Data storage method and device and computer readable storage medium
CN110677466A (en) Application program downloading method, device, gateway and storage medium
CN115543343B (en) Variable cross-thread operation method and device
CN112996132B (en) Dynamic scheduling method, device and equipment applied to 5G physical layer
CN115150031B (en) Distributed system message response method and device based on distributed message
CN112511603B (en) Data port updating method and device, electronic equipment and readable storage medium
CN112532699B (en) Data port updating method and device, electronic equipment and readable storage medium
CN114237758B (en) Communication connection method, device, electronic equipment and computer readable storage medium
CN116248495A (en) Resource determination method and device and electronic equipment
CN116866430A (en) Base station data proxy analysis method, system, terminal equipment and 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