Device connection method, input device, wearable device, apparatus and storage medium
By using the camera in the VR device to scan the QR code information to establish a WiFi connection and switch to Lora communication, the problem of complex connection and high power consumption of VR glasses and VR controllers is solved, and simplified operation and low-power communication are achieved.
Patent Information
- Application Number
- CN202210388753.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-14
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2042-04-14
AI Technical Summary
The connection method between VR glasses and VR controllers in existing VR devices is complex and consumes high power, resulting in cumbersome user operations and high energy consumption.
The camera scans the QR code information of the wearable device, extracts the network connection information, establishes a WiFi connection and pairs it, and then switches to the low-power LoRa communication connection.
It simplifies the device connection process, reduces power consumption, and improves connection efficiency and user experience.
Smart Images

Figure CN114793371B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of smart device technology, and in particular to a device connection method, input device, wearable device, apparatus and storage medium. Background Art
[0002] VR devices currently on the market generally consist of two components: VR glasses and VR controllers. After purchasing a VR device, the first thing users need to do is pair the glasses and controllers. There are various communication methods for VR glasses and VR controllers, and pairing them accurately, quickly, and conveniently helps reduce the difficulty of getting started with VR devices and makes it easier for users to replace controllers.
[0003] Currently, VR glasses and VR controllers use Bluetooth and NFC connections. This connection method is relatively complicated to operate and has low connection efficiency. In addition, Bluetooth and NFC connections also consume high power when communicating.
[0004] The above content is only used to assist in understanding the technical solution of the present invention and does not constitute an admission that the above content is prior art. Summary of the Invention
[0005] The main purpose of the present invention is to provide a device connection method, input device, wearable device, apparatus and storage medium, aiming to solve the technical problems in the prior art of complex connection and high power consumption during communication.
[0006] To achieve the above-mentioned object, the present invention provides a device connection method, which is applied to an input device;
[0007] The device connection method includes:
[0008] Scan the QR code information of the wearable device through the camera;
[0009] Extracting network connection information from the QR code information;
[0010] Establishing a Wi-Fi connection with the wearable device according to the network connection information;
[0011] Pairing with the wearable device via the Wi-Fi connection;
[0012] After pairing is successful, a lora communication connection is established with the wearable device.
[0013] Optionally, the pairing with the wearable device through the Wi-Fi connection includes:
[0014] Transmitting pairing information to the wearable device via the Wi-Fi connection;
[0015] After the wearable device receives the pairing information, data frame pairing is performed with the wearable device based on the pairing information.
[0016] Optionally, after the pairing is successful and a lora communication connection is established with the wearable device, the method further includes:
[0017] Performing Lora communication with the wearable device via the Lora communication connection;
[0018] When it is detected that the lora communication is in a normal communication state, the wifi connection is disconnected.
[0019] Optionally, the device connection method further includes:
[0020] When no user operation is received within a preset time, the current working mode is adjusted to the sleep mode, and a sleep frame is sent to the wearable device to adjust the current working mode of the wearable device to the sleep mode.
[0021] In addition, to achieve the above-mentioned purpose, the present invention also provides a device connection device, which is applied to an input device;
[0022] The device connection device comprises:
[0023] A shooting module is used to scan the QR code information of the wearable device through a camera;
[0024] A reading module, configured to extract network connection information from the QR code information;
[0025] A communication module, configured to establish a Wi-Fi connection with the wearable device according to the network connection information;
[0026] The communication module is further configured to pair with the wearable device via the Wi-Fi connection;
[0027] The communication module is further used to establish a LoRa communication connection with the wearable device after pairing is successful.
[0028] In addition, to achieve the above objectives, the present invention also proposes an input device, which includes: a memory, a processor, and a device connection program stored in the memory and running on the processor, and the device connection program is configured to implement the device connection method described above.
[0029] The present invention provides a device connection method, which is applied to a wearable device;
[0030] The device connection method includes:
[0031] Establish a wifi connection with the input device;
[0032] Pairing with the input device via the Wi-Fi connection;
[0033] After pairing is successful, a lora communication connection is established with the input device.
[0034] Optionally, the pairing with the input device through the Wi-Fi connection includes:
[0035] Receiving pairing information transmitted by the input device through the Wi-Fi connection;
[0036] After receiving the pairing information, data frame pairing is performed with the input device based on the pairing information.
[0037] Optionally, after the pairing is successful and a lora communication connection is established with the input device, the method further includes:
[0038] Performing Lora communication with the input device via the Lora communication connection;
[0039] When it is detected that the lora communication is in a normal communication state, the wifi connection is disconnected.
[0040] In addition, to achieve the above-mentioned object, the present invention also provides a device connection device, which is applied to a wearable device;
[0041] The device connection device comprises:
[0042] Communication module, used to establish a Wi-Fi connection with the input device;
[0043] The communication module is further configured to pair with the input device via the Wi-Fi connection;
[0044] The communication module is further configured to establish a LoRa communication connection with the input device after successful pairing.
[0045] In addition, to achieve the above-mentioned purpose, the present invention also proposes a wearable device, which includes: a memory, a processor, and a device connection program stored in the memory and running on the processor, and the device connection program is configured to implement the device connection method described above.
[0046] In addition, to achieve the above-mentioned purpose, the present invention further proposes a storage medium, on which a device connection program is stored. When the device connection program is executed by a processor, the device connection method described above is implemented.
[0047] The present invention scans QR code information of a wearable device through a camera; extracts network connection information from the QR code information; establishes a Wi-Fi connection with the wearable device according to the network connection information; pairs the wearable device with the Wi-Fi connection; establishes a LoRa communication connection with the wearable device after pairing is successful, establishes a Wi-Fi connection between an input device and the wearable device by scanning the QR code, pairs the wearable device with the LoRa communication through the established Wi-Fi connection, and switches to the LoRa communication connection for communication after pairing is successful, thereby simplifying the device connection process and reducing power consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 It is a structural diagram of an input device in a hardware operating environment involved in an embodiment of the present invention;
[0049] Figure 2 This is a flow chart of a first embodiment of a device connection method according to the present invention;
[0050] Figure 3 This is a flow chart of a second embodiment of the device connection method of the present invention;
[0051] Figure 4 This is a structural block diagram of a first embodiment of the device connection apparatus of the present invention;
[0052] Figure 5 Schematic diagram of the structure of a wearable device in the hardware operating environment involved in the embodiment of the present invention;
[0053] Figure 6 This is a flow chart of a third embodiment of a device connection method according to the present invention;
[0054] Figure 7 This is a flow chart of a fourth embodiment of a device connection method according to the present invention;
[0055] Figure 8 This is a structural block diagram of the second embodiment of the device connection apparatus of the present invention.
[0056] The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings and in conjunction with the embodiments. DETAILED DESCRIPTION
[0057] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0058] Reference Figure 1 , Figure 1 This is a schematic diagram of the input device structure of the hardware operating environment involved in the embodiment of the present invention.
[0059] like Figure 1As shown, the input device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the user interface 1003 may optionally include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a wireless fidelity (Wireless-Fidelity, Wi-Fi) interface). The memory 1005 may be a high-speed random access memory (Random Access Memory, RAM) memory, or a stable non-volatile memory (Non-Volatile Memory, NVM), such as a disk memory. The memory 1005 may optionally be a storage device independent of the aforementioned processor 1001.
[0060] Those skilled in the art will understand that Figure 1 The structure shown in the figure does not constitute a limitation on the input device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0061] like Figure 1 As shown, the memory 1005 as a storage medium may include an operating system, a network communication module, a user interface module, and a device connection program.
[0062] exist Figure 1 In the input device shown, the network interface 1004 is mainly used for data communication with the network server; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the input device of the present invention can be set in the input device, and the input device calls the device connection program stored in the memory 1005 through the processor 1001, and executes the device connection method provided by the embodiment of the present invention.
[0063] The embodiment of the present invention provides a device connection method, referring to Figure 2 , Figure 2 This is a flow chart of a first embodiment of a device connection method according to the present invention.
[0064] In this embodiment, the device connection method includes the following steps:
[0065] Step S10: Scan the QR code information of the wearable device through the camera.
[0066] In this embodiment, the execution subject of this embodiment may be the input device, which has functions such as data processing, data communication, and program execution. The input device may be a device such as a VR controller. Of course, other devices with similar functions may also be used, and this implementation condition does not limit this. For ease of explanation, this embodiment uses an input device as an example.
[0067] It should be noted that virtual reality (VR) technology devices currently on the market generally consist of two parts: VR glasses and VR controllers. After purchasing a VR device, the first thing users need to do is pair the VR glasses and VR controllers. There are also various communication methods for VR glasses and VR controllers. Correctly, quickly, and conveniently pairing the glasses and controllers helps reduce the difficulty of getting started with VR devices and makes it easier for users to replace controllers themselves. Currently, VR glasses and VR controllers are connected via Bluetooth or NFC. The connection process for Bluetooth or NFC is relatively complex. For example, Bluetooth connection requires first turning on the device's Bluetooth, performing the corresponding configuration, and then scanning for Bluetooth access points to obtain a list of Bluetooth access points. Finally, the user selects the device to connect from the list and establishes a Bluetooth connection. The connected party must click the pairing confirmation button again to complete the connection. The entire process requires users to perform relatively tedious operations, and after the Bluetooth connection is established, the power consumption required for communication via the Bluetooth connection is relatively high.
[0068] It should be noted that the input device in this embodiment can be a VR handle, and the wearable device can be VR glasses. In order to solve the above technical problems, the connection process between the input device and the wearable device is simplified in this embodiment. Specifically, it can be implemented as follows.
[0069] In a specific implementation, a camera is installed on the input device, and QR code information is set on the wearable device. The QR code information on the wearable device can be scanned by the camera on the input device. The installation of the camera and the setting position of the QR code information can be adjusted according to actual conditions, and this is not limited in this embodiment.
[0070] It should be noted that both the input device and the wearable device are provided with indicator lights. Different states of the indicator lights represent different connection states and communication states between the input device and the wearable device. For example, when the input device has not established a wifi connection with the wearable device, and when the input device is establishing a wifi connection with the wearable device, the input device flashes a red light. However, the difference is that when the input device has not established a wifi connection with the wearable device, the red light flashes slowly, and the flashing speed is slower, while when the input device is establishing a wifi connection with the wearable device, the red light flashes quickly, and the flashing speed is faster. The specific flashing speed of the light can be adjusted accordingly according to actual needs, and this is not limited in this embodiment. It should be emphasized that the flashing state of the light of the wearable device is consistent with that of the input device, and will not be repeated in this embodiment.
[0071] Step S20: extracting network connection information from the QR code information.
[0072] In a specific implementation, the QR code information includes Wi-Fi AP information. After scanning the QR code information, the network connection information can be extracted from the QR code information.
[0073] Step S30: Establishing a Wi-Fi connection with the wearable device according to the network connection information.
[0074] In the specific implementation, after extracting the network connection information, the input device establishes a WiFi connection with the wearable device based on the obtained network connection information. No human operation is required during the entire process. The input device automatically completes the entire process from extracting the network connection information from the QR code information to establishing the WiFi connection. Compared with Bluetooth and NFC methods, the WiFi connection process is simpler and more efficient.
[0075] Step S40: Pairing with the wearable device via the Wi-Fi connection.
[0076] In a specific implementation, after establishing a WiFi connection with the wearable device, in order to reduce power consumption during the communication process, this embodiment further pairs the wearable device through the WiFi connection. Pairing is used to activate the lora communication module to communicate with the wearable device.
[0077] It should be noted that during the pairing process with the wearable device via Wi-Fi connection, the input device flashes green.
[0078] Step S50: After pairing is successful, establish a lora communication connection with the wearable device.
[0079] In the specific implementation, LoRa communication is a low-power communication mode. In order to reduce communication power consumption, after establishing a WiFi connection with the wearable device, the WiFi connection is switched to a LoRa communication connection, and then communication is carried out through the LoRa communication connection to achieve the purpose of reducing power consumption.
[0080] This embodiment uses a camera to scan the QR code information of a wearable device; extracts network connection information from the QR code information; establishes a WiFi connection with the wearable device based on the network connection information; pairs with the wearable device through the WiFi connection; after successful pairing, establishes a LoRa communication connection with the wearable device, establishes a WiFi connection between the input device and the wearable device by scanning the QR code, pairs the LoRa communication through the established WiFi connection, and after successful pairing, switches to the LoRa communication connection for communication, which simplifies the device connection process and reduces power consumption.
[0081] refer to Figure 3 , Figure 3 This is a flow chart of a second embodiment of a device connection method according to the present invention.
[0082] Based on the first embodiment above, in the device connection method of this embodiment, step S40 specifically includes:
[0083] Step S401: transmitting pairing information to the wearable device via the Wi-Fi connection.
[0084] In a specific implementation, after establishing a WiFi connection with the wearable device, in this embodiment, pairing information is transmitted through the WiFi connection, and the pairing information is used to activate the lora communication module to communicate with the wearable device.
[0085] Step S402: After the wearable device receives the pairing information, data frame pairing is performed with the wearable device based on the pairing information.
[0086] In a specific implementation, after the input device transmits the pairing information to the wearable device, the input device and the wearable device exchange pairing frames, that is, data frame pairing. After the pairing is completed, a lora communication connection can be established with the wearable device.
[0087] Furthermore, in this embodiment, after establishing a LoRa communication connection with the wearable device, the input device communicates with the wearable device via the LoRa communication connection, and the input device sends the user's action information to the wearable device via the LoRa communication connection. In addition, in this embodiment, the communication status of the LoRa communication connection is detected in real time. If the communication status is normal, it means that the LoRa communication is stable at this time. In this case, in this embodiment, the previously established WiFi connection will be disconnected.
[0088] It should be noted that during the communication process through the lora communication connection, the indicator lights of the input device and the wearable device are blue and are always on.
[0089] It is easy to understand that if the user does not operate the input device for a long time, in order to avoid increasing unnecessary power consumption, the input device will be controlled to sleep in this embodiment. Specifically, a preset time is first set in this embodiment. If no user operation is received within the preset time, it can be determined that the user has not operated the input device for a long time. In this case, the current working mode of the input device will be adjusted to sleep mode in this embodiment. After the input device is in sleep mode, the input device will also send a sleep frame to the wearable device, so that the wearable device also enters sleep mode.
[0090] Furthermore, when the input device and the wearable device enter the lora sleep mode, the blue light on the input device and the wearable device flashes, and the flashing speed is slow at this time, in the state of slow blue flashing. It should be emphasized that the above light color can also be adjusted accordingly according to the actual needs of the user, and this is not limited in this embodiment.
[0091] This embodiment transmits pairing information to the wearable device through the WiFi connection; after the wearable device receives the pairing information, it performs data frame pairing with the wearable device based on the pairing information, so that the input device and the wearable device can establish a LoRa communication connection quickly and accurately. At the same time, when it is detected that the LoRa communication is in a normal communication state, the WiFi connection is disconnected, and when no user operation is received within a preset time, the current working mode is adjusted to the sleep mode, and a sleep frame is sent to the wearable device to adjust the current working mode of the wearable device to the sleep mode. Through the LoRa communication connection and the adjustment of the sleep mode, the power consumption during the communication between the input device and the wearable device is further reduced.
[0092] Reference Figure 4 , Figure 4 This is a structural block diagram of the first embodiment of the device connection apparatus of the present invention.
[0093] like Figure 4As shown, the device connection device proposed in the embodiment of the present invention includes:
[0094] The shooting module 10 is used to scan the QR code information of the wearable device through a camera.
[0095] The reading module 20 is used to extract the network connection information from the QR code information.
[0096] The communication module 30 is used to establish a Wi-Fi connection with the wearable device according to the network connection information.
[0097] The communication module 30 is further configured to pair with the wearable device via the Wi-Fi connection.
[0098] The communication module 30 is further configured to establish a LoRa communication connection with the wearable device after pairing is successful.
[0099] This embodiment uses a camera to scan the QR code information of a wearable device; extracts network connection information from the QR code information; establishes a WiFi connection with the wearable device based on the network connection information; pairs with the wearable device through the WiFi connection; after successful pairing, establishes a LoRa communication connection with the wearable device, establishes a WiFi connection between the input device and the wearable device by scanning the QR code, pairs the LoRa communication through the established WiFi connection, and after successful pairing, switches to the LoRa communication connection for communication, which simplifies the device connection process and reduces power consumption.
[0100] Reference Figure 5 , Figure 5 This is a schematic diagram of the wearable device structure of the hardware operating environment involved in the embodiment of the present invention.
[0101] like Figure 5As shown, the wearable device may include: a processor 2001, such as a central processing unit (CPU), a communication bus 2002, a user interface 2003, a network interface 2004, and a memory 2005. The communication bus 2002 is used to realize the connection and communication between these components. The user interface 2003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the user interface 2003 may optionally include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a wireless fidelity (Wireless-Fidelity, Wi-Fi) interface). The memory 2005 may be a high-speed random access memory (Random Access Memory, RAM) memory, or a stable non-volatile memory (Non-Volatile Memory, NVM), such as a disk memory. The memory 2005 may also be a storage device independent of the aforementioned processor 2001.
[0102] Those skilled in the art will understand that Figure 5 The structure shown in the figure does not constitute a limitation on the wearable device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0103] like Figure 5 As shown, the memory 2005 as a storage medium may include an operating system, a network communication module, a user interface module, and a device connection program.
[0104] exist Figure 5 In the wearable device shown, the network interface 2004 is mainly used for data communication with the network server; the user interface 2003 is mainly used for data interaction with the user; the processor 2001 and the memory 2005 in the wearable device of the present invention can be set in the wearable device, and the wearable device calls the device connection program stored in the memory 2005 through the processor 2001 and executes the device connection method provided by the embodiment of the present invention.
[0105] Further, refer to Figure 6 , Figure 6 This is a flow chart of a third embodiment of a device connection method according to the present invention.
[0106] In this embodiment, the device connection method includes the following steps:
[0107] Step S10 ′: establishing a Wi-Fi connection with the input device.
[0108] In this embodiment, the execution subject of this embodiment may be the wearable device, which has functions such as data processing, data communication, and program execution. The wearable device may be a device such as VR glasses. Of course, other devices with similar functions may also be used, and this implementation condition does not limit this. For ease of explanation, this embodiment uses a wearable device as an example.
[0109] It should be noted that virtual reality (VR) technology devices currently on the market generally consist of two parts: VR glasses and VR controllers. After purchasing a VR device, the first thing users need to do is pair the VR glasses and VR controllers. There are also various communication methods for VR glasses and VR controllers. Correctly, quickly, and conveniently pairing the glasses and controllers helps reduce the difficulty of getting started with VR devices and makes it easier for users to replace controllers themselves. Currently, VR glasses and VR controllers are connected via Bluetooth or NFC. The connection process for Bluetooth or NFC is relatively complex. For example, Bluetooth connection requires first turning on the device's Bluetooth, performing the corresponding configuration, and then scanning for Bluetooth access points to obtain a list of Bluetooth access points. Finally, the user selects the device to connect from the list and establishes a Bluetooth connection. The connected party must click the pairing confirmation button again to complete the connection. The entire process requires users to perform relatively tedious operations, and after the Bluetooth connection is established, the power consumption required for communication via the Bluetooth connection is relatively high.
[0110] It should be noted that the input device in this embodiment can be a VR handle, and the wearable device can be VR glasses. In order to solve the above technical problems, the connection process between the input device and the wearable device is simplified in this embodiment. Specifically, it can be implemented as follows.
[0111] In a specific implementation, a camera is installed on the input device, and QR code information is set on the wearable device. The QR code information on the wearable device can be scanned by the camera on the input device, and the input device establishes a Wi-Fi connection with the wearable device based on the scanned QR code information.
[0112] It should be noted that both the input device and the wearable device are provided with indicator lights. Different states of the indicator lights represent different connection states and communication states between the input device and the wearable device. For example, when the input device has not established a wifi connection with the wearable device, and when the input device is establishing a wifi connection with the wearable device, the input device flashes a red light. However, the difference is that when the input device has not established a wifi connection with the wearable device, the red light flashes slowly, and the flashing speed is slower, while when the input device is establishing a wifi connection with the wearable device, the red light flashes quickly, and the flashing speed is faster. The specific flashing speed of the light can be adjusted accordingly according to actual needs, and this is not limited in this embodiment. It should be emphasized that the flashing state of the light of the wearable device is consistent with that of the input device, and will not be repeated in this embodiment.
[0113] Step S20 ′: pairing with the input device via the Wi-Fi connection.
[0114] In a specific implementation, after establishing a WiFi connection with the input device, in order to reduce power consumption during the communication process, this embodiment further pairs the input device through the WiFi connection. The pairing is used to activate the lora communication module to communicate with the input device.
[0115] It should be noted that during the pairing process with the input device via Wi-Fi connection, the green light on the wearable device flashes.
[0116] Step S30': After pairing is successful, establish a lora communication connection with the input device.
[0117] In the specific implementation, LoRa communication is a low-power communication mode. In order to reduce communication power consumption, after establishing a WiFi connection with the wearable device, the WiFi connection is switched to a LoRa communication connection, and then communication is carried out through the LoRa communication connection to achieve the purpose of reducing power consumption.
[0118] This embodiment establishes a WiFi connection with the input device; pairs with the input device through the WiFi connection; after pairing is successful, establishes a LoRa communication connection with the input device, establishes a WiFi connection between the input device and the wearable device, pairs the LoRa communication through the established WiFi connection, and after pairing is successful, switches to the LoRa communication connection for communication, which simplifies the device connection process and also reduces power consumption.
[0119] refer to Figure 7 , Figure 7 This is a flow chart of a fourth embodiment of a device connection method according to the present invention.
[0120] Based on the first embodiment above, in the device connection method of this embodiment, step S20′ specifically includes:
[0121] Step S201 ′: receiving pairing information transmitted by the input device through the Wi-Fi connection.
[0122] In a specific implementation, after establishing a WiFi connection with the input device, in this embodiment, pairing information transmitted by the input device is received through the WiFi connection, and the pairing information is used to activate the lora communication module to communicate with the input device.
[0123] Step S202 ′: after receiving the pairing information, perform data frame pairing with the input device based on the pairing information.
[0124] In a specific implementation, after receiving the pairing information transmitted by the input device, the input device and the wearable device exchange pairing frames, that is, data frame pairing. After the pairing is completed, a lora communication connection can be established with the input device.
[0125] Furthermore, in this embodiment, after establishing a LoRa communication connection with the input device, the input device communicates with the wearable device via the LoRa communication connection, and the input device sends the user's action information to the wearable device via the LoRa communication connection. In addition, in this embodiment, the communication status of the LoRa communication connection is detected in real time. If the communication status is normal, it means that the LoRa communication is stable at this time. In this case, in this embodiment, the previously established WiFi connection will be disconnected.
[0126] It should be noted that during the communication process through the lora communication connection, the indicator lights of the input device and the wearable device are blue and are always on.
[0127] It is easy to understand that if the user does not operate the input device for a long time, in order to avoid increasing unnecessary power consumption, the input device will be controlled to sleep in this embodiment, and the input device will send a sleep frame. If the sleep frame sent by the input device is received, the current mode of the wearable device will also be adjusted to sleep mode in this embodiment to reduce power consumption.
[0128] Furthermore, when the input device and the wearable device enter the lora sleep mode, the blue light on the input device and the wearable device flashes, and the flashing speed is slow at this time, in the state of slow blue flashing. It should be emphasized that the above light color can also be adjusted accordingly according to the actual needs of the user, and this is not limited in this embodiment.
[0129] This embodiment receives the pairing information transmitted by the input device through the WiFi connection; after receiving the pairing information, data frame pairing is performed with the input device based on the pairing information, so that the input device and the wearable device can establish a LoRa communication connection quickly and accurately. At the same time, when it is detected that the LoRa communication is in a normal communication state, the WiFi connection is disconnected, and after receiving the sleep frame sent by the input device, the current working mode is adjusted to the sleep mode. Through the LoRa communication connection and the adjustment of the sleep mode, the power consumption during the communication between the input device and the wearable device is further reduced.
[0130] Reference Figure 8 , Figure 8 This is a structural block diagram of the first embodiment of the device connection apparatus of the present invention.
[0131] like Figure 8 As shown, the device connection device proposed in the embodiment of the present invention includes:
[0132] The communication module 10' is used to establish a Wi-Fi connection with the input device.
[0133] The communication module 10 ′ is further configured to be paired with the input device via the Wi-Fi connection.
[0134] The communication module 10' is further configured to establish a LoRa communication connection with the input device after pairing is successful.
[0135] This embodiment establishes a WiFi connection with the input device; pairs with the input device through the WiFi connection; after pairing is successful, establishes a LoRa communication connection with the input device, establishes a WiFi connection between the input device and the wearable device, pairs the LoRa communication through the established WiFi connection, and after pairing is successful, switches to the LoRa communication connection for communication, which simplifies the device connection process and also reduces power consumption.
[0136] In addition, an embodiment of the present invention further provides a storage medium, on which a device connection program is stored. When the device connection program is executed by a processor, the steps of the device connection method described above are implemented.
[0137] Since the storage medium adopts all the technical solutions of all the above embodiments, it has at least all the beneficial effects brought by the technical solutions of the above embodiments, which will not be described one by one here.
[0138] It should be understood that the above is only an example and does not constitute any limitation to the technical solution of the present invention. In specific applications, those skilled in the art can make settings as needed, and the present invention does not impose any limitation on this.
[0139] It should be noted that the workflow described above is merely illustrative and does not limit the scope of protection of the present invention. In practical applications, technicians in this field can select part or all of it according to actual needs to achieve the purpose of the embodiment scheme, and no limitation is made here.
[0140] In addition, for technical details not fully described in this embodiment, please refer to the device connection method provided in any embodiment of the present invention, and will not be repeated here.
[0141] In addition, it should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or system comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or system. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or system comprising the element.
[0142] The serial numbers of the above embodiments of the present invention are for description only and do not represent the advantages or disadvantages of the embodiments.
[0143] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, or of course by hardware, but in many cases the former is a better embodiment. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. The computer software product is stored in a storage medium (such as a read-only memory (ROM) / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.
[0144] The above are only preferred embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention description and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A device connection method, characterized in that: The device connection method is applied to input devices; The input device is a VR controller; The device connection method includes: Scanning the QR code information of the wearable device through the camera of the input device; the wearable device is VR glasses; Extracting network connection information from the QR code information; Establishing a Wi-Fi connection with the wearable device according to the network connection information; Pairing with the wearable device via the Wi-Fi connection; After pairing is successful, establish a lora communication connection with the wearable device; After the pairing is successful and a lora communication connection is established with the wearable device, the method further includes: Performing Lora communication with the wearable device via the Lora communication connection; When it is detected that the lora communication is in a normal communication state, disconnecting the wifi connection; The device connection method further includes: When no user operation is received within a preset time, the current working mode is adjusted to the sleep mode, and a sleep frame is sent to the wearable device to adjust the current working mode of the wearable device to the sleep mode; The pairing with the wearable device through the Wi-Fi connection includes: Transmitting pairing information to the wearable device via the Wi-Fi connection; After the wearable device receives the pairing information, data frame pairing is performed with the wearable device based on the pairing information.
2. A device connection device, characterized in that: The device connection device is applied to an input device; The input device is a VR controller; The device connection device comprises: A shooting module, configured to scan the QR code information of a wearable device through the camera of the input device; the wearable device is a VR glasses; A reading module, configured to extract network connection information from the QR code information; A communication module, configured to establish a Wi-Fi connection with the wearable device according to the network connection information; The communication module is further configured to pair with the wearable device via the Wi-Fi connection; The communication module is further configured to establish a lora communication connection with the wearable device after successful pairing; The communication module is further configured to perform lora communication with the wearable device through the lora communication connection; and disconnect the wifi connection when it is detected that the lora communication is in a normal communication state; The communication module is further configured to adjust the current working mode to the sleep mode when no user operation is received within a preset time, and send a sleep frame to the wearable device to adjust the current working mode of the wearable device to the sleep mode; The communication module is further configured to transmit pairing information to the wearable device through the Wi-Fi connection; after the wearable device receives the pairing information, the wearable device performs data frame pairing with the wearable device based on the pairing information.
3. An input device, characterized in that: The input device includes: a memory, a processor, and a device connection program stored in the memory and running on the processor, wherein the device connection program is configured to implement the device connection method according to claim 1.
4. A device connection method, characterized in that: The device connection method is applied to wearable devices; The wearable device is VR glasses; The device connection method includes: Establish a Wi-Fi connection with the input device; the input device is a VR controller; Pairing with the input device via the Wi-Fi connection; After pairing is successful, a lora communication connection is established with the input device; After the pairing is successful and a lora communication connection is established with the input device, the method further includes: Performing Lora communication with the input device via the Lora communication connection; When it is detected that the lora communication is in a normal communication state, disconnecting the wifi connection; The device connection method further includes: When no user operation is received within a preset time, the current working mode is adjusted to the sleep mode, and a sleep frame is sent to the input device to adjust the current working mode of the input device to the sleep mode; The pairing with the input device through the Wi-Fi connection includes: transmitting pairing information to the input device via the Wi-Fi connection; After the input device receives the pairing information, data frame pairing is performed with the input device based on the pairing information.
5. A device connection device, characterized in that: The device connection device is used for Wearable device; the wearable device is VR glasses; The device connection device comprises: A communication module, used to establish a Wi-Fi connection with an input device; the input device is a VR controller; The communication module is further configured to pair with the input device via the Wi-Fi connection; The communication module is further configured to establish a LoRa communication connection with the input device after successful pairing; The communication module is further configured to perform lora communication with the input device through the lora communication connection; and disconnect the wifi connection when it is detected that the lora communication is in a normal communication state; The communication module is further configured to adjust the current working mode to the sleep mode when no user operation is received within a preset time, and send a sleep frame to the input device to adjust the current working mode of the input device to the sleep mode; The communication module is further configured to transmit pairing information to the input device via the Wi-Fi connection; and after receiving the pairing information, perform data frame pairing with the input device based on the pairing information.
6. A wearable device, characterized in that: The wearable device includes: a memory, a processor, and a device connection program stored in the memory and running on the processor, wherein the device connection program is configured to implement the device connection method according to claim 4.
7. A storage medium, characterized in that: The storage medium stores a device connection program, which, when executed by the processor, implements the device connection method according to any one of claims 1 or 4.
Citation Information
Patent Citations
Data transmission method and device and terminal
CN107343325A
Wireless connection method for mobile robot and hand manipulator and mobile robot system
CN109068398A
Wireless network connection system
CN212660337U