TW201717595A - Smart device, and method and apparatus for establishing bluetooth connection between devices therefor - Google Patents
Smart device, and method and apparatus for establishing bluetooth connection between devices therefor Download PDFInfo
- Publication number
- TW201717595A TW201717595A TW105135509A TW105135509A TW201717595A TW 201717595 A TW201717595 A TW 201717595A TW 105135509 A TW105135509 A TW 105135509A TW 105135509 A TW105135509 A TW 105135509A TW 201717595 A TW201717595 A TW 201717595A
- Authority
- TW
- Taiwan
- Prior art keywords
- bluetooth
- target
- module
- establishing
- connection
- Prior art date
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W76/00—Connection management
- H04W76/10—Connection setup
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
Description
本發明係關於藍牙通訊領域,尤其關於一種智慧設備及其建立藍牙連接的方法、裝置。 The present invention relates to the field of Bluetooth communication, and more particularly to a smart device and a method and apparatus for establishing a Bluetooth connection.
隨著網際網路技術,尤其是行動網際網路和物聯網的發展,藉助與智慧手機等智慧設備與環境周邊的智慧卡進行連接通訊的需求在逐漸增多。其中藍牙通訊技術,尤其是低功耗藍牙通訊技術成為了一種重要的通訊方式。目前智慧設備建立藍牙連接時,一般要通過掃描周邊的藍牙信號,將周邊的藍牙設備列舉並展示給使用者,由使用者選擇要連接的藍牙設備進行連接操作。但隨著支持藍牙通訊的設備增多,智慧設備通常掃描出的周邊藍牙設備的資料較多,智慧設備將為使用者提供較長的周邊藍牙設備列表,為使用者正確選擇目標藍牙設備造成困難。 With the development of Internet technologies, especially the mobile Internet and the Internet of Things, there is an increasing demand for communication with smart devices such as smart phones and smart cards around the environment. Among them, Bluetooth communication technology, especially low-power Bluetooth communication technology has become an important communication method. At present, when a smart device establishes a Bluetooth connection, it generally needs to scan and display the surrounding Bluetooth devices to the user, and the user selects the Bluetooth device to be connected to perform the connection operation. However, as the number of devices supporting Bluetooth communication increases, the smart device usually scans out the surrounding Bluetooth devices, and the smart device will provide the user with a long list of peripheral Bluetooth devices, which is difficult for the user to correctly select the target Bluetooth device.
為更精準的與目標藍牙設備建立連接,當前有以下解決方案。 In order to establish a more accurate connection with the target Bluetooth device, the following solutions are currently available.
智慧終端通過拍攝並解析印刷在目標藍牙設備外殼或其說明書上的物理地址(MAC地址)資訊來實現與目標藍牙設備的配對操作。 The smart terminal performs pairing operation with the target Bluetooth device by capturing and parsing the physical address (MAC address) information printed on the target Bluetooth device housing or its manual.
但這種方式存在以下不足:若MAC地址資訊印刷在目標藍牙設備外殼,則必然對目標藍牙設備的外殼面積有 要求,方法靈活性受到限制;若印刷在目標設備說明書上,則必然給使用者造成不便,影響使用者體驗;因為僅獲取了目標藍牙設備的MAC地址資訊,智慧終端還需一直保持掃描發現周邊藍牙設備,影響系統效率;且建立藍牙連接的主動權完全掌握在智慧終端一方,目標藍牙設備只能被動連接,不能對發起連接的一方進行驗證,影響系統的安全性。 However, this method has the following disadvantages: if the MAC address information is printed on the target Bluetooth device shell, the shell area of the target Bluetooth device must be Requirements, method flexibility is limited; if printed on the target device manual, it will inevitably cause inconvenience to the user, affecting the user experience; because only the MAC address information of the target Bluetooth device is obtained, the smart terminal needs to keep scanning to find the periphery. The Bluetooth device affects the system efficiency; and the initiative to establish a Bluetooth connection is completely in the smart terminal side. The target Bluetooth device can only be passively connected, and the party that initiated the connection cannot be verified, which affects the security of the system.
本發明實施例期望提供一種智慧設備及其建立設備間藍牙連接的方法、裝置,能更高效、更安全的建立藍牙連接,提高使用者體驗。 Embodiments of the present invention are directed to providing a smart device and a method and apparatus for establishing a Bluetooth connection between devices, which can establish a Bluetooth connection more efficiently and safely, and improve user experience.
本發明實施例的技術方案是這樣實現的。 The technical solution of the embodiment of the present invention is implemented in this way.
本發明實施例提供了一種建立設備間藍牙連接方法,該方法包括:獲取目標藍牙設備的匹配參數;打開自身的藍牙模組;開啟藍牙模組掃描功能;當掃描到與獲取到的匹配參數相匹配的目標藍牙設備後,停止藍牙模組掃描功能,建立藍牙連接;其中,所述匹配參數包括與所述目標藍牙設備唯一對應的參數、配對密碼、目標藍牙設備的藍牙名稱或者是服務匹配過濾規則參數資訊。 An embodiment of the present invention provides a method for establishing a Bluetooth connection between devices. The method includes: acquiring a matching parameter of a target Bluetooth device; opening a Bluetooth module of the device; enabling a scanning function of the Bluetooth module; and scanning and matching the acquired matching parameters After the matching target Bluetooth device, the Bluetooth module scanning function is stopped, and a Bluetooth connection is established; wherein the matching parameter includes a parameter uniquely corresponding to the target Bluetooth device, a pairing password, a Bluetooth name of the target Bluetooth device, or a service matching filter. Rule parameter information.
上述的方法,當掃描時:以一定頻率停止並重新啟動掃描動作,並重複此過程;實時匹配掃描返回的周邊藍牙設備的廣播資訊,根據掃描之前獲取的匹配參數進行匹配,匹配成功則首先停止掃描功能,再進行下一步連接。 The above method, when scanning: stopping and restarting the scanning action at a certain frequency, and repeating the process; real-time matching the broadcast information of the surrounding Bluetooth devices returned by the scan, matching according to the matching parameters obtained before the scanning, and the matching is successful first Scan the function and then proceed to the next connection.
上述的方法,當所述目標藍牙設備是藍牙智慧卡時, 所述獲取目標藍牙設備的匹配參數包括:智慧設備通過撥號或者短訊進行所述藍牙智慧卡廣播資訊的重置;或者智慧設備通過內部的第二通道獲取所述藍牙智慧卡的廣播資訊。 The above method, when the target Bluetooth device is a Bluetooth smart card, The obtaining the matching parameter of the target Bluetooth device includes: the smart device performing the resetting of the Bluetooth smart card broadcast information by using a dialing or a short message; or the smart device acquiring the broadcast information of the Bluetooth smart card through the internal second channel.
上述的方法,所述方法還包括:所述目標藍牙設備針對所述建立設備間藍牙連接的請求進行驗證。 In the above method, the method further includes: the target Bluetooth device verifying the request for establishing a Bluetooth connection between the devices.
上述的方法,當針對所述建立設備間藍牙連接的請求的發起方進行驗證時,所述驗證包括:所述目標藍牙設備產生隨機數,用預置的密鑰和算法對所述隨機數進行加密,發送到所述建立藍牙連接請求的發起方;所述發起方解密所述隨機數,並處理之後發送回所述目標藍牙設備;所述目標藍牙設備對所述發起方發送的資料進行解密比對,符合約定規則,則通過驗證,維持連接;否則,所述目標藍牙設備斷開連接。 In the above method, when the initiator of the request for establishing a Bluetooth connection between devices is verified, the verification includes: the target Bluetooth device generates a random number, and performs the random number by using a preset key and an algorithm. Encrypted, sent to the initiator that establishes a Bluetooth connection request; the initiator decrypts the random number, and then sends back to the target Bluetooth device; the target Bluetooth device decrypts the data sent by the initiator If the comparison is in accordance with the agreed rules, the connection is maintained through verification; otherwise, the target Bluetooth device is disconnected.
上述的方法,當在智慧設備與所述目標藍牙設備建立藍牙連接後進行驗證,所述驗證包括:所述目標藍牙設備產生一個隨機數,並用預置的密鑰和算法進行加密,並把此資料發送給所述智慧設備;所述智慧設備用約定的密鑰和算法進行解密,對解密的所述隨機數進行加一處理,重新加密後回傳給所述目標藍牙設備;所述目標藍牙設備解密回傳資料,判斷是否能重新解密成功,成功則比對所述隨機數,如果為原數加一,則驗證通過,否則驗證失敗,在3s內無資料則驗證失敗;驗證失敗則所述目標藍牙設備斷開所述藍牙連接。 The above method, when the smart device establishes a Bluetooth connection with the target Bluetooth device, the verification comprises: the target Bluetooth device generates a random number, and encrypts with a preset key and algorithm, and Sending the data to the smart device; the smart device decrypts with the agreed key and algorithm, adds a process to the decrypted random number, re-encrypts and transmits back to the target Bluetooth device; the target Bluetooth The device decrypts the returned data to determine whether the decryption can be successfully decrypted. If the success is successful, the random number is compared. If the original number is increased by one, the verification is passed. Otherwise, the verification fails. If there is no data within 3 seconds, the verification fails; if the verification fails, the verification fails. The target Bluetooth device disconnects the Bluetooth connection.
上述的方法,所述目標藍牙設備為藍牙卡。 In the above method, the target Bluetooth device is a Bluetooth card.
本發明還提供一種智慧設備的建立藍牙連接裝置,該裝置用於實現上述建立藍牙連接的方法中由智慧設備(主設備方)完成的操作,該裝置包括:獲取匹配參數模組、打開藍牙模組、開啟掃描模組和匹配設備模組;其中,獲取匹配參數模組,用於獲取目標藍牙設備的匹配參數;打開藍牙模組,用於打開自身的藍牙模組;開啟掃描模組,用於開啟藍牙模組掃描功能;匹配設備模組,用於當掃描到與獲取到的匹配參數相匹配的目標藍牙設備後,停止藍牙模組掃描功能。 The present invention also provides a Bluetooth connection device for establishing a smart device, wherein the device is used to implement the operation performed by the smart device (the master device side) in the method for establishing a Bluetooth connection, and the device includes: acquiring a matching parameter module, and opening a Bluetooth module. The group, the scanning module and the matching device module are opened; wherein the matching parameter module is obtained for acquiring matching parameters of the target Bluetooth device; the Bluetooth module is opened for opening the Bluetooth module thereof; and the scanning module is enabled. The Bluetooth module scanning function is enabled; the matching device module is configured to stop the Bluetooth module scanning function after scanning the target Bluetooth device that matches the acquired matching parameter.
本發明還提供一種智慧設備,該智慧設備中包括上述智慧設備的建立藍牙連接的裝置,所述智慧設備具有藍牙模組。 The invention also provides a smart device, which comprises a device for establishing a Bluetooth connection of the smart device, wherein the smart device has a Bluetooth module.
上述的智慧設備是智慧手機或平板電腦。 The above smart device is a smart phone or tablet.
本發明實施例所提供的智慧設備及其建立藍牙連接的方法、裝置,不限定預置的連接資訊為藍牙MAC地址,擴展了獲取藍牙匹配參數的渠道;通過先獲取目標藍牙設備的匹配參數,使得發現目標藍牙設備的效率更高;此外,本發明還增加了反應方對發起方的合法性驗證功能,提高了反應方的安全性。 The smart device provided by the embodiment of the present invention and the method and device for establishing the Bluetooth connection do not limit the preset connection information to a Bluetooth MAC address, and expand the channel for acquiring the Bluetooth matching parameter; by first obtaining the matching parameter of the target Bluetooth device, The efficiency of discovering the target Bluetooth device is higher; in addition, the invention also increases the legality verification function of the responder to the initiator, and improves the security of the responder.
101-104‧‧‧步驟 101-104‧‧‧Steps
301‧‧‧獲取匹配參數模組 301‧‧‧Get matching parameter module
302‧‧‧打開藍牙模組 302‧‧‧Open Bluetooth module
303‧‧‧開啟掃描模組 303‧‧‧Open scanning module
304‧‧‧匹配設備模組 304‧‧‧Matching device module
圖1為本發明實施例提供的藍牙連接建立方法的實現流程示意圖。 FIG. 1 is a schematic flowchart of an implementation process of a Bluetooth connection establishment method according to an embodiment of the present invention.
圖2為本發明提供的藍牙設備間連接建立方法在應用 在實施例1中的流程示意圖。 FIG. 2 is a schematic diagram of a method for establishing a connection between Bluetooth devices according to the present invention. Schematic diagram of the process in Example 1.
圖3為本發明實施例提供的藍牙連接建立裝置的結構示意圖。 FIG. 3 is a schematic structural diagram of a Bluetooth connection establishing apparatus according to an embodiment of the present invention.
為了更清楚地說明本發明實施例和技術方案,下面將結合圖式及實施例對本發明的技術方案進行更詳細的說明,顯然,所描述的實施例是本發明的一部分實施例,而不是全部實施例。基於本發明的實施例,所屬技術領域中具有通常知識者在不逸離本發明精神的前提下所獲得的所有其他實施例,都屬於本發明保護的範圍。 In order to more clearly illustrate the embodiments and technical solutions of the present invention, the technical solutions of the present invention will be described in more detail below with reference to the drawings and embodiments. It is obvious that the described embodiments are a part of the embodiments of the present invention, and not all Example. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without departing from the spirit of the invention are within the scope of the invention.
在本發明實施例中,藍牙連接的發起方(主設備方)為智慧設備,可以是智慧手機、平板電腦等各種具有藍牙模組的智慧設備;藍牙連接的反應方(從設備方)為智慧卡,可以是具有藍牙介面的SIM(Subscriber Identity Module客戶識別模組)卡、USIM(Universal Subscriber Identity Module,全球使用者識別)卡、UIM(User Identify Module,使用者識別模組)卡和SD卡(Secure Digital Memory Card,安全數位記憶卡)等各種智慧卡,也稱為藍牙卡。 In the embodiment of the present invention, the initiator (master device side) of the Bluetooth connection is a smart device, which may be a smart device with a Bluetooth module, such as a smart phone or a tablet computer; the reaction party of the Bluetooth connection (from the device side) is wisdom. The card may be a SIM (Subscriber Identity Module) card with a Bluetooth interface, a USIM (Universal Subscriber Identity Module) card, a UIM (User Identify Module) card, and an SD card. (Secure Digital Memory Card, etc.) Various smart cards, also known as Bluetooth cards.
圖1為本發明提供的藍牙設備間連接建立方法的實現流程示意圖,如圖1所示,該方法包括以下步驟。 FIG. 1 is a schematic flowchart of an implementation method for establishing a connection between Bluetooth devices according to the present invention. As shown in FIG. 1, the method includes the following steps.
步驟101,獲取目標藍牙設備的匹配參數。 Step 101: Acquire matching parameters of the target Bluetooth device.
具體的,智慧設備獲取目標藍牙設備的匹配參數,這裏,所述目標藍牙設備是指智慧設備使用者希望與之建立 藍牙連接的設備,藍牙設備可以是藍牙智慧卡或其他支持藍牙通訊協議的設備,而所述匹配參數可以包括例如目標設備的MAC地址等與藍牙設備唯一對應的參數、配對密碼、藍牙設備的藍牙名稱或者是服務匹配過濾規則等參數資訊。 Specifically, the smart device acquires a matching parameter of the target Bluetooth device, where the target Bluetooth device refers to the user who wants to establish the smart device. For a Bluetooth-connected device, the Bluetooth device may be a Bluetooth smart card or other device supporting the Bluetooth communication protocol, and the matching parameter may include, for example, a MAC address of the target device, a parameter uniquely corresponding to the Bluetooth device, a pairing password, and Bluetooth of the Bluetooth device. The name or the parameter information such as the service matching filter rule.
進一步的,當所述藍牙設備是藍牙智慧卡時,所述獲取目標藍牙設備的匹配參數可以包括:智慧設備通過撥號或者短訊進行藍牙智慧卡廣播資訊的重置。 Further, when the Bluetooth device is a Bluetooth smart card, the acquiring the matching parameter of the target Bluetooth device may include: the smart device resetting the Bluetooth smart card broadcast information by using a dialing or a short message.
或者,智慧設備通過內部的第二通道獲取所述藍牙智慧卡的廣播資訊,例如,手機可通過7816介面讀取SIM卡的行動設備國際身份碼(International Mobile Equipment Identity,IMEI),藍牙SIM卡也約定廣播國際行動用戶識別碼(International Mobile Subscriber Identification Number,IMSI)號作為藍牙配對密碼。 Alternatively, the smart device obtains the broadcast information of the Bluetooth smart card through the internal second channel. For example, the mobile phone can read the SIM card mobile device international identity code (IMEI) through the 7816 interface, and the Bluetooth SIM card also The International Mobile Subscriber Identification Number (IMSI) number is agreed as the Bluetooth pairing password.
本方案不限定預置的匹配措施,此步驟中只要能夠獲取到後續可用於藍牙配對的參數資訊即可。 This solution does not limit the preset matching measures. In this step, as long as the parameter information that can be used for Bluetooth pairing can be obtained.
步驟102,打開自身的藍牙模組。 Step 102, open its own Bluetooth module.
具體的,智慧設備打開自身的藍牙模組。 Specifically, the smart device opens its own Bluetooth module.
實際應用中,打開藍牙模組與獲取智慧卡匹配參數沒有必然的先後關係,只要保證這兩項操作在開啟藍牙模組掃描功能之前進行即可。 In practical applications, there is no necessary relationship between opening the Bluetooth module and obtaining the smart card matching parameters, as long as the two operations are performed before the Bluetooth module scanning function is enabled.
步驟103,開啟藍牙模組掃描功能。 In step 103, the Bluetooth module scanning function is turned on.
具體的,智慧設備開啟自身的藍牙模組的掃描功能,掃描周邊的藍牙設備。 Specifically, the smart device turns on the scanning function of its own Bluetooth module and scans the surrounding Bluetooth devices.
進一步的,為提供發現效率,智慧設備自身的藍牙模組可以選擇以一定頻率停止並重新啟動掃描動作,重複此過程,例如,重複頻率為1-5s停止啟動一次。 Further, in order to provide discovery efficiency, the smart device's own Bluetooth module can choose to stop and restart the scanning action at a certain frequency, and repeat the process, for example, the repetition frequency is 1-5s to stop starting once.
步驟104,當掃描到與獲取到的匹配參數相匹配的目標藍牙設備後,停止藍牙模組掃描功能。 Step 104: After scanning the target Bluetooth device that matches the acquired matching parameter, stop the Bluetooth module scanning function.
具體的,智慧設備根據接收到的藍牙廣播中廣播的匹配參數,判斷是否與步驟101中獲取到的匹配參數相同,如果相同,則確定發出該廣播的藍牙設備為目標藍牙設備,因此,可停止智慧設備自身藍牙模組的掃描功能。 Specifically, the smart device determines, according to the matching parameter broadcasted in the received Bluetooth broadcast, whether it is the same as the matching parameter obtained in step 101. If the same, the Bluetooth device that sends the broadcast is determined to be the target Bluetooth device, and therefore, the device can stop. The scanning function of the smart device's own Bluetooth module.
需要特別說明的,在智慧設備啟動掃描周圍藍牙設備之後,可能會搜索到多個藍牙設備,智慧設備的掃描功能是異步的,需要有匹配模組實時匹配掃描模組返回的周邊藍牙設備的廣播資訊,根據掃描之前獲取的匹配參數進行匹配,匹配成功則首先停止掃描功能,並進行下一步連接。 It should be specially stated that after the smart device starts scanning the surrounding Bluetooth devices, multiple Bluetooth devices may be searched. The scanning function of the smart device is asynchronous, and the matching module needs to match the broadcast of the surrounding Bluetooth devices returned by the scanning module in real time. The information is matched according to the matching parameters obtained before the scanning. If the matching is successful, the scanning function is first stopped, and the next connection is performed.
在掃描執行時可以採取間隙停止、啟動掃描的策略,來提高智慧設備對周邊藍牙智慧卡的發現能力。 During the scanning execution, a strategy of stopping the gap and starting the scanning may be adopted to improve the ability of the smart device to discover the surrounding Bluetooth smart card.
之後,智慧設備使用自身的藍牙模組連接匹配到的目標藍牙設備。 After that, the smart device uses its own Bluetooth module to connect to the matching target Bluetooth device.
進一步的,根據業務需要,在智慧設備發出建立藍牙連接請求後,上述藍牙設備間連接建立方法還包括:接受目標藍牙設備針對所述建立藍牙連接請求進行的驗證。 Further, after the smart device sends a request for establishing a Bluetooth connection, the method for establishing a connection between the Bluetooth devices further includes: accepting, by the target Bluetooth device, the verification performed by the target Bluetooth device for the Bluetooth connection request.
具體的,目標藍牙設備根據業務需要,可以針對所述建立藍牙連接請求的發起方進行驗證,在一個實施例中,所述驗證可以包括:目標設備產生隨機數,用預置的密鑰 和算法對隨機數進行加密,發送到所述建立藍牙連接請求的發起方。 Specifically, the target Bluetooth device may perform verification on the initiator that establishes the Bluetooth connection request according to the service requirement. In an embodiment, the verification may include: the target device generates a random number, and uses the preset key. And the algorithm encrypts the random number and sends it to the initiator that establishes the Bluetooth connection request.
發起方(智慧設備)解密該隨機數,並處理之後發送回目標藍牙設備。 The initiator (smart device) decrypts the random number and processes it and sends it back to the target Bluetooth device.
目標設備對發起方發送的資料進行解密比對,符合約定規則,則通過驗證,維持連接;否則,目標設備斷開連接。 The target device decrypts the data sent by the initiator, and conforms to the agreed rules, and then maintains the connection through verification; otherwise, the target device disconnects.
上述驗證過程,也可以在智慧設備與目標藍牙設備建立藍牙連接後進行,例如,連接成功後,目標藍牙設備可通過自身驗證模組進行連接發起方的合法性驗證。 The above verification process may also be performed after the smart device establishes a Bluetooth connection with the target Bluetooth device. For example, after the connection is successful, the target Bluetooth device can perform the validity verification of the connection initiator through the self-authentication module.
(1)產生一個隨機數,並用預置的密鑰和算法進行加密,並把此資料發送給智慧設備。 (1) Generate a random number and encrypt it with a preset key and algorithm, and send this data to the smart device.
(2)智慧設備用約定的密鑰和算法進行解密,對解密的隨機數進行加一處理,重新加密後回傳給藍牙智慧卡。 (2) The smart device decrypts with the agreed key and algorithm, adds the decrypted random number, re-encrypts and transmits it back to the Bluetooth smart card.
(3)目標藍牙設備解密回傳資料,看是否能重新解密成功,成功則比對隨機數,如果為原數加一,則驗證通過,否則驗證失敗,在3s內無資料則驗證失敗。 (3) The target Bluetooth device decrypts the returned data to see if it can be decrypted successfully. If the success is successful, the random number is compared. If the original number is increased by one, the verification is passed. Otherwise, the verification fails. If there is no data within 3 seconds, the verification fails.
(4)驗證失敗則目標藍牙設備斷開此藍牙連接。 (4) If the verification fails, the target Bluetooth device disconnects the Bluetooth connection.
以上驗證方式只是目標藍牙設備對發起方的一種合法性驗證,並不限於所述方式,屬於是藍牙周邊設備對中心設備的合法性進行驗證這一方式。 The above verification method is only a kind of legality verification of the target Bluetooth device to the initiator, and is not limited to the above manner, and belongs to a method in which the Bluetooth peripheral device verifies the legality of the central device.
實施例1 Example 1
圖2為本發明提供的藍牙設備間連接建立方法在應用 在實施例1中的流程示意圖,在實施例1中,智慧設備為智慧手機,而目標藍牙設備為藍牙智慧卡如圖2所示,獲取藍牙卡的匹配參數與打開藍牙模組沒有先後關係,此兩個步驟都要在開啟藍牙模組的掃描功能之前。其中匹配參數可以通過印在外殼上的條碼、二維碼等資訊,使用者通過掃描獲取;如果是SIM卡,也可以通過撥號或者短訊進行廣播資訊的重置來達到統一;或者通過智慧設備內部的第二通道獲取藍牙智慧卡的廣播資訊(手機可通過7816介面讀取SIM卡的IMSI號,藍牙SIM卡也約定廣播IMSI號)。此步驟包括但不限於以上所提方式。在啟動掃描周圍藍牙卡之後,可能會搜索到多個藍牙設備,智慧設備的掃描功能是異步的,需要有匹配模組實時匹配掃描模組返回的周邊藍牙設備的廣播資訊,根據掃描之前獲取的匹配參數進行匹配,匹配成功則首先停止掃描功能,並進行下一步連接。在掃描執行時可以採取間隙停止、啟動掃描的策略,來提高智慧設備對周邊藍牙智慧卡的發現能力。連接成功後,智慧藍牙卡可通過自身驗證模組進行連接發起方的合法性驗證。 FIG. 2 is a schematic diagram of a method for establishing a connection between Bluetooth devices according to the present invention. In the first embodiment, the smart device is a smart phone, and the target Bluetooth device is a Bluetooth smart card. As shown in FIG. 2, the matching parameters of the Bluetooth card are not related to the opening of the Bluetooth module. Both steps must be before the scanning function of the Bluetooth module is turned on. The matching parameter can be obtained by scanning the bar code, the two-dimensional code and the like on the outer casing, and the user can obtain the information by scanning, or if the SIM card is used, the broadcast information can be reset by dialing or short message to achieve uniformity; or through the smart device. The internal second channel acquires the broadcast information of the Bluetooth smart card (the mobile phone can read the IMSI number of the SIM card through the 7816 interface, and the Bluetooth SIM card also agrees to broadcast the IMSI number). This step includes, but is not limited to, the above mentioned methods. After scanning the surrounding Bluetooth card, multiple Bluetooth devices may be searched. The scanning function of the smart device is asynchronous. The matching module needs to match the broadcast information of the surrounding Bluetooth devices returned by the scanning module in real time, according to the information acquired before the scanning. The matching parameters are matched. If the matching is successful, the scanning function is stopped first, and the next connection is made. During the scanning execution, a strategy of stopping the gap and starting the scanning may be adopted to improve the ability of the smart device to discover the surrounding Bluetooth smart card. After the connection is successful, the smart Bluetooth card can verify the validity of the connection initiator through its own verification module.
(1)產生一個隨機數,並用預置的密鑰和算法進行加密,並把此資料發送給智慧設備。 (1) Generate a random number and encrypt it with a preset key and algorithm, and send this data to the smart device.
(2)智慧設備用約定的密鑰和算法進行解密,對解密的隨機數進行加一處理,重新加密後回傳給藍牙智慧卡。 (2) The smart device decrypts with the agreed key and algorithm, adds the decrypted random number, re-encrypts and transmits it back to the Bluetooth smart card.
(3)藍牙智慧卡解密回傳資料,看是否能重新解 密成功,成功則比對隨機數,如果為原數加一,則驗證通過,否則驗證失敗,在3s內無資料則驗證失敗。 (3) Bluetooth smart card decrypts the returned data to see if it can be re-solved If the secret is successful, the success compares the random number. If the original number is increased by one, the verification is passed. Otherwise, the verification fails. If there is no data within 3 seconds, the verification fails.
(4)驗證失敗則藍牙智慧卡斷開此藍牙連接。 (4) If the verification fails, the Bluetooth smart card disconnects the Bluetooth connection.
以上驗證方式只是藍牙智慧卡對發起方的一種合法性驗證,並不限於所述方式,屬於是藍牙周邊設備對中心設備的合法性進行驗證這一方式。 The above verification method is only a legality verification of the Bluetooth smart card to the initiator, and is not limited to the above manner, and belongs to a method in which the Bluetooth peripheral device verifies the legality of the central device.
本發明還提供一種智慧設備的建立藍牙連接裝置,該裝置用於實現上述建立藍牙連接方法中由智慧設備(主設備方)完成的操作,如圖3所示,該裝置包括:獲取匹配參數模組301、打開藍牙模組302、開啟掃描模組303和匹配設備模組304。 The present invention also provides a Bluetooth connection device for establishing a smart device. The device is used to implement the operation performed by the smart device (the master device side) in the method for establishing a Bluetooth connection. As shown in FIG. 3, the device includes: acquiring a matching parameter module. The group 301 opens the Bluetooth module 302, turns on the scanning module 303, and matches the device module 304.
其中,獲取匹配參數模組301,用於獲取目標藍牙設備的匹配參數。 The matching parameter module 301 is configured to acquire matching parameters of the target Bluetooth device.
打開藍牙模組302,用於打開自身的藍牙模組。 The Bluetooth module 302 is turned on to open its own Bluetooth module.
開啟掃描模組303,用於開啟藍牙模組掃描功能。 The scanning module 303 is turned on to enable the scanning function of the Bluetooth module.
匹配設備模組304,用於當掃描到與獲取到的匹配參數相匹配的目標藍牙設備後,停止藍牙模組掃描功能。 The matching device module 304 is configured to stop the Bluetooth module scanning function after scanning the target Bluetooth device that matches the acquired matching parameter.
本發明還提供一種智慧設備,該智慧設備中包括上述智慧設備的建立藍牙連接裝置。 The invention also provides a smart device, wherein the smart device comprises a Bluetooth connection device for establishing the smart device.
本發明的通訊系統的各個模組對應執行上述通訊方法實施例所描述的步驟,因此具有相同的有益效果。另外,應該理解到,以上所描述的通訊系統的實施方式僅僅是示意性的,所描述模組的劃分,僅僅為一種邏輯功能劃分,實際實現時可以有另外的劃分方式。另外,模組相互之間 的耦合或通訊連接可以是通過一些介面,也可以是電性或其它的形式。 Each module of the communication system of the present invention corresponds to the steps described in the above embodiment of the communication method, and thus has the same advantageous effects. In addition, it should be understood that the implementation of the communication system described above is merely illustrative, and the division of the described modules is only a logical function division, and may be further divided in actual implementation. In addition, the modules are between each other The coupling or communication connection may be through some interface, or in electrical or other form.
上述各個功能模組作為通訊系統的組成部分,可以是或者也可以不是物理框,既可以位於一個地方,也可以分布到多個網路單元上,既可以採用硬體的形式實現,也可以採用軟體功能框的形式實現。可以根據實際的需要選擇其中的部分或者全部模組來實現本發明方案的目的。 Each of the above functional modules may or may not be a physical frame, and may be located in one place or on multiple network units, and may be implemented in a hardware form or in a hardware form. The form of the software function box is implemented. Some or all of the modules may be selected according to actual needs to achieve the objectives of the solution of the present invention.
所屬技術領域中具有通常知識者應明白,本發明的實施例可提供為方法、系統、或電腦程式產品。因此,本發明可採用硬體實施例、軟體實施例、或結合軟體和硬體方面的實施例的形式。而且,本發明可採用在一個或多個其中包含有電腦可用程式代碼的電腦可用儲存介質(包括但不限於磁碟儲存器和光學儲存器等)上實施的電腦程式產品的形式。 Those of ordinary skill in the art will appreciate that embodiments of the present invention can be provided as a method, system, or computer program product. Thus, the invention may take the form of a hardware embodiment, a software embodiment, or an embodiment incorporating a software and a hardware. Moreover, the present invention can take the form of a computer program product embodied on one or more computer usable storage media (including but not limited to disk storage and optical storage, etc.).
本發明是參照根據本發明實施例的方法、設備(系統)、和電腦程式產品的流程圖和/或方框圖來描述的。應理解可由電腦程式指令實現流程圖和/或方框圖中的每一流程和/或方框、以及流程圖和/或方框圖中的流程和/或方框的結合。可提供這些電腦程式指令到通用電腦、專用電腦、嵌入式處理機或其他可編程資料處理設備的處理器以產生一個機器,使得通過電腦或其他可編程資料處理設備的處理器執行的指令產生用於實現在流程圖一個流程或多個流程和/或方框圖一個方框或多個方框中指定的功能的裝置。 The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus, and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or FIG. These computer program instructions can be provided to a processor of a general purpose computer, a special purpose computer, an embedded processor or other programmable data processing device to produce a machine for generating instructions for execution by a processor of a computer or other programmable data processing device. Means for implementing the functions specified in one or more of the flow or in a block or blocks of the flow chart.
這些電腦程式指令也可儲存在能引導電腦或其他可編程資料處理設備以特定方式工作的電腦可讀儲存器中,使得儲存在該電腦可讀儲存器中的指令產生包括指令裝置的製造品,該指令裝置實現在流程圖一個流程或多個流程和/或方框圖一個方框或多個方框中指定的功能。 The computer program instructions can also be stored in a computer readable storage that can direct a computer or other programmable data processing device to operate in a particular manner, such that instructions stored in the computer readable storage produce an article of manufacture including the instruction device. The instruction means implements the functions specified in one or more blocks of the flow or in a flow or block diagram of the flowchart.
這些電腦程式指令也可裝載到電腦或其他可編程資料處理設備上,使得在電腦或其他可編程設備上執行一系列操作步驟以產生電腦實現的處理,從而在電腦或其他可編程設備上執行的指令提供用於實現在流程圖一個流程或多個流程和/或方框圖一個方框或多個方框中指定的功能的步驟。 These computer program instructions can also be loaded onto a computer or other programmable data processing device to perform a series of operational steps on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device. The instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
再次說明,以上所述僅為本發明的實施例,並非因此限制本發明的申請專利範圍,凡是利用本發明說明書及圖式內容所作的等效結構或等效流程變換,例如各實施例之間技術特徵的相互結合,或直接或間接運用在其他相關的技術領域,均同理包括在本發明的專利保護範圍內。 It is to be understood that the above description is only an embodiment of the present invention, and is not intended to limit the scope of the claims of the present invention. The equivalent structure or equivalent flow transformations made by the description of the present invention and the contents of the drawings, for example, between the embodiments The combination of technical features, or directly or indirectly, in other related technical fields is included in the scope of patent protection of the present invention.
101-104‧‧‧步驟 101-104‧‧‧Steps
Claims (10)
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510737899 | 2015-11-03 | ||
??201510737899.X | 2015-11-03 |
Publications (2)
Publication Number | Publication Date |
---|---|
TW201717595A true TW201717595A (en) | 2017-05-16 |
TWI634771B TWI634771B (en) | 2018-09-01 |
Family
ID=58662919
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
TW105135509A TWI634771B (en) | 2015-11-03 | 2016-11-02 | Wisdom device and method and device for establishing Bluetooth connection between devices |
Country Status (3)
Country | Link |
---|---|
CN (1) | CN107006049A (en) |
TW (1) | TWI634771B (en) |
WO (1) | WO2017076269A1 (en) |
Families Citing this family (29)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110018508A (en) * | 2018-01-10 | 2019-07-16 | 西安中兴新软件有限责任公司 | A kind of localization method and device |
CN108200541B (en) * | 2018-02-11 | 2024-04-16 | 张戈零 | Bluetooth control terminal based on Internet of things |
CN110830976B (en) * | 2018-08-10 | 2022-08-12 | 炬力(珠海)微电子有限公司 | Communication connection establishing method and device |
CN109041034B (en) * | 2018-09-18 | 2021-11-30 | 歌尔科技有限公司 | Bluetooth-based information interaction method, system, Bluetooth device and medium |
CN109785490A (en) * | 2019-01-29 | 2019-05-21 | 上海博泰悦臻网络技术服务有限公司 | Bi-directional verification method and system, intelligent terminal and the T-BOX of bluetooth key |
CN111510893A (en) * | 2019-01-31 | 2020-08-07 | 北京骑胜科技有限公司 | Signal processing method and device, electronic equipment and readable storage medium |
CN109920102B (en) * | 2019-02-02 | 2023-12-12 | 江门市新会区博上科技有限公司 | Bluetooth keyless entry intelligent lock method, device, equipment and storage medium |
CN109831767B (en) * | 2019-03-21 | 2022-06-07 | 科大讯飞股份有限公司 | Bluetooth connection method and system of intelligent wearable device |
CN113132962B (en) * | 2019-04-16 | 2022-12-06 | 华为技术有限公司 | Bluetooth scanning method and electronic equipment |
CN111683359B (en) * | 2019-06-28 | 2023-03-24 | 创新先进技术有限公司 | BLE communication method, device, equipment and storage medium |
CN110784861A (en) * | 2019-11-07 | 2020-02-11 | 江苏英索纳智能科技有限公司 | Bluetooth switch control module |
CN110944312B (en) * | 2019-11-14 | 2023-08-25 | 合肥星空物联信息科技有限公司 | Method for carrying out dual-mode Bluetooth pairing by utilizing audio data and Bluetooth device |
CN110891265B (en) * | 2019-11-26 | 2023-01-03 | Oppo(重庆)智能科技有限公司 | Wireless connection control method and device, mobile terminal and storage medium |
CN110933684B (en) * | 2019-11-28 | 2023-05-12 | 江苏电力信息技术有限公司 | Small world wireless sensor network construction method based on mixed mode |
CN110944313B (en) * | 2019-12-04 | 2023-03-24 | 惠州Tcl移动通信有限公司 | Bluetooth connection method, device, storage medium and terminal |
CN111682990A (en) * | 2020-04-27 | 2020-09-18 | 深圳星普森信息技术有限公司 | Intelligent household system equipment access control method and system based on Bluetooth scattering network networking |
CN113691964B (en) * | 2020-05-19 | 2023-09-05 | 成都鼎桥通信技术有限公司 | Bluetooth device connection method, device and storage medium |
CN113727313A (en) * | 2020-05-25 | 2021-11-30 | 深圳Tcl数字技术有限公司 | Bluetooth scanning control method, mobile terminal and storage medium |
CN111800774A (en) * | 2020-07-03 | 2020-10-20 | 上海风秩科技有限公司 | Control method and device of Bluetooth equipment and storage medium |
CN112367655B (en) * | 2020-11-06 | 2023-01-10 | 炬力(珠海)微电子有限公司 | Communication method and device for TWS equipment team formation and electronic equipment |
CN112996140B (en) * | 2021-02-02 | 2023-04-14 | 亚信科技(成都)有限公司 | Connection method, device, equipment and storage medium |
CN113473433B (en) * | 2021-07-06 | 2023-03-17 | 巨翊科技(上海)有限公司 | Quick-pairing Bluetooth networking communication system and method |
CN113490192B (en) * | 2021-07-26 | 2024-04-02 | 深圳市元征科技股份有限公司 | Bluetooth connection method, device, terminal equipment and readable storage medium |
CN113645607B (en) * | 2021-08-16 | 2024-04-16 | Oppo广东移动通信有限公司 | Bluetooth device discovery method, device, terminal and storage medium |
CN115342592B (en) * | 2022-08-31 | 2024-07-02 | 海信冰箱有限公司 | Refrigerator and binding method of weighing device thereof |
CN115633115B (en) * | 2022-09-08 | 2024-02-02 | 宁波奥克斯电气股份有限公司 | Operation matching method for multiple intelligent air conditioners based on Bluetooth and intelligent air conditioner |
CN115484340B (en) * | 2022-09-13 | 2024-03-08 | 宁波奥克斯电气股份有限公司 | Operation matching method for multiple intelligent air conditioners based on Bluetooth and intelligent air conditioner |
CN115379590B (en) * | 2022-10-27 | 2023-02-14 | 深圳市正浩创新科技股份有限公司 | Bluetooth connection establishing method and device, electronic equipment and computer storage medium |
CN116208955A (en) * | 2022-12-30 | 2023-06-02 | 飞天诚信科技股份有限公司 | Bluetooth connection-based equipment authentication method and device |
Family Cites Families (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100800733B1 (en) * | 2006-02-08 | 2008-02-01 | 삼성전자주식회사 | Bluetooth system and bluetooth bonding process method |
CN101640693A (en) * | 2008-07-31 | 2010-02-03 | 乐金电子(中国)研究开发中心有限公司 | System and method for testifying recording time of mobile phone |
TW201228253A (en) * | 2010-10-29 | 2012-07-01 | Ibm | Apparatus for establishing wireless connection and wireless device |
CN103067055B (en) * | 2012-12-26 | 2016-11-09 | 深圳天珑无线科技有限公司 | A kind of Bluetooth connecting method and mobile terminal |
CN103888177A (en) * | 2014-02-25 | 2014-06-25 | 南京邮电大学 | Method for quickly establishing Bluetooth connection |
CN104702320B (en) * | 2014-04-11 | 2018-02-09 | 上海智向信息科技有限公司 | Near field based on bluetooth pays decision method and system |
CN104320412B (en) * | 2014-11-11 | 2018-04-17 | 福建联迪商用设备有限公司 | A kind of method and device of Bluetooth POS, Bluetooth POS secure connection |
CN104540238B (en) * | 2014-12-26 | 2017-02-22 | 国民技术股份有限公司 | Wireless communication method and device and intelligent card |
CN104980887A (en) * | 2015-07-16 | 2015-10-14 | 北京握奇智能科技有限公司 | Bluetooth connection establishment method and intelligent terminal |
-
2016
- 2016-11-01 CN CN201680003534.7A patent/CN107006049A/en active Pending
- 2016-11-01 WO PCT/CN2016/104195 patent/WO2017076269A1/en active Application Filing
- 2016-11-02 TW TW105135509A patent/TWI634771B/en not_active IP Right Cessation
Also Published As
Publication number | Publication date |
---|---|
WO2017076269A1 (en) | 2017-05-11 |
TWI634771B (en) | 2018-09-01 |
CN107006049A (en) | 2017-08-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
TWI634771B (en) | Wisdom device and method and device for establishing Bluetooth connection between devices | |
CN111669276B (en) | Network verification method, device and system | |
KR102398276B1 (en) | Method and apparatus for downloading and installing a profile | |
CN105119939B (en) | The cut-in method and device, providing method and device and system of wireless network | |
CN113099443B (en) | Equipment authentication method, device, equipment and system | |
US10305684B2 (en) | Secure connection method for network device, related apparatus, and system | |
CN107005927B (en) | Access method, device and system of User Equipment (UE) | |
US20160269176A1 (en) | Key Configuration Method, System, and Apparatus | |
US9654284B2 (en) | Group based bootstrapping in machine type communication | |
JP6727292B2 (en) | Security authentication methods, configuration methods, and related devices | |
CN113055867A (en) | Method and device for auxiliary network distribution of terminal and electronic equipment | |
TW201706900A (en) | Method and device for authentication using dynamic passwords | |
KR20160078426A (en) | Method and apparatus to identity verification using asymmetric keys in wireless direct communication network | |
CN105792194B (en) | Authentication method, authentication device, the network equipment, the Verification System of base station legitimacy | |
CN105634737B (en) | Data transmission method, terminal and system | |
CN109890029B (en) | Automatic network distribution method of intelligent wireless equipment | |
US20160227412A1 (en) | Wireless Terminal Configuration Method, Apparatus, and Wireless Terminal | |
WO2015144041A1 (en) | Network authentication method and device | |
CN110784865A (en) | Network distribution method and terminal of Internet of things equipment, Internet of things equipment and network distribution system | |
CN108306793B (en) | Intelligent device, intelligent home gateway, and method and system for establishing connection | |
CN109361681B (en) | Method, device and equipment for authenticating national secret certificate | |
WO2016101774A1 (en) | Wireless communication method and apparatus and application system and device thereof | |
WO2017091987A1 (en) | Method and apparatus for secure interaction between terminals | |
WO2018040524A1 (en) | Method and device for sharing hotspots | |
CN111770588A (en) | Method and system for quickly establishing wireless connection with wireless router |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
MM4A | Annulment or lapse of patent due to non-payment of fees |