CN115174302A - Processing method, device, equipment and storage medium of pluggable accessory - Google Patents

Processing method, device, equipment and storage medium of pluggable accessory Download PDF

Info

Publication number
CN115174302A
CN115174302A CN202211081289.5A CN202211081289A CN115174302A CN 115174302 A CN115174302 A CN 115174302A CN 202211081289 A CN202211081289 A CN 202211081289A CN 115174302 A CN115174302 A CN 115174302A
Authority
CN
China
Prior art keywords
accessory
pluggable
information
communication key
client
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
CN202211081289.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.)
Hangzhou Tuya Information Technology Co Ltd
Original Assignee
Hangzhou Tuya Information 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 Hangzhou Tuya Information Technology Co Ltd filed Critical Hangzhou Tuya Information Technology Co Ltd
Priority to CN202211081289.5A priority Critical patent/CN115174302A/en
Publication of CN115174302A publication Critical patent/CN115174302A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2803Home automation networks
    • H04L12/2807Exchanging configuration information on appliance services in a home automation network
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling
    • G06F13/4068Electrical coupling
    • G06F13/4081Live connection to bus, e.g. hot-plugging

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Computer Hardware Design (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a processing method, a processing device, equipment and a storage medium of pluggable accessories. The method comprises the following steps: the method comprises the steps that wired connection information of a pluggable accessory is obtained from a main device, wherein the wired connection information comprises an accessory identification of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire; acquiring initialization information and a communication key of the pluggable accessory according to the accessory identification; and sending the initialization information and the communication key to the pluggable accessory through the main equipment, and indicating the pluggable accessory to carry out distribution according to the initialization information and the communication key. The embodiment of the invention can improve the distribution network efficiency of pluggable accessories and reduce the construction cost of the intelligent home.

Description

Processing method, device, equipment and storage medium of pluggable accessory
Technical Field
The invention relates to the technical field of intelligent control, in particular to a processing method, a processing device, processing equipment and a storage medium for pluggable accessories.
Background
The intelligent home system is a living environment of people, the intelligent home system is installed by taking a house as a platform, and along with the continuous development of the consumption demand of people and the intelligent heating of the house, the intelligent home system gradually has more and more abundant contents and more perfect system configuration.
The increasingly perfect system configuration also represents that more and more intelligent devices need to be connected into the network, most of the intelligent devices on the market are provided with built-in wireless communication modules or directly connected with routers through wired network ports, and then the devices are distributed through specific user programs so as to be controlled.
Although the continuous access of the intelligent device can improve the intelligent degree, two problems are brought. Firstly, the cost of building of intelligent house has been improved to the too much smart machine of quantity, and each smart machine of another mode all need dispose wireless router information, bluetooth need join in marriage equally, and complex operation and the degree of difficulty are high in the user's use, are connected between equipment and the customer end and join in marriage the net and need spend a large amount of time.
Disclosure of Invention
The invention provides a processing method, a processing device, processing equipment and a storage medium of pluggable accessories, which are used for improving the distribution network efficiency of the pluggable accessories and reducing the construction cost of an intelligent home.
According to an aspect of the present invention, there is provided a method for processing a pluggable accessory, including:
the method comprises the steps of obtaining wired connection information of a pluggable accessory from a main device, wherein the wired connection information comprises an accessory identification of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire;
acquiring initialization information and a communication key of the pluggable accessory according to the accessory identification;
sending the initialization information and the communication key to the pluggable accessory through the main equipment, and indicating the pluggable accessory to carry out distribution according to the initialization information and the communication key
According to another aspect of the present invention, there is provided a processing apparatus for a pluggable accessory, comprising:
the device comprises a connection information acquisition module, a connection information acquisition module and a control module, wherein the connection information acquisition module is used for acquiring wired connection information of a pluggable accessory from a main device, and the wired connection information comprises an accessory identifier of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire;
the distribution network information acquisition module is used for acquiring the initialization information and the communication key of the pluggable accessory according to the accessory identification;
and the distribution network information issuing module is used for sending the initialization information and the communication key to the pluggable accessory through the main equipment and indicating the pluggable accessory to distribute the network according to the initialization information and the communication key.
According to another aspect of the present invention, there is provided an electronic apparatus including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores a computer program executable by the at least one processor, the computer program being executable by the at least one processor to enable the at least one processor to perform the method of processing pluggable accessories of any embodiment of the invention.
According to another aspect of the present invention, there is provided a computer-readable storage medium storing computer instructions for causing a processor to implement a method of processing a pluggable accessory according to any embodiment of the present invention when executed.
According to the embodiment of the invention, the pluggable accessory is in wired connection with the main equipment, the main equipment is used as an intermediary for communication interaction between the pluggable accessory and the client, and a channel is not required to be established between the pluggable accessory and the client again in the process of distribution, so that the distribution speed is increased by reducing the distribution steps, plug and play is realized, and as the accessory is not required to be provided with a wireless communication module, a plurality of accessories can share the wireless communication module of the main equipment, and the development cost and the material cost are reduced.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present invention, nor do they necessarily limit the scope of the invention. Other features of the present invention will become apparent from the following description.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1A is a flowchart illustrating a method for processing a pluggable accessory according to an embodiment of the present invention;
fig. 1B is a schematic diagram of a gateway data forwarding process according to an embodiment of the present invention;
FIG. 2A is a flowchart of a processing method for a pluggable accessory according to another embodiment of the present invention;
FIG. 2B is a schematic diagram of an accessory distribution network flow provided in accordance with yet another embodiment of the present invention;
FIG. 3 is a schematic diagram of a processing device for a pluggable accessory according to another embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device implementing an embodiment of the invention.
Detailed Description
In order to make those skilled in the art better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be obtained by a person skilled in the art without making any creative effort based on the embodiments in the present invention, shall fall within the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in other sequences than those illustrated or described herein. Moreover, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Fig. 1A is a flowchart of a processing method for a pluggable accessory according to an embodiment of the present invention, where the pluggable accessory without a communication module communicates with a client via a host device in a pluggable manner to implement intelligent control of a device, and the method may be executed by a processing apparatus for the pluggable accessory, where the processing apparatus may be implemented in hardware and/or software, and the processing apparatus may be configured in an electronic device with corresponding data processing capability, such as a client of intelligent device management software. As shown in fig. 1A, the method includes:
s110, obtaining wired connection information of a pluggable accessory from a main device, wherein the wired connection information comprises an accessory identifier of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire.
The pluggable accessory is an intelligent device without a wireless communication module, pluggable communication is adopted between the pluggable accessory and the main device, for example, the pluggable accessory is connected in a wired mode such as UART (universal asynchronous receiver/transmitter), SPI (serial peripheral interface), IIC (inter-integrated circuit) and the like, data are delivered to the main device to be forwarded, the state report and the instruction issue of the accessory needing to be processed by a client side are carried out, and the accessory forwards and backwards transmits the data through a communication module of the main device.
Specifically, the main device and the client (including but not limited to a smart phone, a tablet computer, a personal computer, etc.) establish a reliable communication connection through Wi-Fi, bluetooth, wire, etc. The main device communicates with the client through the communication module, and sends the wired connection information of successful connection between the accessory and the main device to the client through an appointed instruction. Because the accessory can be plugged, the combination between the main equipment and the accessory can be replaced by oneself to meet different requirements of users. Meanwhile, the distribution process is based on the channel established by the main equipment, the channel does not need to be established with the client again, the distribution steps are reduced, the distribution speed is increased, plug and play is realized, and because the accessories do not need to be provided with the wireless communication module, a plurality of accessories can share the wireless communication module of the main equipment, and the development cost and the material cost are reduced.
And S120, acquiring initialization information and a communication key of the pluggable accessory according to the accessory identification.
Specifically, the client analyzes the accessory identifier of the accessory according to the wired connection information, queries according to the unique identifier (uuid) of the accessory identifier, and indicates that the accessory is already connected to the network if the accessory exists under the account number of the client, and does not need cloud binding and re-issues activation information to the equipment. If the uuid does not exist in the account, the accessory is connected with the cloud to activate a distribution network, initialization information and a communication key of the pluggable accessory are obtained from the cloud, and the key information is used for encryption and decryption of communication information data between the follow-up accessory and the client. In addition, after the accessory information is bound and activated at the cloud, the accessory information can be mounted to a corresponding user account for management. And meanwhile, the client initializes the functions and loads the panel (such as loading the bulb control panel on the inserted bulb APP) according to the equipment type of the accessory. Meanwhile, historical equipment information is cached by the cloud (for example, a temperature and humidity sensor is inserted, the measured data is reported to the cloud, other accessories are used, and historical data of the temperature and humidity sensor can be seen on the APP).
Optionally, the obtaining initialization information and a communication key of the pluggable accessory according to the accessory identifier includes:
and generating an accessory binding request according to the accessory identification, sending the accessory binding request to a cloud end, and indicating the cloud end to bind the pluggable accessory with the client end according to the accessory binding request, and issuing initialization information and a communication key of the pluggable accessory to the client end after the binding is completed.
Specifically, if the client communicates directly with the host device without the local gateway as a communication intermediary between the client and the host device, the initialization information and the communication key may be obtained as follows: the client sends an accessory binding request carrying an accessory uuid to the cloud, the cloud binds the accessory equipment corresponding to the uuid to the current user account, and initializes parameters and a control panel according to the equipment type (if the accessory is a bulb, initializes necessary parameters of the bulb, a UI (user interface) and function points of the control panel). In addition, the cloud generates a device number distributed by the cloud and a subsequent encryption key for communication according to a specific encryption rule, and issues the device number and the subsequent encryption key to the client.
Optionally, the obtaining initialization information and a communication key of the pluggable accessory according to the accessory identifier includes:
and generating an accessory binding request according to the accessory identification, sending the accessory binding request to a local gateway, and instructing the local gateway to acquire the initialization information and the communication key of the pluggable accessory from a cloud according to the accessory binding request, and issuing the initialization information and the communication key request of the pluggable accessory to a client.
Specifically, if the communication module of the master device does not have the self-networking capability (i.e., cannot be directly connected to the internet, such as bluetooth or ZigBee), the communication module of the master device may be connected to the gateway to expand the communication capability. Connecting a main device without the self-networking capability to a gateway, after the connection is established among the accessory, the main device and the gateway, obtaining device information (such as a unique device identifier uuid, a local communication encryption key and the like) of the accessory by the main device to generate an accessory binding request, sending the accessory binding request to the gateway through a main device communication module, analyzing the request by the gateway to obtain the uuid of the accessory for device query, if the activated accessory does not exist in the user account, sending the request to a cloud for activation of the accessory device, and referring to the specific cloud activation process in the embodiment, which is not described herein again. If the activation is successful, the cloud end sends the initialization information, the communication encryption key and other information of the accessory to the main device through the gateway, and then the main device decrypts the information and sends the information to the accessory.
Fig. 1B is a schematic diagram of a gateway data forwarding process according to an embodiment of the present invention. In the distribution network flow, the accessories have communication addresses and communication encryption keys distributed by the cloud. The method comprises the steps that an instruction is issued at a client side, the instruction is sent to a cloud server in an encrypted mode according to an agreed communication key, the cloud side is pushed to a gateway, the gateway finds a corresponding main device according to a communication address of accessory equipment and sends a control instruction to the main device, and the main device sends the accessory according to a target address. In addition, the status reporting and issuing processes of the accessory equipment are consistent, and only data is transmitted reversely in the data direction.
S130, the initialization information and the communication key are sent to the pluggable accessory through the main device, and the pluggable accessory is instructed to carry out distribution according to the initialization information and the communication key.
Specifically, the client acquires device initialization information and a communication key returned from the cloud, sends the initialization information and the request key to the main device by using an established communication channel with the main device, and the main device analyzes the initialization information and the request key and transmits the initialization information and the request key to the inserted accessory device to complete the initialization pairing and distribution process of the accessories. In addition, according to the communication technology (such as Wi-Fi and Bluetooth) of the main device, the distribution network and the control flow of the device can be modified in the step of interacting with the client, wherein the modification is suitable for the communication technology. For example, wi-Fi intelligent devices can communicate with a client and a cloud through the internet, and bluetooth intelligent devices can communicate with the client through a bluetooth low-power-consumption technology and perform cloud activation and state reporting through the client.
Optionally, the main device includes the intelligent battery package that possesses pluggable module and wireless module, and is corresponding, but the pluggable accessory includes the consumer that possesses pluggable module.
Specifically, the accessory can carry the energy storage component or be external power supply by itself, and when the accessory needs external power supply, the accessory can use the electric energy that main equipment provided to carry out work operation. At this moment, the product form of the main device is mainly an intelligent battery pack, the intelligent battery pack has a bluetooth communication capability and is provided with a UART interface, wherein the bluetooth communication module can be connected with a client (such as a smart phone) and also can be connected with a gateway having the bluetooth capability. Accessory equipment without communication capacity is inserted into a battery pack through a UART interface to complete equipment combination, and the battery pack conducts network distribution, control and other actions on the accessories through a client.
According to the embodiment of the invention, the pluggable accessory is in wired connection with the main equipment, the main equipment is used as an intermediary for communication interaction between the pluggable accessory and the client, and a channel is not required to be established between the pluggable accessory and the client again in the process of distribution, so that the distribution speed is increased by reducing the distribution steps, plug and play is realized, and as the accessory is not required to be provided with a wireless communication module, a plurality of accessories can share the wireless communication module of the main equipment, and the development cost and the material cost are reduced.
Fig. 2A is a flowchart of a processing method of a pluggable accessory according to another embodiment of the present invention, which is improved based on the foregoing embodiment. As shown in fig. 2A, the method includes:
s210, if a pluggable accessory insertion instruction sent by a main device is received, sending a pluggable accessory inquiry instruction to the main device to indicate the main device to generate wired connection information according to an accessory identifier of a newly connected pluggable accessory; and receiving the wired connection information sent by the main equipment.
Specifically, after the connection channel is established between the client and the host device, the client sends a specific instruction to query the host device for device information, which includes information about the accessory. If the client and accessory are already connected (i.e., before the master and client establish communication), the master reports instructions to the client for accessory insertion as in the previous case (accessory insertion). And the subsequent processes are consistent, namely cloud activation and distribution network information issuing.
Fig. 2B is a schematic diagram of an accessory distribution network flow according to another embodiment of the present invention. Whether the main device is connected with the accessory before the main device is connected with the client or not needs to send an accessory insertion instruction, and then the client sends an accessory query instruction.
S220, acquiring initialization information and a communication key of the pluggable accessory according to the accessory identification;
and S230, sending the initialization information and the communication key to the pluggable accessory through the main device, and indicating the pluggable accessory to carry out distribution according to the initialization information and the communication key.
S240, acquiring a state report message sent by the main equipment, and determining a message source of the state report message according to address information in the state report message, wherein the message source is the main equipment or a pluggable accessory; and according to the message source of the state report message, decrypting and processing the state report message by adopting a corresponding communication key.
The equipment control means that the client issues a control instruction of the accessory in modes of graphical operation interface, voice, gesture and the like on the UI. The state reporting means that the instantaneous state and changed data of the information such as the state and data of each functional point of the accessory are reported to the client in a specific protocol format.
Specifically, the reporter of the status report may be a master device or an accessory, and the two devices share an encryption channel. Because the accessory needs to communicate with the client by means of the main device, the status report message of the accessory also needs to be uploaded to the client by means of a communication channel between the main device and the client, if the accessory sends information to the main device, the main device directly forwards the data to the client through the communication module after receiving the data, and the main device forwards the data to the client in various wired/wireless communication modes such as connected Bluetooth, wi-Fi and the like. Therefore, the client reports the status report message received from the host device, and the source of the message may be the host device or a pluggable accessory. The client determines the corresponding message source according to the address information in the state report, decrypts the report by adopting the communication key corresponding to the message source, and performs further statistics, early warning and other processing on the decrypted report data. The communication between the main device and the accessory is transmitted according to a special protocol agreed between the main device and the accessory, and before the main device sends data to the accessory, the instruction number is analyzed first, and then the protocol SRC field is analyzed to judge whether the instruction needs to be transferred to the accessory or not. If the data is required to be sent to the accessory, the data is sent through the connected interface.
Illustratively, table 1 is the contents of the communication protocol between the accessory and the host device and the client.
Figure 643468DEST_PATH_IMAGE001
Table 1 communication protocol content
Wherein, CMD: the device command number, 1 byte, is used for distinguishing the purpose of data and the device appointed command function. SN: packet sequence number, 4 bytes, number used to prevent replay attacks and the same instruction. SRC: data source, 1 byte, to distinguish whether the data is from the master device or the accessory device. INFO _ LEN: length of device information, 1 byte, length of next data segment, i.e. length of device information content. And (3) INFO: device information, INFO _ LEN byte, information for recording the device, such as unique identifier uuid, function flag bit, extended function, and the like. VERSION: protocol version number, 1 byte, is used for recording the version number of the current protocol, and can be used for version differentiation after the protocol is updated. DATA _ ID: the information number, 1 byte, the number for the DATA point, and uuid have a mapping relationship in the cloud, for example, DATA with DATA _ ID of 1 for a smart light device with uuid of 0001 indicates the light switch function. DATA _ TYPE: data type, 1 byte, content type of device control data, including but not limited to boolean, numeric, data, and the like. DATA _ LEN: data length, 1 byte, next data segment length, i.e., the content length of the data point. DATA: the control DATA, DATA _ LEN bytes, the content of the DATA control, can be in any text format such as boolean, numeric, DATA, etc., i.e. the TYPE of DATA indicated by DATA _ TYPE. The content of the data protocol can be properly adjusted and expanded, and is not in a fixed format, for example, a length can be added after the protocol for reserving a function field. The main device and the accessory transmit the device states according to the protocol format, and the communication key distributed by the cloud end after the distribution network at the first point is used for communication.
In addition, the data protocol can also carry out packet transmission, for example, the Bluetooth communication can be adjusted according to the Bluetooth mcu of the client, and the data layer can also carry out packet processing. Referring to the packetization DATA protocol shown in table 2, the DATA content of the DATA field of the control protocol is packetized, and each control DATA packet only stores the content of one packet. Each packet format is as above: PACK _ ID: number of complete data packet, 1 byte; PACK _ SN: each data packet sequence number of the sub-package is used for restoring data and preventing replay according to sequential combination, and the PACK _ SN of each PACK _ ID is counted from 0 to 1 byte; PACK _ LEN: data length of single packet, 1 byte; PACK _ DATA: data content, 1 byte.
Figure 241940DEST_PATH_IMAGE002
TABLE 2 packetization protocol Format
S250, determining the accessory information of the pluggable accessory to be controlled, and determining the target main equipment connected with the pluggable accessory to be controlled according to the accessory information; and sending the device control message of the pluggable accessory to be controlled to the target main device according to the address information of the target main device, wherein the device control message is used for indicating the target main device to send the device control message to the pluggable accessory to be controlled.
The device control refers to human-computer interaction between the main device and the accessory device, which is realized by a user through a client or a cloud automation command, and the user modifies the device state and the stored data and executes the device through a series of ways such as UI, voice and gestures. And formatting the data format transmitted by the client according to the protocol, and carrying out encryption protection according to a communication key issued by the cloud after the distribution network.
Specifically, whether the equipment needing to be controlled is an accessory is determined in the client, and if the equipment needing to be controlled is the main equipment, the data target is marked as the main equipment; and if the equipment needing to be controlled is the accessory, inquiring the address of the main equipment corresponding to the accessory according to the accessory information so as to send the equipment control message to the main equipment connected with the accessory. And after the address of the main equipment is determined, encrypting by using a corresponding communication key, and sending an equipment control message by using the address of the main equipment. And after the main equipment or the accessory receives the equipment control message, feeding back a processing result of the state control message: if the message is successfully received and decrypted, the message can be executed and the command can be replied to be successfully received, and the message is fed back to the user through a UI (user interface), voice and the like by the client, and if the message is not successfully received and decrypted, the message is fed back to the user through the UI, voice and the like to fail the operation. In addition, after the user successfully controls the device, the result after the device is controlled can be uploaded to the cloud according to the device type, the network condition and the like, and therefore the real-time state of the device can be updated for interactive display when the user logs in another client.
According to the embodiment of the invention, after the pluggable accessories are distributed, the main equipment is used as an intermediary for information transmission, so that the state control of the client on the accessories and the report of the accessories to the client are realized.
Fig. 3 is a schematic structural diagram of a processing device of a pluggable accessory according to another embodiment of the present invention. As shown in fig. 3, the apparatus includes:
a connection information obtaining module 310, configured to obtain wired connection information of a pluggable accessory from a host device, where the wired connection information includes an accessory identifier of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire;
a distribution network information obtaining module 320, configured to obtain initialization information and a communication key of the pluggable accessory according to the accessory identifier;
a distribution network information issuing module 330, configured to send the initialization information and the communication key to the pluggable accessory through the master device, and instruct the pluggable accessory to perform distribution network according to the initialization information and the communication key
The processing device of the pluggable accessory provided by the embodiment of the invention can execute the processing method of the pluggable accessory provided by any embodiment of the invention, and has the corresponding functional modules of the execution method and the beneficial effects
Optionally, the connection information obtaining module 310 includes:
the inquiry instruction sending unit is used for sending a pluggable accessory inquiry instruction to the main equipment to indicate the main equipment to generate wired connection information according to the accessory identification of the newly connected pluggable accessory if the pluggable accessory insertion instruction sent by the main equipment is received;
and the connection information acquisition unit is used for receiving the wired connection information sent by the main equipment.
Optionally, the distribution network information obtaining module 320 includes a first distribution network information obtaining unit, configured to generate an accessory binding request according to the accessory identifier, send the accessory binding request to a cloud, instruct the cloud to bind the pluggable accessory with the client according to the accessory binding request, and issue the initialization information and the communication key of the pluggable accessory to the client after the binding is completed.
Optionally, the distribution network information obtaining module 320 includes a second distribution network information obtaining unit, configured to generate an accessory binding request according to the accessory identifier, send the accessory binding request to a local gateway, and instruct the local gateway to obtain the initialization information and the communication key of the pluggable accessory from a cloud according to the accessory binding request, and send the initialization information and the communication key request of the pluggable accessory to a client.
Optionally, the apparatus further comprises:
a status report receiving module, configured to obtain a status report message sent by the host device, and determine a message source of the status report message according to address information in the status report message, where the message source is the host device or a pluggable accessory;
and the state reporting processing module is used for decrypting and processing the state reporting message by adopting a corresponding communication key according to the message source of the state reporting message.
Optionally, the apparatus further comprises:
the target main equipment determining module is used for determining the accessory information of the pluggable accessory to be controlled and determining the target main equipment connected with the pluggable accessory to be controlled according to the accessory information;
and the equipment control issuing module is used for sending the equipment control message of the pluggable accessory to be controlled to the target main equipment according to the address information of the target main equipment and indicating the target main equipment to send the equipment control message to the pluggable accessory to be controlled.
Optionally, the main device includes the intelligent battery package that possesses pluggable module and wireless module, and is corresponding, but the pluggable accessory is including the power consumption smart machine that possesses pluggable module.
The processing apparatus for pluggable accessories described further can also execute the processing method for pluggable accessories provided by any embodiment of the present invention, and has functional modules and beneficial effects corresponding to the execution method.
FIG. 4 illustrates a schematic diagram of an electronic device 40 that may be used to implement an embodiment of the invention. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smart phones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 4, the electronic device 40 includes at least one processor 41, and a memory communicatively connected to the at least one processor 41, such as a Read Only Memory (ROM) 42, a Random Access Memory (RAM) 43, and the like, wherein the memory stores a computer program executable by the at least one processor, and the processor 41 may perform various suitable actions and processes according to the computer program stored in the Read Only Memory (ROM) 42 or the computer program loaded from a storage unit 48 into the Random Access Memory (RAM) 43. In the RAM 43, various programs and data necessary for the operation of the electronic apparatus 40 can also be stored. The processor 41, the ROM 42, and the RAM 43 are connected to each other via a bus 44. An input/output (I/O) interface 45 is also connected to bus 44.
A number of components in the electronic device 40 are connected to the I/O interface 45, including: an input unit 46 such as a keyboard, a mouse, or the like; an output unit 47 such as various types of displays, speakers, and the like; a storage unit 48 such as a magnetic disk, optical disk, or the like; and a communication unit 49 such as a network card, modem, wireless communication transceiver, etc. The communication unit 49 allows the electronic device 40 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
Processor 41 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of processor 41 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various processors running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The processor 41 performs the various methods and processes described above, such as the processing of a pluggable accessory.
In some embodiments, the processing of the pluggable accessory may be implemented as a computer program tangibly embodied on a computer-readable storage medium, such as storage unit 48. In some embodiments, part or all of the computer program may be loaded and/or installed onto the electronic device 40 via the ROM 42 and/or the communication unit 49. When the computer program is loaded into RAM 43 and executed by processor 41, one or more steps of the process of the pluggable accessory described above may be performed. Alternatively, in other embodiments, the processor 41 may be configured to perform the processing of the pluggable accessory in any other suitable manner (e.g., by way of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
A computer program for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the computer programs, when executed by the processor, cause the functions/acts specified in the flowchart and/or block diagram block or blocks to be performed. A computer program can execute entirely on a machine, partly on a machine, as a stand-alone software package partly on a machine and partly on a remote machine or entirely on a remote machine or server.
In the context of the present invention, a computer-readable storage medium may be a tangible medium that can contain, or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. A computer readable storage medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. Alternatively, the computer readable storage medium may be a machine readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the electronic device. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), blockchain networks, and the Internet.
The computing system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service are overcome.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present invention may be executed in parallel, sequentially, or in different orders, and are not limited herein as long as the desired results of the technical solution of the present invention can be achieved.
The above-described embodiments should not be construed as limiting the scope of the invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A processing method of pluggable accessories, which is applied to a local client, comprises the following steps:
the method comprises the steps that wired connection information of a pluggable accessory is obtained from a main device, wherein the wired connection information comprises an accessory identification of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire;
acquiring initialization information and a communication key of the pluggable accessory according to the accessory identification;
and sending the initialization information and the communication key to the pluggable accessory through the main equipment, and indicating the pluggable accessory to carry out distribution according to the initialization information and the communication key.
2. The method of claim 1, wherein obtaining the wired connection information of the pluggable accessory from the host device comprises:
if a pluggable accessory insertion instruction sent by a main device is received, sending a pluggable accessory inquiry instruction to the main device to indicate the main device to generate wired connection information according to an accessory identification of a newly connected pluggable accessory;
and receiving the wired connection information sent by the main equipment.
3. The method of claim 1, wherein obtaining initialization information and a communication key for the pluggable accessory based on the accessory identification comprises:
and generating an accessory binding request according to the accessory identification, sending the accessory binding request to a cloud end, and indicating the cloud end to bind the pluggable accessory with the client end according to the accessory binding request, and issuing initialization information and a communication key of the pluggable accessory to the client end after the binding is completed.
4. The method of claim 1, wherein obtaining initialization information and a communication key of the pluggable accessory according to the accessory identifier comprises:
and generating an accessory binding request according to the accessory identification, sending the accessory binding request to a local gateway, and indicating the local gateway to acquire the initialization information and the communication key of the pluggable accessory from a cloud according to the accessory binding request, and issuing the initialization information and the communication key request of the pluggable accessory to a client.
5. The method of claim 1, wherein after sending the initialization information and the communication key to the pluggable accessory via the host device, further comprising:
acquiring a state report message sent by the main equipment, and determining a message source of the state report message according to address information in the state report message, wherein the message source is the main equipment or a pluggable accessory;
and according to the message source of the state report message, decrypting and processing the state report message by adopting a corresponding communication key.
6. The method of claim 5, wherein after sending the initialization information and the communication key to the pluggable accessory via the host device, further comprising:
determining accessory information of a pluggable accessory to be controlled, and determining target main equipment connected with the pluggable accessory to be controlled according to the accessory information;
and sending the device control message of the pluggable accessory to be controlled to the target main device according to the address information of the target main device, wherein the device control message is used for indicating the target main device to send the device control message to the pluggable accessory to be controlled.
7. The method of any of claims 1-6, wherein the primary device comprises a smart battery pack having a pluggable module and a wireless module, and wherein the pluggable accessory comprises a powered smart device having a pluggable module.
8. A processing apparatus for pluggable accessories deployed at a local client, the apparatus comprising:
the pluggable accessory connecting device comprises a connecting information acquisition module, a connection information acquisition module and a pluggable accessory connecting module, wherein the connecting information acquisition module is used for acquiring wired connecting information of a pluggable accessory from a main device, and the wired connecting information comprises an accessory identification of the pluggable accessory; the main equipment is connected with the pluggable accessory through a wire;
the distribution network information acquisition module is used for acquiring the initialization information and the communication key of the pluggable accessory according to the accessory identification;
and the distribution network information issuing module is used for sending the initialization information and the communication key to the pluggable accessory through the main equipment and indicating the pluggable accessory to carry out distribution according to the initialization information and the communication key.
9. An electronic device, characterized in that the electronic device comprises:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of processing a pluggable accessory of any of claims 1-7.
10. A computer readable storage medium having stored thereon computer instructions for causing a processor to perform the method of processing a pluggable accessory of any of claims 1-7 when executed.
CN202211081289.5A 2022-09-06 2022-09-06 Processing method, device, equipment and storage medium of pluggable accessory Pending CN115174302A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211081289.5A CN115174302A (en) 2022-09-06 2022-09-06 Processing method, device, equipment and storage medium of pluggable accessory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211081289.5A CN115174302A (en) 2022-09-06 2022-09-06 Processing method, device, equipment and storage medium of pluggable accessory

Publications (1)

Publication Number Publication Date
CN115174302A true CN115174302A (en) 2022-10-11

Family

ID=83481401

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211081289.5A Pending CN115174302A (en) 2022-09-06 2022-09-06 Processing method, device, equipment and storage medium of pluggable accessory

Country Status (1)

Country Link
CN (1) CN115174302A (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103685323A (en) * 2014-01-02 2014-03-26 中国科学院信息工程研究所 Method for realizing intelligent home security networking based on intelligent cloud television gateway
CN108400869A (en) * 2018-01-26 2018-08-14 海尔优家智能科技(北京)有限公司 A kind of encryption communication method, terminal, equipment, cloud device and medium
CN110365576A (en) * 2018-03-26 2019-10-22 江苏智慧新吴信息科技有限公司 A kind of things-internet gateway hot plug enters the method in cloud
CN111314912A (en) * 2020-02-11 2020-06-19 浙江大华技术股份有限公司 WiFi configuration method and device, storage medium and electronic device
CN112040485A (en) * 2020-11-02 2020-12-04 杭州涂鸦信息技术有限公司 Local area network key agreement method, system and computer readable storage medium
CN113132977A (en) * 2019-12-31 2021-07-16 佛山市云米电器科技有限公司 Network distribution method, network distribution system and computer readable storage medium
CN113271579A (en) * 2021-05-24 2021-08-17 杭州涂鸦信息技术有限公司 Bluetooth device control method, client, computer device and readable storage medium
CN113630246A (en) * 2021-07-28 2021-11-09 珠海格力电器股份有限公司 Smart home control method and device, electronic equipment and storage medium
CN114900826A (en) * 2022-04-26 2022-08-12 青岛海尔科技有限公司 Equipment binding method and device, storage medium and electronic device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103685323A (en) * 2014-01-02 2014-03-26 中国科学院信息工程研究所 Method for realizing intelligent home security networking based on intelligent cloud television gateway
CN108400869A (en) * 2018-01-26 2018-08-14 海尔优家智能科技(北京)有限公司 A kind of encryption communication method, terminal, equipment, cloud device and medium
CN110365576A (en) * 2018-03-26 2019-10-22 江苏智慧新吴信息科技有限公司 A kind of things-internet gateway hot plug enters the method in cloud
CN113132977A (en) * 2019-12-31 2021-07-16 佛山市云米电器科技有限公司 Network distribution method, network distribution system and computer readable storage medium
CN111314912A (en) * 2020-02-11 2020-06-19 浙江大华技术股份有限公司 WiFi configuration method and device, storage medium and electronic device
CN112040485A (en) * 2020-11-02 2020-12-04 杭州涂鸦信息技术有限公司 Local area network key agreement method, system and computer readable storage medium
CN113271579A (en) * 2021-05-24 2021-08-17 杭州涂鸦信息技术有限公司 Bluetooth device control method, client, computer device and readable storage medium
CN113630246A (en) * 2021-07-28 2021-11-09 珠海格力电器股份有限公司 Smart home control method and device, electronic equipment and storage medium
CN114900826A (en) * 2022-04-26 2022-08-12 青岛海尔科技有限公司 Equipment binding method and device, storage medium and electronic device

Similar Documents

Publication Publication Date Title
EP3873004A1 (en) Method for establishing classic bluetooth connection between dual-mode bluetooth devices, and dual-mode bluetooth device
US20160277205A1 (en) Internet of things (iot) communication method, communication end, and user end
WO2016161913A1 (en) Resource transfer system and method
CN109496419A (en) Document handling method, device and system
WO2013131477A1 (en) Remote monitoring device and method
CN104749996A (en) Remote control method of ZigBee remote controller
CN103457911A (en) Method and system of information sharing
CN108924806A (en) A kind of family's internet of things data communication means and system using BLE technology
CN108418903B (en) Remote access system and access method for embedded software log
WO2019196454A1 (en) Data transmission method and device, and multi-split air conditioning system
TW201814609A (en) Information pushing
WO2012112650A1 (en) Method and apparatus for plug and play, networkable iso 18000-7 connectivity
CN112631800A (en) Kafka-oriented data transmission method and system, computer equipment and storage medium
CN106708554A (en) Program running method and device
CN104639409A (en) Method and device for automatically adding sound box to sound box ad-hoc network
CN112445700A (en) Test method and device
US11736557B1 (en) Copying and pasting between devices
KR102017631B1 (en) Terminal apparatus and method for transmitting and receiving data
CN111831513A (en) Log query method and device, electronic equipment and storage medium
WO2014067258A1 (en) Cloud service triggering method, cloud server and thin client
CN109213955B (en) Data processing method and related equipment
EP2960792A2 (en) Electronic device and data copy method between electronic devices
CN115174302A (en) Processing method, device, equipment and storage medium of pluggable accessory
CN111988270A (en) Intelligent communication gateway device and implementation method thereof
CN112019409A (en) Equipment distribution network processing method, equipment distribution network processing device and electronic equipment

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: 20221011