CN110231785A - A kind of method and device based on terminal control multiple devices - Google Patents

A kind of method and device based on terminal control multiple devices Download PDF

Info

Publication number
CN110231785A
CN110231785A CN201910374530.5A CN201910374530A CN110231785A CN 110231785 A CN110231785 A CN 110231785A CN 201910374530 A CN201910374530 A CN 201910374530A CN 110231785 A CN110231785 A CN 110231785A
Authority
CN
China
Prior art keywords
control instruction
equipment
subsidiary engine
instruction
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.)
Pending
Application number
CN201910374530.5A
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.)
Guangzhou Lango Electronic Science and Technology Co Ltd
Original Assignee
Guangzhou Lango Electronic Science and 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 Guangzhou Lango Electronic Science and Technology Co Ltd filed Critical Guangzhou Lango Electronic Science and Technology Co Ltd
Priority to CN201910374530.5A priority Critical patent/CN110231785A/en
Publication of CN110231785A publication Critical patent/CN110231785A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers
    • G05B19/042Programme control other than numerical control, i.e. in sequence controllers or logic controllers using digital processors
    • G05B19/0423Input/output
    • GPHYSICS
    • G08SIGNALLING
    • G08CTRANSMISSION SYSTEMS FOR MEASURED VALUES, CONTROL OR SIMILAR SIGNALS
    • G08C17/00Arrangements for transmitting signals characterised by the use of a wireless electrical link
    • G08C17/02Arrangements for transmitting signals characterised by the use of a wireless electrical link using a radio link
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B2219/00Program-control systems
    • G05B2219/20Pc systems
    • G05B2219/25Pc structure of the system
    • G05B2219/25257Microcontroller

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Selective Calling Equipment (AREA)

Abstract

The invention discloses a kind of method and devices based on terminal control multiple devices, wherein the described method includes: generating control instruction based on terminal, and the end IN based on data transmission interface sends control instruction to host equipment;Host equipment parses and executes the control instruction, and forwards control instruction to the end IN of the data transmission interface of series connection subsidiary engine equipment based on the OUT terminal of data transmission interface;The subsidiary engine equipment parses and executes control instruction, judges whether the subsidiary engine equipment is in series with next subsidiary engine equipment;If being in series with next subsidiary engine equipment, subsidiary engine equipment forwards the control instruction to the end IN of the data transmission interface of concatenated next subsidiary engine equipment based on the OUT terminal of data transmission interface;Until having executed the control instruction with the concatenated all subsidiary engine equipment of host equipment.In embodiments of the present invention, equipment cost, improve data transfer efficiency and mistake or data loss probability in reduction transmission process can be reduced.

Description

A kind of method and device based on terminal control multiple devices
Technical field
The present invention relates to instruction control technology field more particularly to a kind of methods and dress based on terminal control multiple devices It sets.
Background technique
With the development of network technology and radio network technique (wife), adopted between existing many equipment and equipment Those corresponding connections with the mode of wireless network or Ethernet, so, it is necessary to build one or more routing Device equipment carries out the connection between equipment and equipment, or bridge joint;So, communication connection between equipment and equipment Higher cost, and data (instruction) is carried out by wife or Ethernet and is sent, it needs to forward by router, it is understood that there may be number It can not be reached at the first time according to (instruction), and there may be in repeating process, the fortuitous events such as data (instruction) are lost.
Summary of the invention
It is an object of the invention to overcome the deficiencies in the prior art, the present invention provides one kind to be set based on terminal control more Standby method and device can reduce equipment cost, improve data transfer efficiency and mistake or number in reduction transmission process According to losing probability.
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of sides based on terminal control multiple devices Method, which comprises
Control instruction is generated based on terminal, and the end IN based on data transmission interface sends the control to host equipment and refers to It enables;
The host equipment parses and executes the control instruction, and auxiliary to connecting based on the OUT terminal of data transmission interface The end IN of the data transmission interface of machine equipment forwards the control instruction;
The subsidiary engine equipment parses and executes the control instruction, and it is next auxiliary to judge whether the subsidiary engine equipment is in series with Machine equipment;
If being in series with next subsidiary engine equipment, the subsidiary engine equipment is based on the OUT terminal of data transmission interface to concatenated The end IN of the data transmission interface of next subsidiary engine equipment forwards the control instruction;
Until having executed the control instruction with the concatenated all subsidiary engine equipment of the host equipment.
Optionally, the method also includes:
The subsidiary engine equipment is after having executed the control instruction, the IN of the subsidiary engine equipment based on data transmission interface The OUT terminal to upper level subsidiary engine equipment is held to feed back the execution information of the control instruction, until the execution information feeds back to institute State host equipment.
Optionally, the execution information includes implementing result and equipment ID number.
Optionally, the host equipment parses and executes the control instruction, comprising:
The host equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction Type;
The host equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to pair The execution module answered is executed, and implementing result is fed back to host equipment.
Optionally, the subsidiary engine equipment parses and executes the control instruction, comprising:
The subsidiary engine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction Type;
The subsidiary engine equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to pair The execution module answered is executed, and implementing result is fed back to subsidiary engine equipment;
The subsidiary engine equipment is based on the implementing result and device id generates execution information.
It is optionally, described that control instruction is generated based on terminal, comprising:
The terminal generates the control instruction that can be sent by data transmission interface based on user in operation interface operation;Or,
The terminal is based on network connection and receives networking command, and place networking command is converted to can be by data transmission interface The control instruction of transmission.
Optionally, the control instruction includes that volume adjustment instruction, voice queries instruction, brightness control instruction, brightness are looked into Ask instruction, booting or shutdown command, information source switching command and information source inquiry instruction.
Optionally, the data transmission interface is asynchronous transmission standard interface.
In addition, the embodiment of the invention also provides a kind of system based on terminal control multiple devices, the system comprises:
Terminal: the end IN for generating control instruction, and based on data transmission interface sends the control to host equipment Instruction;
Host equipment: for parsing and executing the control instruction, and it is auxiliary to connecting based on the OUT terminal of data transmission interface The end IN of the data transmission interface of machine equipment forwards the control instruction;
Subsidiary engine equipment: for parsing and executing the control instruction, it is next to judge whether the subsidiary engine equipment is in series with Subsidiary engine equipment;If being in series with next subsidiary engine equipment, set based on the OUT terminal of data transmission interface to concatenated next subsidiary engine The end IN of standby data transmission interface forwards the control instruction;Until being held with the concatenated all subsidiary engine equipment of the host equipment The control instruction is gone.
Optionally, the subsidiary engine equipment is also used to after having executed the control instruction, based on data transmission interface The execution information of the control instruction is fed back at the end IN to the OUT terminal of upper level subsidiary engine equipment, until the execution information is fed back to The host equipment.
In embodiments of the present invention, host equipment and subsidiary engine set and subsidiary engine equipment and subsidiary engine equipment between pass through Serial Port Line Connection, terminal is also to be connect by Serial Port Line with host equipment, and control instruction and execution information are transmitted by Serial Port Line, Equipment cost, improve data transfer efficiency and mistake or data loss probability in reduction transmission process can be reduced.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it is clear that, the accompanying drawings in the following description is only this Some embodiments of invention for those of ordinary skill in the art without creative efforts, can be with Other attached drawings are obtained according to these attached drawings.
Fig. 1 is the flow diagram of the method based on terminal control multiple devices in the embodiment of the present invention;
Fig. 2 is the flow diagram of the method based on terminal control multiple devices in another embodiment of the present invention;
Fig. 3 is the structure composition schematic diagram of the system based on terminal control multiple devices in the embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts all other Embodiment shall fall within the protection scope of the present invention.
Embodiment
Referring to Fig. 1, Fig. 1 is the process signal of the method based on terminal control multiple devices in the embodiment of the present invention Figure.
As shown in Figure 1, a kind of method based on terminal control multiple devices, which comprises
S11: control instruction is generated based on terminal, and the end IN based on data transmission interface sends the control to host equipment System instruction;
It is described that control instruction is generated based on terminal in specific implementation process of the present invention, comprising: the terminal is based on user The control instruction that can be sent by data transmission interface is generated in operation interface operation;It is received or, the terminal is based on network connection Place networking command is converted to the control instruction that can be sent by data transmission interface by networking command.
Further, the control instruction includes volume adjustment instruction, voice queries instruction, brightness control instruction, brightness Inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction.
Specifically, terminal (master control) can be mobile phone terminal, PC terminal or tablet terminal etc., the number of mark can be passed through It is connected according to interface Serial Port Line with host equipment, also or terminal is host equipment itself;Terminal has raw for user's operation Interface or operation input equipment at control instruction, such as keyboard, mouse input equipment, operation interface such as APP operation interface Or web page operation interface etc., i.e., terminal is based on user can be transmitted in operation interface or the generation of operation input equipment operation by data The control instruction that interface is sent.
Terminal can also by directly by internet it is received in a manner of, receive other terminal remotes operation networking command, so The networking command is transformed into the control instruction that can be sent by data transmission interface afterwards;And the company between terminal and host Connecing is RS232 (asynchronous transmission standard interface) the realization connection that both sides are connected by Serial Port Line.
Control instruction includes volume adjustment instruction, voice queries instruction, brightness control instruction, brightness inquiry instruction, opens Machine or shutdown command, information source switching command and information source inquiry instruction etc.;Volume adjustment instruction adds deduct or mute for volume; Voice queries instruction for inquire whether mute or current volume etc.;Booting or shutdown command are for controlling facility switching machine; Information source switching command is for switching current signal source;Information source inquiry instruction is for inquiring current signal source;Brightness control refers to Order adds deduct for adjusting present intensity;Brightness inquiry instruction is for inquiring present intensity value.
Then the end IN in Serial Port Line control instruction connected by data transmission interface is sent to host equipment.
Here, transmitting relationship by the control instruction between Serial Port Line connection terminal (master control) and host equipment, effectively Guarantee the problems such as no instruction is lost in instruction efficiency of transmission and transmission process.
S12: the host equipment parses and executes the control instruction, and based on the OUT terminal of data transmission interface to string The end IN for joining the data transmission interface of subsidiary engine equipment forwards the control instruction;
In specific implementation process of the present invention, the host equipment parses and executes the control instruction, comprising: the master Machine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction type;The host Equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to corresponding execution module and is carried out It executes, and implementing result is fed back into host equipment.
Specifically, the related chip module inside host equipment is first first after host equipment receives control instruction The control instruction is first parsed, to obtain instruction type corresponding to the control instruction, such as belongs to volume adjustment instruction, sound is looked into Ask instruction, brightness control instruction, brightness inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction Any one in;The control instruction is sent to corresponding execution module by the then instruction type according to belonging to the instruction On executed, then implementing result is fed back, for example belong to volume adjustment instruction, then the control instruction is sent to volume tune It saves in module, volume adjustment setting is carried out according to the volume adjusted needed for instruction, it is 30 (set voluem that such as instruction, which adjusts volume, =30), current volume is adjusted to 30 by volume adjusting module, then feeds back the result of adjusting, and the content of feedback includes as follows Information volume=30 etc..
During host equipment executes control instruction or after the control instruction that is finished, host equipment and subsidiary engine Equipment is realized by Serial Port Line connection RS232 (asynchronous transmission standard interface) and is connected in series;The OUT that host equipment passes through Serial Port Line The end IN to the subsidiary engine equipment being cascaded is held to send the control instruction.
S13: the subsidiary engine equipment parses and executes the control instruction;
In specific implementation process of the present invention, the subsidiary engine equipment parses and executes the control instruction, comprising: described auxiliary Machine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction type;The subsidiary engine Equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to corresponding execution module and is carried out It executes, and implementing result is fed back into subsidiary engine equipment;The subsidiary engine equipment is based on the implementing result and device id generation is held Row information.
Specifically, the related chip module inside subsidiary engine equipment is first first after subsidiary engine equipment receives control instruction The control instruction is first parsed, to obtain instruction type corresponding to the control instruction, such as belongs to volume adjustment instruction, sound is looked into Ask instruction, brightness control instruction, brightness inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction Any one in;The control instruction is sent to corresponding execution module by the then instruction type according to belonging to the instruction On executed, then implementing result is fed back, for example belong to volume adjustment instruction, then the control instruction is sent to volume tune It saves in module, volume adjustment setting is carried out according to the volume adjusted needed for instruction, it is 30 (set voluem that such as instruction, which adjusts volume, =30), current volume is adjusted to 30 by volume adjusting module, then feeds back the result of adjusting, and the content of feedback includes as follows Information volume=30 etc..
It include that implementing result and the subsidiary engine device id, the subsidiary engine are set in the feedback content (execution information) of subsidiary engine equipment Standby ID is uniquely, for distinguishing different subsidiary engine equipment.
S14: judge whether the subsidiary engine equipment is in series with next subsidiary engine equipment;
In specific implementation process of the present invention, which passes through detection itself RS232 (asynchronous transmission standard interface) OUT terminal level signal to determine whether being connected in series with next subsidiary engine equipment;By detecting itself RS232 (asynchronous biography Defeated standard interface) OUT terminal whether be high level, be then judged as if high level and be in series with next subsidiary engine equipment;If low Level, which is then judged as, is not in series with next subsidiary engine equipment.
S15: if being in series with next subsidiary engine equipment, the subsidiary engine equipment is based on the OUT terminal of data transmission interface to string The end IN of the data transmission interface of next subsidiary engine equipment of connection forwards the control instruction;
In specific implementation process of the present invention, after detecting with concatenated next subsidiary engine equipment, subsidiary engine equipment The control is sent to the end IN of the data transmission interface of concatenated next subsidiary engine equipment in OUT terminal by data transmission interface to refer to It enables, the control instruction of transmission refers to without any modification, and the control that forwarding host equipment or upper subsidiary engine equipment are sent It enables.
S16: until having executed the control instruction with the concatenated all subsidiary engine equipment of the host equipment;
In specific implementation process of the present invention, between host equipment and subsidiary engine equipment, passes sequentially through OUT terminal and forwarded to the end IN Control instruction is set until subsidiary engine equipment can not detect the Serial Port Line that OUT terminal has access there is no next subsidiary engine Until standby.
S17: for the subsidiary engine equipment after having executed the control instruction, the subsidiary engine equipment is based on data transmission interface The end IN the execution information of the control instruction is fed back to the OUT terminal of upper level subsidiary engine equipment, until the execution information is fed back To the host equipment.
In specific implementation process of the present invention, the execution information includes implementing result and equipment ID number.
Specifically, subsidiary engine equipment after having executed corresponding control instruction, generates corresponding execution information, then should Execution information is fed back by the end IN of the subsidiary engine equipment to the OUT terminal of the subsidiary engine equipment of upper level, and so on, step by step instead Feedback, finally feeds back to the execution information of each subsidiary engine equipment on host equipment;It is gathered around in host equipment and subsidiary engine equipment There is data transmission interface, which is RS232 (asynchronous transmission standard interface), also, the execution information includes holding Row result and device id.
In the specific implementation process, such as the classroom of school, the teaching equipment of classroom is passed through RS232 (asynchronous biography Defeated standard interface) it is connected using Serial Port Line, when needing to shut down after class, it can be sent by terminal to teaching equipment Shutdown command will can shut down simultaneously with other concatenated teaching equipments of the teaching equipment;Specifically, can be by concatenated teaching For any one equipment in equipment as host equipment, terminal is mobile phone terminal, PC terminal or tablet terminal etc., can pass through mark The data-interface Serial Port Line of note is connected with host equipment, and also or terminal is host equipment itself.
In embodiments of the present invention, host equipment and subsidiary engine set and subsidiary engine equipment and subsidiary engine equipment between pass through Serial Port Line Connection, terminal is also to be connect by Serial Port Line with host equipment, and control instruction and execution information are transmitted by Serial Port Line, Equipment cost, improve data transfer efficiency and mistake or data loss probability in reduction transmission process can be reduced.
Embodiment
Referring to Fig. 2, the process that Fig. 2 is the method based on terminal control multiple devices in another embodiment of the present invention is shown It is intended to.
As shown in Fig. 2, a kind of method based on terminal control multiple devices, which comprises
Terminal generates control instruction, and the end IN for being then based on asynchronous transmission standard interface is sent on host equipment;
Host equipment parses the control instruction, obtains the instruction type of the control instruction;
The instruction setup module, which is sent to, according to the instruction type of the control instruction executes the control instruction;
After the execution for completing the control instruction, implementing result is fed back into instruction setup module;
The OUT terminal for being then based on asynchronous transmission standard interface forwards (transmission) control instruction to the end IN of subsidiary engine equipment;
Subsidiary engine equipment parses the control instruction, obtains the instruction type of the control instruction;According to the instruction of the control instruction Type is sent to the instruction setup module and executes the control instruction;It is after the execution for completing the control instruction, implementing result is anti- It feeds and instructs setup module;Then execution information is generated to send (instead by the end IN of the subsidiary engine equipment to the OUT terminal of host equipment Feedback) execution information;
The subsidiary engine equipment is by detecting its OUT terminal with the presence or absence of access Serial Port Line to determine whether being in series with next subsidiary engine Equipment, if there is the subsidiary engine equipment to forward the control instruction to the end IN of next subsidiary engine equipment by OUT terminal, next subsidiary engine equipment It executes the control instruction and generates execution information, upward subsidiary engine equipment is fed back step by step, until feeding back to host equipment;With such It pushes away, which is forwarded to all concatenated subsidiary engine equipment and is executed, and feeds back execution information to host equipment.
Wherein the detailed implementation of each step please refers to above-described embodiment, and details are not described herein.
In embodiments of the present invention, host equipment and subsidiary engine set and subsidiary engine equipment and subsidiary engine equipment between pass through Serial Port Line Connection, terminal is also to be connect by Serial Port Line with host equipment, and control instruction and execution information are transmitted by Serial Port Line, Equipment cost, improve data transfer efficiency and mistake or data loss probability in reduction transmission process can be reduced.
Embodiment
Referring to Fig. 3, the structure composition that Fig. 3 is the system based on terminal control multiple devices in the embodiment of the present invention is shown It is intended to.
As shown in figure 3, a kind of system based on terminal control multiple devices, the system comprises:
Terminal 11: the end IN for generating control instruction, and based on data transmission interface sends the control to host equipment System instruction;
It is described that control instruction is generated based on terminal in specific implementation process of the present invention, comprising: the terminal is based on user The control instruction that can be sent by data transmission interface is generated in operation interface operation;It is received or, the terminal is based on network connection Place networking command is converted to the control instruction that can be sent by data transmission interface by networking command.
Further, the control instruction includes volume adjustment instruction, voice queries instruction, brightness control instruction, brightness Inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction.
Specifically, terminal (master control) can be mobile phone terminal, PC terminal or tablet terminal etc., the number of mark can be passed through It is connected according to interface Serial Port Line with host equipment, also or terminal is host equipment itself;Terminal has raw for user's operation Interface or operation input equipment at control instruction, such as keyboard, mouse input equipment, operation interface such as APP operation interface Or web page operation interface etc., i.e., terminal is based on user can be transmitted in operation interface or the generation of operation input equipment operation by data The control instruction that interface is sent.
Terminal can also by directly by internet it is received in a manner of, receive other terminal remotes operation networking command, so The networking command is transformed into the control instruction that can be sent by data transmission interface afterwards;And the company between terminal and host Connecing is RS232 (asynchronous transmission standard interface) the realization connection that both sides are connected by Serial Port Line.
Control instruction includes volume adjustment instruction, voice queries instruction, brightness control instruction, brightness inquiry instruction, opens Machine or shutdown command, information source switching command and information source inquiry instruction etc.;Volume adjustment instruction adds deduct or mute for volume; Voice queries instruction for inquire whether mute or current volume etc.;Booting or shutdown command are for controlling facility switching machine; Information source switching command is for switching current signal source;Information source inquiry instruction is for inquiring current signal source;Brightness control refers to Order adds deduct for adjusting present intensity;Brightness inquiry instruction is for inquiring present intensity value.
Then the end IN in Serial Port Line control instruction connected by data transmission interface is sent to host equipment.
Here, transmitting relationship by the control instruction between Serial Port Line connection terminal (master control) and host equipment, effectively Guarantee the problems such as no instruction is lost in instruction efficiency of transmission and transmission process.
Host equipment 12: for parsing and executing the control instruction, and based on the OUT terminal of data transmission interface to series connection The end IN of the data transmission interface of subsidiary engine equipment forwards the control instruction;
In specific implementation process of the present invention, the host equipment parses and executes the control instruction, comprising: the master Machine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction type;The host Equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to corresponding execution module and is carried out It executes, and implementing result is fed back into host equipment.
Specifically, the related chip module inside host equipment is first first after host equipment receives control instruction The control instruction is first parsed, to obtain instruction type corresponding to the control instruction, such as belongs to volume adjustment instruction, sound is looked into Ask instruction, brightness control instruction, brightness inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction Any one in;The control instruction is sent to corresponding execution module by the then instruction type according to belonging to the instruction On executed, then implementing result is fed back, for example belong to volume adjustment instruction, then the control instruction is sent to volume tune It saves in module, volume adjustment setting is carried out according to the volume adjusted needed for instruction, it is 30 (set voluem that such as instruction, which adjusts volume, =30), current volume is adjusted to 30 by volume adjusting module, then feeds back the result of adjusting, and the content of feedback includes as follows Information volume=30 etc..
During host equipment executes control instruction or after the control instruction that is finished, host equipment and subsidiary engine Equipment is realized by Serial Port Line connection RS232 (asynchronous transmission standard interface) and is connected in series;The OUT that host equipment passes through Serial Port Line The end IN to the subsidiary engine equipment being cascaded is held to send the control instruction.
Subsidiary engine equipment 13: for parsing and executing the control instruction, it is next to judge whether the subsidiary engine equipment is in series with A subsidiary engine equipment;If being in series with next subsidiary engine equipment, based on the OUT terminal of data transmission interface to concatenated next subsidiary engine The end IN of the data transmission interface of equipment forwards the control instruction;Until with the concatenated all subsidiary engine equipment of the host equipment The control instruction is executed.
In specific implementation process of the present invention, the subsidiary engine equipment parses and executes the control instruction, comprising: described auxiliary Machine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction type;The subsidiary engine Equipment is based on described instruction type and obtains corresponding execution module, and the control instruction is sent to corresponding execution module and is carried out It executes, and implementing result is fed back into subsidiary engine equipment;The subsidiary engine equipment is based on the implementing result and device id generation is held Row information.
Specifically, the related chip module inside subsidiary engine equipment is first first after subsidiary engine equipment receives control instruction The control instruction is first parsed, to obtain instruction type corresponding to the control instruction, such as belongs to volume adjustment instruction, sound is looked into Ask instruction, brightness control instruction, brightness inquiry instruction, booting or shutdown command, information source switching command and information source inquiry instruction Any one in;The control instruction is sent to corresponding execution module by the then instruction type according to belonging to the instruction On executed, then implementing result is fed back, for example belong to volume adjustment instruction, then the control instruction is sent to volume tune It saves in module, volume adjustment setting is carried out according to the volume adjusted needed for instruction, it is 30 (set voluem that such as instruction, which adjusts volume, =30), current volume is adjusted to 30 by volume adjusting module, then feeds back the result of adjusting, and the content of feedback includes as follows Information volume=30 etc..
It include that implementing result and the subsidiary engine device id, the subsidiary engine are set in the feedback content (execution information) of subsidiary engine equipment Standby ID is uniquely, for distinguishing different subsidiary engine equipment.
In specific implementation process of the present invention, which passes through detection itself RS232 (asynchronous transmission standard interface) OUT terminal level signal to determine whether being connected in series with next subsidiary engine equipment;By detecting itself RS232 (asynchronous biography Defeated standard interface) OUT terminal whether be high level, be then judged as if high level and be in series with next subsidiary engine equipment;If low Level, which is then judged as, is not in series with next subsidiary engine equipment.
In specific implementation process of the present invention, after detecting with concatenated next subsidiary engine equipment, subsidiary engine equipment The control is sent to the end IN of the data transmission interface of concatenated next subsidiary engine equipment in OUT terminal by data transmission interface to refer to It enables, the control instruction of transmission refers to without any modification, and the control that forwarding host equipment or upper subsidiary engine equipment are sent It enables.
In specific implementation process of the present invention, between host equipment and subsidiary engine equipment, passes sequentially through OUT terminal and forwarded to the end IN Control instruction is set until subsidiary engine equipment can not detect the Serial Port Line that OUT terminal has access there is no next subsidiary engine Until standby.
Further, the subsidiary engine equipment 13 is also used to after having executed the control instruction, is connect based on data transmission The execution information of the control instruction is fed back at the end IN of mouth to the OUT terminal of upper level subsidiary engine equipment, until the execution information is anti- It is fed to the host equipment.
In specific implementation process of the present invention, the execution information includes implementing result and equipment ID number.
Specifically, subsidiary engine equipment after having executed corresponding control instruction, generates corresponding execution information, then should Execution information is fed back by the end IN of the subsidiary engine equipment to the OUT terminal of the subsidiary engine equipment of upper level, and so on, step by step instead Feedback, finally feeds back to the execution information of each subsidiary engine equipment on host equipment;It is gathered around in host equipment and subsidiary engine equipment There is data transmission interface, which is RS232 (asynchronous transmission standard interface), also, the execution information includes holding Row result and device id.
In the specific implementation process, such as the classroom of school, the teaching equipment of classroom is passed through RS232 (asynchronous biography Defeated standard interface) it is connected using Serial Port Line, when needing to shut down after class, it can be sent by terminal to teaching equipment Shutdown command will can shut down simultaneously with other concatenated teaching equipments of the teaching equipment;Specifically, can be by concatenated teaching For any one equipment in equipment as host equipment, terminal is mobile phone terminal, PC terminal or tablet terminal etc., can pass through mark The data-interface Serial Port Line of note is connected with host equipment, and also or terminal is host equipment itself.
In embodiments of the present invention, host equipment and subsidiary engine set and subsidiary engine equipment and subsidiary engine equipment between pass through Serial Port Line Connection, terminal is also to be connect by Serial Port Line with host equipment, and control instruction and execution information are transmitted by Serial Port Line, Equipment cost, improve data transfer efficiency and mistake or data loss probability in reduction transmission process can be reduced.
Those of ordinary skill in the art will appreciate that all or part of the steps in the various methods of above-described embodiment is can It is completed with instructing relevant hardware by program, which can be stored in a computer readable storage medium, storage Medium may include: read-only memory (ROM, ReadOnly Memory), random access memory (RAM, Random Access Memory), disk or CD etc..
In addition, be provided for the embodiments of the invention above a kind of method and device based on terminal control multiple devices into It has gone and has been discussed in detail, herein should be using a specific example illustrates the principle and implementation of the invention, the above reality The explanation for applying example is merely used to help understand method and its core concept of the invention;Meanwhile for the general technology of this field Personnel, according to the thought of the present invention, there will be changes in the specific implementation manner and application range, in conclusion this theory Bright book content should not be construed as limiting the invention.

Claims (10)

1. a kind of method based on terminal control multiple devices, which is characterized in that the described method includes:
Control instruction is generated based on terminal, and the end IN based on data transmission interface sends the control instruction to host equipment;
The host equipment parses and executes the control instruction, and is set based on the OUT terminal of data transmission interface to series connection subsidiary engine The end IN of standby data transmission interface forwards the control instruction;
The subsidiary engine equipment parses and executes the control instruction, judges whether the subsidiary engine equipment is in series with next subsidiary engine and sets It is standby;
If being in series with next subsidiary engine equipment, the subsidiary engine equipment is based on the OUT terminal of data transmission interface to concatenated next The end IN of the data transmission interface of a subsidiary engine equipment forwards the control instruction;
Until having executed the control instruction with the concatenated all subsidiary engine equipment of the host equipment.
2. according to claim 1 the method based on terminal control multiple devices, which is characterized in that the method also includes:
The subsidiary engine equipment after having executed the control instruction, the subsidiary engine equipment based on the end IN of data transmission interface to The OUT terminal of upper level subsidiary engine equipment feeds back the execution information of the control instruction, until the execution information feeds back to the master Machine equipment.
3. the method according to claim 2 based on terminal control multiple devices, which is characterized in that the execution information packet Include implementing result and equipment ID number.
4. the method according to claim 1 based on terminal control multiple devices, which is characterized in that the host equipment solution It analyses and executes the control instruction, comprising:
The host equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction class Type;
The host equipment is based on described instruction type and obtains corresponding execution module, the control instruction is sent to corresponding Execution module is executed, and implementing result is fed back to host equipment.
5. the method according to claim 1 based on terminal control multiple devices, which is characterized in that the subsidiary engine equipment solution It analyses and executes the control instruction, comprising:
The subsidiary engine equipment parses the control instruction, and according to parsing result obtain the control instruction belonging to instruction class Type;
The subsidiary engine equipment is based on described instruction type and obtains corresponding execution module, the control instruction is sent to corresponding Execution module is executed, and implementing result is fed back to subsidiary engine equipment;
The subsidiary engine equipment is based on the implementing result and device id generates execution information.
6. the method according to claim 1 based on terminal control multiple devices, which is characterized in that described raw based on terminal At control instruction, comprising:
The terminal generates the control instruction that can be sent by data transmission interface based on user in operation interface operation;Or,
The terminal is based on network connection and receives networking command, and place networking command, which is converted to, to be sent by data transmission interface Control instruction.
7. the method according to claim 1 based on terminal control multiple devices, which is characterized in that the control instruction packet Include volume adjustment instruction, voice queries instruction, brightness control instruction, brightness inquiry instruction, booting or shutdown command, information source switching Instruction and information source inquiry instruction.
8. the method based on terminal control multiple devices described in -7 according to claim 1, which is characterized in that the data transmission Interface is asynchronous transmission standard interface.
9. a kind of system based on terminal control multiple devices, which is characterized in that the system comprises:
Terminal: the end IN for generating control instruction, and based on data transmission interface sends the control instruction to host equipment;
Host equipment: it is set for parsing and executing the control instruction, and based on the OUT terminal of data transmission interface to series connection subsidiary engine The end IN of standby data transmission interface forwards the control instruction;
Subsidiary engine equipment: for parsing and executing the control instruction, judge whether the subsidiary engine equipment is in series with next subsidiary engine Equipment;If being in series with next subsidiary engine equipment, based on the OUT terminal of data transmission interface to concatenated next subsidiary engine equipment The end IN of data transmission interface forwards the control instruction;Until having been executed with the concatenated all subsidiary engine equipment of the host equipment The control instruction.
10. the system according to claim 9 based on terminal control multiple devices, which is characterized in that the subsidiary engine equipment It is also used to after having executed the control instruction, OUT terminal of the end IN based on data transmission interface to upper level subsidiary engine equipment The execution information of the control instruction is fed back, until the execution information feeds back to the host equipment.
CN201910374530.5A 2019-05-05 2019-05-05 A kind of method and device based on terminal control multiple devices Pending CN110231785A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910374530.5A CN110231785A (en) 2019-05-05 2019-05-05 A kind of method and device based on terminal control multiple devices

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910374530.5A CN110231785A (en) 2019-05-05 2019-05-05 A kind of method and device based on terminal control multiple devices

Publications (1)

Publication Number Publication Date
CN110231785A true CN110231785A (en) 2019-09-13

Family

ID=67860417

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910374530.5A Pending CN110231785A (en) 2019-05-05 2019-05-05 A kind of method and device based on terminal control multiple devices

Country Status (1)

Country Link
CN (1) CN110231785A (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN201210249Y (en) * 2008-06-20 2009-03-18 刘艺洋 Mechanical control system for stage
CN103115536A (en) * 2013-02-08 2013-05-22 前进民爆股份有限公司 Digital electronic detonator large-scale priming system for engineering blasting and method thereof
CN103257642A (en) * 2013-04-28 2013-08-21 深圳市英威腾电气股份有限公司 Multiple-converter master-slave control system
CN103268094A (en) * 2013-04-28 2013-08-28 深圳市英威腾电气股份有限公司 Signal transmission method and frequency converter multi-machine master-auxiliary control system
CN204347561U (en) * 2014-03-26 2015-05-20 李雪峰 Based on the distributed monitor-control network of RS485 communication
CN105741528A (en) * 2014-12-09 2016-07-06 哈尔滨米米米业科技有限公司 Power line carrier communication technology-based light assistant landing system
CN107132833A (en) * 2016-02-26 2017-09-05 欧姆龙株式会社 Main frame, slave device and its control method, control program, error monitoring system
CN206523765U (en) * 2017-03-08 2017-09-26 信阳师范学院 LAN automatic control system based on PIC single chip microcomputer
CN108965448A (en) * 2018-07-27 2018-12-07 东莞铭普光磁股份有限公司 A kind of message transfer system and method

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN201210249Y (en) * 2008-06-20 2009-03-18 刘艺洋 Mechanical control system for stage
CN103115536A (en) * 2013-02-08 2013-05-22 前进民爆股份有限公司 Digital electronic detonator large-scale priming system for engineering blasting and method thereof
CN103257642A (en) * 2013-04-28 2013-08-21 深圳市英威腾电气股份有限公司 Multiple-converter master-slave control system
CN103268094A (en) * 2013-04-28 2013-08-28 深圳市英威腾电气股份有限公司 Signal transmission method and frequency converter multi-machine master-auxiliary control system
CN204347561U (en) * 2014-03-26 2015-05-20 李雪峰 Based on the distributed monitor-control network of RS485 communication
CN105741528A (en) * 2014-12-09 2016-07-06 哈尔滨米米米业科技有限公司 Power line carrier communication technology-based light assistant landing system
CN107132833A (en) * 2016-02-26 2017-09-05 欧姆龙株式会社 Main frame, slave device and its control method, control program, error monitoring system
CN206523765U (en) * 2017-03-08 2017-09-26 信阳师范学院 LAN automatic control system based on PIC single chip microcomputer
CN108965448A (en) * 2018-07-27 2018-12-07 东莞铭普光磁股份有限公司 A kind of message transfer system and method

Similar Documents

Publication Publication Date Title
CN103580942B (en) A kind of simulative serial port method of testing and device
TW200627876A (en) Data transmission apparatus, data transmission method, data transmission program, and recording medium
CN103338488B (en) Method for switching network, terminal, controller, gateway and system
CN103856302A (en) Intelligent-equipment control method
CN108123873A (en) Data forwarding paths selection method and device, storage medium, server-side
CN101931550B (en) Method and device for synchronizing main and standby main control boards
CN104301813A (en) Ethernet passive optical network system and configuration method
WO2023160620A1 (en) Optical distribution network device and signal processing method
CN105681445A (en) Method and device for selecting point-to-point transmission path of data
JP2010166531A (en) Radio apparatus
CN103369662A (en) Adapter, baseband processing unit and base station system
CN101847135B (en) Series-connected communication system and communication method thereof
CN105246129B (en) The network-building method and device of a kind of intelligent terminal
CN102394734A (en) RS 485 communication system with nonpolarized connection and control method thereof
CN104125150A (en) Protocol message processing method, device and system
CN102932470B (en) Handheld device controls the method and system of computer terminal
CN110231785A (en) A kind of method and device based on terminal control multiple devices
CN104617989A (en) Method and terminal for changing terminal working mode based on a Bluetooth beacon
CN104333500B (en) A kind of signal conversion method, apparatus and system
CN110111768A (en) Audio synchronous transmission method, system and computer equipment, computer readable storage medium
CN105374354A (en) Terminal voice control method and device
CN104936055A (en) Terminal with earphone interface and earphone interface adaptive method
CN207022190U (en) A kind of signal amplification circuit and power amplifying device
CN106161044A (en) A kind of information transferring method and device
CN105657052B (en) The communication means of controlling terminal and voice box group, device and speaker set control system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20190913