CN111163171B - Remote control method and device for terminal equipment - Google Patents

Remote control method and device for terminal equipment Download PDF

Info

Publication number
CN111163171B
CN111163171B CN201911414689.1A CN201911414689A CN111163171B CN 111163171 B CN111163171 B CN 111163171B CN 201911414689 A CN201911414689 A CN 201911414689A CN 111163171 B CN111163171 B CN 111163171B
Authority
CN
China
Prior art keywords
long connection
instruction
executed
terminal equipment
terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201911414689.1A
Other languages
Chinese (zh)
Other versions
CN111163171A (en
Inventor
于健
刘在平
许宝进
唐坤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong Senter Electronic Co Ltd
Original Assignee
Shandong Senter Electronic 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 Shandong Senter Electronic Co Ltd filed Critical Shandong Senter Electronic Co Ltd
Priority to CN201911414689.1A priority Critical patent/CN111163171B/en
Publication of CN111163171A publication Critical patent/CN111163171A/en
Application granted granted Critical
Publication of CN111163171B publication Critical patent/CN111163171B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/146Markers for unambiguous identification of a particular session, e.g. session cookie or URL-encoding

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The application discloses a remote control method of terminal equipment, which comprises the following steps: in a preset time, the server receives a request message for acquiring a command to be executed, which is sent by the terminal equipment; inquiring a pre-cached instruction list to be executed based on the equipment identifier of the terminal equipment according to the request message; returning the inquired to-be-executed instruction to the terminal equipment so that the terminal equipment can execute the to-be-executed instruction conveniently; and establishing long connection between the server and the equipment according to the specific instruction to be executed, and establishing long connection between the server and the control end, so that the control end can control the terminal equipment in real time. According to the method and the device, the terminal equipment obtains the instruction cached by the control end at the server end by receiving the instruction obtaining request of the terminal equipment within the preset time, so that the aim of controlling the terminal equipment in a non-real-time manner is fulfilled; the long connections between the server and the terminal equipment and between the server and the control end can be dynamically established, so that the control end can control the terminal equipment in real time.

Description

Remote control method and device for terminal equipment
Technical Field
The present application relates to the field of computer technologies, and in particular, to a remote control method and apparatus for a terminal device.
Background
With the advance of technology, many devices which previously operated independently are also networked to communicate with a designated server through a network, and these peripheral devices interacting with the server are collectively referred to as terminal devices. Meanwhile, in order to implement remote control on peripheral equipment, a class of equipment or application needs to communicate with a server and issue an instruction, and then the instruction is forwarded to terminal equipment by the server, and the class of equipment or application is collectively called as a control end.
The existing control method of the control end for the terminal equipment has the defects that the control end cannot better control the terminal equipment.
Disclosure of Invention
In view of this, embodiments of the present application provide a method and an apparatus for remotely controlling a terminal device, so as to solve a problem that a control end in the prior art cannot better control the terminal device.
The embodiment of the application adopts the following technical scheme:
the embodiment of the application provides a remote control method of terminal equipment, which comprises the following steps:
in a preset time, the server receives a request message for acquiring a command to be executed, which is sent by the terminal equipment; the request message comprises a device identifier of the terminal device;
determining the equipment identifier of the terminal equipment according to the request message, and inquiring a pre-cached instruction list to be executed based on the equipment identifier; the device identifier of the terminal device is stored corresponding to the instruction list to be executed by the terminal device; returning a to-be-executed instruction corresponding to the identifier of the terminal equipment to the terminal equipment so that the terminal equipment can execute the to-be-executed instruction;
based on the received request from the control terminal, putting a long connection establishing instruction into the instruction list to be executed so that the service terminal and the terminal equipment establish long connection; and receiving a request for establishing long connection from the control terminal, so that the service terminal and the control terminal establish long connection.
Further, after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further includes:
receiving information sent by the control terminal, and obtaining an identifier of the terminal equipment and a command to be executed corresponding to the identifier of the terminal equipment according to the information;
and searching the long connection maintenance list according to the obtained identifier of the terminal equipment, and sending the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment through long connection so that the terminal equipment can execute the instruction to be executed corresponding to the identifier of the terminal equipment in real time.
Further, after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further includes:
storing the identifier of the terminal equipment into a first long connection maintenance list; storing the identifier of the control end into a second long connection maintenance list; and the first long connection maintenance list and the second long connection maintenance list are correspondingly stored.
Further, the method further comprises:
and the server provides an interface for modifying the instruction list to be executed so that the control end calls the interface to dynamically modify the instruction list to be executed.
Further, before the querying a pre-cached list of instructions to be executed based on the device identifier, the method further includes:
and storing the device identifier and the list of the instructions to be executed corresponding to the device identifier in a database.
Further, after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further includes:
and the server receives a first protocol sent by the control terminal so as to judge whether the server establishes long connection with the terminal equipment or not through the first protocol.
Further, after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further includes:
and the server receives a second protocol sent by the plurality of control terminals, so that the plurality of control terminals monitor the terminal equipment through the second protocol.
Further, when the instruction to be executed corresponding to the identifier of the terminal device is to disconnect long connection; after the instruction to be executed corresponding to the identifier of the terminal device is sent to the terminal device through the long connection, the method further includes:
the server side disconnects with the terminal equipment, the server side disconnects with the control side, the identifier of the terminal equipment in the first long connection maintenance list and the identifier of the control side in the second long connection maintenance list are deleted, and the monitoring relation of the plurality of control sides to the terminal equipment is relieved.
Further, after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further includes:
the server receives a third protocol sent by the control end, so that the transmission mode of the instruction to be executed corresponding to the identifier of the terminal equipment is changed into a mode that the request information for acquiring the instruction to be executed is sent to the server through the terminal equipment within a preset time, and the server returns the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment after receiving the request information for acquiring the instruction to be executed sent by the terminal equipment.
An embodiment of the present application further provides a remote control apparatus for a terminal device, where the apparatus includes:
the server side receives a request message for acquiring the instruction to be executed, which is sent by the terminal equipment, within the preset time; the request message comprises a device identifier of the terminal device;
a determining unit, configured to determine a device identifier of the terminal device according to the request message, and query a pre-cached instruction list to be executed based on the device identifier, where the device identifier of the terminal device is stored in correspondence with the instruction list to be executed by the terminal device; returning the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment so that the terminal equipment can execute the instruction to be executed conveniently;
the execution unit is used for putting a long connection establishing instruction into the instruction list to be executed based on the received request from the control end so as to establish long connection between the service end and the terminal equipment; and receiving a request for establishing long connection from the control terminal, so that the service terminal and the control terminal establish long connection.
The embodiment of the application adopts at least one technical scheme which can achieve the following beneficial effects: according to the method and the device, the terminal equipment acquires the command cached at the server side by receiving the command acquisition request of the terminal equipment within the preset time, and the terminal equipment executes the command, so that the purpose of controlling the terminal equipment is achieved, and the control side can better control the terminal equipment. Based on the received request from the control end, the instruction for establishing the long connection can be put into an instruction list to be executed, so that the long connection is established between the service end and the terminal equipment, the long connection is established between the service end and the control end, the instruction sent by the control end can be forwarded to the terminal equipment in real time, and the terminal equipment responds to the instruction of the control end in real time.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1 is a schematic flowchart of a remote control method for a terminal device according to an embodiment of the present disclosure;
fig. 2 is a schematic flowchart of a remote control method for a terminal device according to a second embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a remote control device of a terminal device according to a third embodiment of this specification.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the technical solutions of the present application will be described in detail and completely with reference to the following specific embodiments of the present application and the accompanying drawings. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Fig. 1 is a schematic flowchart of a remote control method for a terminal device according to an embodiment of the present disclosure.
The embodiment of the present specification may be implemented by a server side, and specifically includes:
step S101, in a preset time, a server receives a request message sent by a terminal device for acquiring a command to be executed, wherein the request message comprises a device identifier of the terminal device.
Step S102, according to the request message, the server determines the device identifier of the terminal device, and queries a pre-cached instruction list to be executed based on the device identifier, wherein the device identifier of the terminal device is stored in correspondence with the instruction list to be executed of the terminal device.
Step S103, the server returns the instruction to be executed corresponding to the identifier of the terminal device to the terminal device, so that the terminal device can execute the instruction to be executed.
Step S104, based on the request received from the control end, the service end puts the long connection establishment instruction into the instruction list to be executed so as to establish long connection between the service end and the terminal equipment, and receives the long connection establishment request from the control end, so that the service end and the control end establish long connection.
In the embodiment of the description, the terminal device obtains the instruction cached by the control end at the server end by receiving the request of obtaining the instruction from the terminal device within the preset time, and the terminal device executes the instruction, so that the purpose of controlling the terminal device is achieved, and the control end can better control the terminal device. Based on the received request from the control end, the instruction for establishing the long connection can be put into an instruction list to be executed, so that the long connection is established between the service end and the terminal equipment, the long connection is established between the service end and the control end, the instruction sent by the control end can be forwarded to the terminal equipment in real time, and the terminal equipment responds to the instruction of the control end in real time.
Corresponding to the above embodiments, fig. 2 is a schematic flow chart of a remote control method for a terminal device provided in the second embodiment of this specification.
The present embodiment may be implemented by the server side, and specifically includes:
step S201, in a preset time, a server receives a request message sent by a terminal device to acquire an instruction to be executed, where the request message includes a device identifier of the terminal device.
In step S201 of the embodiment of the present specification, the preset time may be dynamically set according to specific requirements. And the server provides an interface for modifying the instruction list to be executed so that the control end can call the interface and dynamically modify the instruction list to be executed. The modification includes addition, reduction or change, and the instruction to be executed of each terminal device may be multiple.
Step S202, according to the request message, the server determines the device identifier of the terminal device, and queries a pre-cached instruction list to be executed based on the device identifier, wherein the device identifier of the terminal device is stored in correspondence with the instruction list to be executed of the terminal device.
In step S202 in this embodiment of the present specification, the server may store the device identifier and the instruction list to be executed corresponding to the device identifier in a database, so as to prevent the server from losing data when the server is powered off. The instruction list to be executed stores a plurality of instructions to be executed, and the plurality of instructions to be executed may be instructions to be executed that are returned to a plurality of terminal devices, or may be instructions to be executed that are returned to one terminal device.
Step S203, the server returns the to-be-executed instruction corresponding to the identifier of the terminal device to the terminal device, so that the terminal device executes the to-be-executed instruction.
In step S203 of this specification embodiment, the instruction to be executed by the terminal device is an instruction that is cached in the server by the control end in advance, and only when the terminal device sends request information for acquiring the instruction to be executed to the server, the server will return the instruction to be executed corresponding to the identifier of the terminal device to the terminal device, and the terminal device executes the instruction to be executed after acquiring the instruction to be executed. The instruction to be executed at least comprises one or more of establishing long connection, disconnecting long connection, obtaining terminal equipment information, uploading logs, uploading coordinates and upgrading versions.
In the above step, for scenario one, an operator operates the control end to modify the to-be-executed instruction list, where the to-be-executed instruction list may include multiple instructions, and the server receives the modified to-be-executed instruction list sent by the control end. And in the set time, the terminal equipment requests a to-be-executed instruction list, the server side inquires whether an instruction containing the identifier of the terminal equipment exists, and if so, the server side returns a corresponding to-be-executed instruction list to the terminal equipment.
Step S204, based on the request received from the control end, the service end puts the long connection establishment instruction into the instruction list to be executed, so that the service end establishes long connection with the terminal device, and receives the long connection establishment request from the control end, so that the service end establishes long connection with the control end.
In step S204 in this embodiment of the present description, when the control end needs the terminal device to execute the issued instruction in real time, it is necessary to establish a long connection between the service end and the terminal device, and establish a long connection between the service end and the control end. The server side puts the instruction for establishing long connection into the instruction list to be executed, so that the terminal device and the server side establish long connection. It should be noted that the time for the server to establish the long connection with the control end may occur before the server establishes the long connection with the terminal device, or may occur after the server establishes the long connection with the terminal device, which is not limited in this specification.
In step S204 in this embodiment of the present description, the server receives a request for establishing a long connection from the control end, so that after the server establishes a long connection with the control end, the server may further store an identifier of the terminal device in a first long connection maintenance list; storing the identifier of the control end into a second long connection maintenance list; and the first long connection maintenance list and the second long connection maintenance list are correspondingly stored.
Step S205, the server receives the information sent by the control end, and obtains the identifier of the terminal device and the instruction to be executed corresponding to the identifier of the terminal device according to the information.
Step S206, searching the long connection maintenance list according to the obtained identifier of the terminal equipment, and sending the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment through long connection so that the terminal equipment can execute the instruction to be executed corresponding to the identifier of the terminal equipment in real time.
In step S206 in this embodiment of the present description, in a state that a long connection has been established between a terminal device and a server, and a long connection has been established between the server and a control terminal, the control terminal sends a to-be-executed instruction corresponding to an identifier of the terminal device and the identifier of the terminal device to the server, the server searches for a long connection maintenance list, and if the identifier of the terminal device exists in the long connection maintenance list, the server forwards the to-be-executed instruction to the terminal device corresponding to the identifier of the terminal device in a long connection manner, so that the terminal device executes the to-be-executed instruction in real time.
Step S204-step S206, aiming at the second scene, the operator operates the control end, adds the instruction for establishing the long connection into the instruction list to be executed, and the server end receives the instruction for establishing the long connection with the terminal equipment, which is sent by the control end. Within a set time, the terminal equipment requests a list of instructions to be executed, the server inquires an instruction of an identifier of the terminal equipment, and returns an instruction for establishing long connection to the terminal equipment, so that the long connection between the control terminal and the server is completed, and the long connection between the server and the terminal equipment is established.
The server receives a request for establishing long connection from the control terminal, so that after the server establishes long connection with the control terminal, the method further comprises:
and the server receives a first protocol sent by the control terminal so as to judge whether the server establishes long connection with the terminal equipment or not through the first protocol.
The server receives a request for establishing long connection from the control terminal, so that after the server establishes long connection with the control terminal, the method further comprises:
and the server receives a second protocol sent by the plurality of control terminals, so that the plurality of control terminals monitor the terminal equipment through the second protocol. The terminal device and the server have established long connection, and the control end monitoring the terminal device may be the control end establishing long connection with the server or the control end not establishing long connection with the server. In addition, the control end can also monitor a plurality of terminal devices establishing long connection. When the terminal device that establishes the long connection sends data through the long connection, the data is forwarded to all control terminals that monitor the terminal device.
When the instruction to be executed corresponding to the identifier of the terminal equipment is to disconnect long connection; after the instruction to be executed corresponding to the identifier of the terminal device is sent to the terminal device through the long connection, the method further includes:
the server side disconnects with the terminal equipment, the server side disconnects with the control side, the identifier of the terminal equipment in the first long connection maintenance list and the identifier of the control side in the second long connection maintenance list are deleted, and the monitoring relation of the plurality of control sides to the terminal equipment is relieved.
The server receives a request for establishing long connection from the control terminal, so that after the server establishes long connection with the control terminal, the method further comprises:
the server receives a third protocol sent by the control end, so that the transmission mode of the instruction to be executed corresponding to the identifier of the terminal equipment is changed into a mode that the request information for acquiring the instruction to be executed is sent to the server through the terminal equipment within a preset time, and the server returns the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment after receiving the request information for acquiring the instruction to be executed sent by the terminal equipment. It should be noted that, in a state where the terminal device establishes the long connection with the server and the server establishes the long connection with the control end, the instruction to be executed may not be directly forwarded through the third protocol, but the terminal device is required to send request information for acquiring the instruction to be executed within a preset time.
It should be noted that the first protocol, the second protocol, and the third protocol may be control codes sent by the control end to the service end, and corresponding instructions are executed through the service end.
It should be noted that in this embodiment of the present specification, the control end includes one or more of a PC end browser, a PC end control program, third-party software that can perform communication at the PC end, a mobile end browser, a mobile end APP, or an applet.
It should be noted that, in this embodiment of the present specification, the control end may send different device identifiers and instructions to be executed to the service end, and the service end may select different terminal devices to forward according to the device identifiers, so that single-station communication and group broadcast of the terminal devices by the control end may be implemented.
One control method of the existing control end to the terminal is as follows: the server caches the control end instruction and waits for the active request of the terminal equipment, the transmission of the control end instruction depends on the active request of the terminal equipment, and the time of the active request of the terminal equipment is uncertain, so that the task with higher real-time requirement cannot be met. Another existing control method for a terminal by a control end is as follows: the way that the terminal equipment establishes long connection with the server and the server forwards the control end instruction means that the server needs to maintain the long connection with the control end and the terminal equipment in real time, and the server resources are wasted and certain pressure is caused on the terminal equipment under the condition that real-time communication is not needed. Compared with the prior art, the embodiment of the specification requests the terminal equipment to acquire the instruction at regular time under the conventional condition, and the control end can modify, add or delete the instruction through the server-end interface, so that non-real-time control is realized; for tasks with higher real-time requirements, the real-time control of a control end on a plurality of devices is realized by dynamically establishing long connection and forwarding at a server end; when the communication is finished, the long connection is disconnected, so that the resource waste caused by maintaining the long connection is avoided; the group broadcast and the single real-time communication to the terminal equipment can be selected according to the requirements, and the reduction of the power consumption and the network flow of the terminal equipment is facilitated.
In the embodiment of the description, the terminal device obtains the instruction cached by the control end at the server end by receiving the request of obtaining the instruction from the terminal device within the preset time, and the terminal device executes the instruction, so that the purpose of controlling the terminal device is achieved, and the control end can better control the terminal device. Based on the received request from the control end, the instruction for establishing the long connection can be put into an instruction list to be executed, so that the long connection is established between the service end and the terminal equipment, the long connection is established between the service end and the control end, the instruction sent by the control end can be forwarded to the terminal equipment in real time, and the terminal equipment responds to the instruction of the control end in real time.
Corresponding to the above embodiment, fig. 3 is a schematic structural diagram of a remote control device of a terminal device provided in the third embodiment of this specification, and specifically includes: a receiving unit 1, a determining unit 2 and an executing unit 3.
The receiving unit 1 is used for the server side to receive a request message for acquiring a command to be executed, which is sent by the terminal device, within a preset time; the request message includes a device identifier of the terminal device.
The determining unit 2 is configured to determine a device identifier of the terminal device according to the request message, and query a pre-cached instruction list to be executed based on the device identifier, where the device identifier of the terminal device is stored in correspondence with the instruction list to be executed by the terminal device; and returning the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment so as to facilitate the terminal equipment to execute the instruction to be executed.
The execution unit 3 is configured to, based on receiving a request from the control end, put a long connection establishment instruction into the instruction list to be executed, so that the service end establishes a long connection with the terminal device; and receiving a request for establishing long connection from the control terminal, so that the service terminal and the control terminal establish long connection.
In the embodiment of the description, the terminal device obtains the instruction cached by the control end at the server end by receiving the request of obtaining the instruction from the terminal device within the preset time, and the terminal device executes the instruction, so that the purpose of controlling the terminal device is achieved, and the control end can better control the terminal device. Based on the received request from the control end, the instruction for establishing the long connection can be put into the instruction list to be executed, so that the long connection is established between the service end and the terminal equipment, the long connection is established between the service end and the control end, the instruction issued by the control end can be forwarded to the terminal equipment in real time, and the terminal equipment responds to the instruction of the control end in real time.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Hardware Description Language), traffic, pl (core universal Programming Language), HDCal (jhdware Description Language), lang, Lola, HDL, laspam, hardward Description Language (vhr Description Language), vhal (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functionality of the units may be implemented in one or more software and/or hardware when implementing the present application.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices, or any other non-transmission medium which can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that 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 an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The application may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The application may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only an example of the present application and is not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (9)

1. A remote control method for a terminal device, the method comprising:
in a preset time, the server receives a request message for acquiring a command to be executed, which is sent by the terminal equipment; the request message comprises a device identifier of the terminal device;
determining the equipment identifier of the terminal equipment according to the request message, and inquiring a pre-cached instruction list to be executed based on the equipment identifier; the device identifier of the terminal device is stored corresponding to the instruction list to be executed by the terminal device; returning the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment so that the terminal equipment can execute the instruction to be executed conveniently;
based on the received request from the control terminal, putting a long connection establishing instruction into the instruction list to be executed so that the service terminal and the terminal equipment establish long connection; receiving a request for establishing long connection from the control terminal, so that the service terminal and the control terminal establish long connection;
receiving information sent by the control terminal, and obtaining an identifier of the terminal equipment and a to-be-executed instruction corresponding to the identifier of the terminal equipment according to the information;
searching a long connection maintenance list according to the terminal equipment identifier;
if the identifier of the terminal equipment exists in the long connection maintenance list, sending the to-be-executed instruction corresponding to the identifier of the terminal equipment to the terminal equipment in a long connection mode, so that the terminal equipment executes the to-be-executed instruction corresponding to the identifier of the terminal equipment in real time, and after the to-be-executed instruction is executed, returning a result to the server through long connection, returning the result to the control end through long connection by the server, sending an instruction for disconnecting the long connection to the server by the control end, and forwarding the instruction for disconnecting the long connection to the terminal equipment by the server.
2. The method according to claim 1, wherein after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further comprises:
storing the identifier of the terminal equipment into a first long connection maintenance list; storing the identifier of the control end into a second long connection maintenance list; and the first long connection maintenance list and the second long connection maintenance list are correspondingly stored.
3. The method of claim 1, further comprising:
and the server provides an interface for modifying the instruction list to be executed so that the control end calls the interface to dynamically modify the instruction list to be executed.
4. The method according to claim 1, wherein before querying a pre-cached list of instructions to be executed based on the device identifier, the method further comprises:
and storing the device identifier and the list of the instructions to be executed corresponding to the device identifier in a database.
5. The method according to claim 1, wherein after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further comprises:
and the server receives a first protocol sent by the control terminal so as to judge whether the server establishes long connection with the terminal equipment or not through the first protocol.
6. The method according to claim 2, wherein after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further comprises:
and the server receives a second protocol sent by the plurality of control terminals, so that the plurality of control terminals monitor the terminal equipment through the second protocol.
7. The remote control method of the terminal device according to claim 6, wherein when the command to be executed corresponding to the identifier of the terminal device is to disconnect a long connection; after the instruction to be executed corresponding to the identifier of the terminal device is sent to the terminal device through the long connection, the method further includes:
the server side disconnects with the terminal equipment, the server side disconnects with the control side, the identifier of the terminal equipment in the first long connection maintenance list and the identifier of the control side in the second long connection maintenance list are deleted, and the monitoring relation of the plurality of control sides to the terminal equipment is relieved.
8. The method according to claim 1, wherein after receiving the request for establishing the long connection from the control end, so that the server end establishes the long connection with the control end, the method further comprises:
the server receives a third protocol sent by the control end, so that the transmission mode of the instruction to be executed corresponding to the identifier of the terminal equipment is changed into a mode that the request information for acquiring the instruction to be executed is sent to the server through the terminal equipment within a preset time, and the server returns the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment after receiving the request information for acquiring the instruction to be executed sent by the terminal equipment.
9. An apparatus for remote control of a terminal device, the apparatus comprising:
the server side receives a request message for acquiring the instruction to be executed, which is sent by the terminal equipment, within the preset time; the request message comprises a device identifier of the terminal device;
a determining unit, configured to determine a device identifier of the terminal device according to the request message, and query a pre-cached instruction list to be executed based on the device identifier, where the device identifier of the terminal device is stored in correspondence with the instruction list to be executed by the terminal device; returning the instruction to be executed corresponding to the identifier of the terminal equipment to the terminal equipment so that the terminal equipment can execute the instruction to be executed conveniently;
the execution unit is used for putting a long connection establishing instruction into the instruction list to be executed based on the received request from the control end so as to establish long connection between the service end and the terminal equipment; receiving a request for establishing long connection from the control terminal, so that the service terminal and the control terminal establish long connection, receiving information sent by the control terminal, obtaining a to-be-executed instruction corresponding to an identifier of a terminal device according to the information, searching a long connection maintenance list according to the identifier of the terminal device, sending the to-be-executed instruction corresponding to the identifier of the terminal device to the terminal device in a long connection mode if the identifier of the terminal device is stored in the long connection maintenance list, so that the terminal device executes the to-be-executed instruction corresponding to the identifier of the terminal device in real time, and returns a result to the service terminal through long connection after the to-be-executed instruction is executed, the service terminal returns a result to the control terminal through long connection, and the control terminal sends a command for disconnecting long connection to the service terminal, and the server forwards a command of disconnecting the long connection to the terminal equipment.
CN201911414689.1A 2019-12-31 2019-12-31 Remote control method and device for terminal equipment Active CN111163171B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911414689.1A CN111163171B (en) 2019-12-31 2019-12-31 Remote control method and device for terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911414689.1A CN111163171B (en) 2019-12-31 2019-12-31 Remote control method and device for terminal equipment

Publications (2)

Publication Number Publication Date
CN111163171A CN111163171A (en) 2020-05-15
CN111163171B true CN111163171B (en) 2022-08-05

Family

ID=70559981

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911414689.1A Active CN111163171B (en) 2019-12-31 2019-12-31 Remote control method and device for terminal equipment

Country Status (1)

Country Link
CN (1) CN111163171B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114390087A (en) * 2021-12-16 2022-04-22 航天信息股份有限公司 Control method and system for data acquisition equipment of tax-control oiling machine

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104811478A (en) * 2015-03-27 2015-07-29 上海斐讯数据通信技术有限公司 Remote control system and method of wireless terminal equipment
EP2950570A1 (en) * 2014-05-27 2015-12-02 Panasonic Intellectual Property Management Co., Ltd. Remote imaging method and remote imaging control device
CN105704157A (en) * 2016-04-08 2016-06-22 上海卓易科技股份有限公司 Remote control method and system, intelligent terminal and service terminal application to remote control method and system
CN109799719A (en) * 2019-01-31 2019-05-24 广东美的制冷设备有限公司 Control method, server, household appliance and the storage medium of household appliance

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5474644B2 (en) * 2010-04-14 2014-04-16 株式会社ソニー・コンピュータエンタテインメント Server connection method, server, and remote operation system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2950570A1 (en) * 2014-05-27 2015-12-02 Panasonic Intellectual Property Management Co., Ltd. Remote imaging method and remote imaging control device
CN104811478A (en) * 2015-03-27 2015-07-29 上海斐讯数据通信技术有限公司 Remote control system and method of wireless terminal equipment
CN105704157A (en) * 2016-04-08 2016-06-22 上海卓易科技股份有限公司 Remote control method and system, intelligent terminal and service terminal application to remote control method and system
CN109799719A (en) * 2019-01-31 2019-05-24 广东美的制冷设备有限公司 Control method, server, household appliance and the storage medium of household appliance

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Web-based remote networked control for smart homes;LEI Zhongcheng;《 Proceedings of the 32nd Chinese Control Conference》;20131021;全文 *
基于"互联网+"智能家居的远程控制实现;许冰昕;《智能计算机与应用》;20161111;全文 *

Also Published As

Publication number Publication date
CN111163171A (en) 2020-05-15

Similar Documents

Publication Publication Date Title
KR102513998B1 (en) Communication methods and devices, entities and computer readable storage media
CN108959341B (en) Data synchronization method, device and equipment
CN104714835A (en) Data access processing method and device
CN110765165B (en) Method, device and system for synchronously processing cross-system data
CN109561128B (en) Data transmission method and device
CN111163171B (en) Remote control method and device for terminal equipment
CN114710549B (en) Dynamic management method, system and service node for network card in container platform
CN111294377A (en) Network request sending method of dependency relationship, terminal device and storage medium
CN116107999B (en) Database service and storage system and method
CN107704502B (en) Routing method, device, equipment and system
CN112596780A (en) Service execution method and device
CN114625410A (en) Request message processing method, device and equipment
CN108809763B (en) Network performance parameter acquisition method, terminal device and storage medium
CN112187759A (en) Cross-network data transmission method and device
CN113761400A (en) Access request forwarding method, device and equipment
CN117093161B (en) Memory management system, method, medium and equipment based on optical transceiver chip
CN115174587B (en) Data transmission system, method and device, computer readable storage medium and electronic equipment
CN115599845B (en) Service execution method, device, storage medium and electronic equipment
CN114237837B (en) Program calling method, program calling device, program calling equipment and computer readable storage medium
CN114401302B (en) Linkage action execution method, linkage action execution device and storage medium
CN111124923B (en) Running state query method and device, server equipment and storage medium
WO2024099274A1 (en) Data processing method, device, and storage medium
CN117883789B (en) Data acquisition method, apparatus, device, readable storage medium, and program product
CN113836405B (en) Information query method, device and computer readable storage medium
CN114268653B (en) Equipment calling method, device, equipment, medium and product

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
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Yu Jian

Inventor after: Liu Zaiping

Inventor after: Xu Baojin

Inventor after: Tang Kun

Inventor before: Yu Jian

Inventor before: Wang Limin

Inventor before: Liu Zaiping

Inventor before: Xu Baojin

Inventor before: Tang Kun

GR01 Patent grant
GR01 Patent grant