TWI683590B - Control method and control system for internet of things device - Google Patents

Control method and control system for internet of things device Download PDF

Info

Publication number
TWI683590B
TWI683590B TW107142538A TW107142538A TWI683590B TW I683590 B TWI683590 B TW I683590B TW 107142538 A TW107142538 A TW 107142538A TW 107142538 A TW107142538 A TW 107142538A TW I683590 B TWI683590 B TW I683590B
Authority
TW
Taiwan
Prior art keywords
identification number
cross
iot device
blockchain
chain server
Prior art date
Application number
TW107142538A
Other languages
Chinese (zh)
Other versions
TW202021414A (en
Inventor
李耕維
王聖方
何丞堯
Original Assignee
財團法人資訊工業策進會
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 財團法人資訊工業策進會 filed Critical 財團法人資訊工業策進會
Priority to TW107142538A priority Critical patent/TWI683590B/en
Priority to CN201811486652.5A priority patent/CN111245883A/en
Application granted granted Critical
Publication of TWI683590B publication Critical patent/TWI683590B/en
Publication of TW202021414A publication Critical patent/TW202021414A/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C9/00Individual registration on entry or exit
    • G07C9/00174Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
    • G07C9/00571Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys operated by interacting with a central unit
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • H04L67/125Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks involving control of end-device applications over a network

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)
  • Telephonic Communication Services (AREA)

Abstract

A control method for internet of things (IoT) device is disclosed herein. Each IoT device has a corresponding device identification number. The method includes: receiving and storing the device identification number corresponding to each IoT device via a cross-chain server, and registering the device identification number corresponding to each IoT device on a first blockchain; filling the device identification number into a smart contract corresponding to each IoT device through the cross-chain server; and deploying the smart contract to a second blockchain to generate a contract identification number corresponding to the smart contract; wherein, when the cross-chain server is configured to query the smart contract according to the contract identification number, the cross- chain server is configured to generate a control instruction corresponding to the device identification number of the smart contract, and transmit the IoT device corresponding to the device identification number via the first blockchain.

Description

物聯網裝置之控制方法及控制系統 Control method and control system of Internet of Things device

本案是有關於一種控制方法及控制系統,且特別是有關於一種用於物聯網裝置之控制方法及控制系統。 This case relates to a control method and control system, and particularly to a control method and control system for an Internet of Things device.

隨著物聯網技術(Internet of Things,IoT)的蓬勃發展,讓所有能行使獨立功能的物體如車輛、機器、家用電器等,連接上網路,能夠進行資訊數據分析,統整物與物的數位資訊。然而,管理物聯網裝置的管理正面臨集中式管理的管理僵化問題與安全隱私爭議,以及現有非集中式管理機制因區塊鏈交易時間過長,無法即時與裝置互動等問題。因此,如何與物聯網裝置互動並降低物聯網裝置的開發成本,是本領域待解決的問題。 With the vigorous development of Internet of Things (IoT), all objects that can perform independent functions such as vehicles, machines, household appliances, etc. can be connected to the Internet to analyze information and data, and integrate the digital of things and things. News. However, the management of IoT device management is facing the problems of centralized management, management rigidity and security privacy disputes, and the existing non-centralized management mechanism because the blockchain transaction time is too long to interact with the device in real time. Therefore, how to interact with the IoT device and reduce the development cost of the IoT device is a problem to be solved in the art.

本發明之主要目的係在提供一種物聯網裝置之控制方法以及物聯網裝置之控制系統,其主要係改進以往集 中式管理的管理僵化問題與安全隱私爭議,以及現有非集中式管理機制如區塊鏈因交易時間過長無法進行即時交易等問題。利用物聯網裝置合約管理服務,保留集中式管理彈性部署、數據安全可靠的特性,達到物聯網裝置即時互動,並降低物聯網裝置開發與部署成本的功效。 The main object of the present invention is to provide a control method of an Internet of Things device and a control system of the Internet of Things device, which mainly improve the prior art The rigid management problem and security privacy disputes of Chinese management, as well as the existing non-centralized management mechanism, such as the blockchain is unable to conduct real-time transactions due to the long transaction time. The use of IoT device contract management services retains the features of centralized management, flexible deployment, and data security and reliability to achieve real-time interaction of IoT devices and reduce the cost of IoT device development and deployment costs.

為達成上述目的,本案之第一態樣是在提供一種物聯網裝置之控制方法,應用於複數個物聯網裝置,每一物聯網裝置具有對應的裝置識別號,此方法包含以下步驟:透過跨鏈伺服器接收並儲存每一物聯網裝置對應的裝置識別號,每一物聯網裝置並於第一區塊鏈上註冊其對應的該裝置識別號;透過跨鏈伺服器將裝置識別號填入對應的智能合約;以及將智能合約部署至第二區塊鏈以產生對應智能合約的合約識別號並儲存對應的裝置識別號;其中,跨鏈伺服器根據合約識別號查詢智能合約,產生對應智能合約之裝置識別號的控制指令並傳送到第一區塊鏈,以供對應裝置識別號的物聯網裝置連接至該第一區塊鏈取得。 In order to achieve the above purpose, the first aspect of this case is to provide a control method of an IoT device, which is applied to a plurality of IoT devices, each IoT device has a corresponding device identification number. This method includes the following steps: The chain server receives and stores the device identification number corresponding to each IoT device, and each IoT device registers its corresponding device identification number on the first blockchain; fill in the device identification number through the cross-chain server The corresponding smart contract; and deploy the smart contract to the second blockchain to generate the contract identification number of the corresponding smart contract and store the corresponding device identification number; wherein, the cross-chain server queries the smart contract according to the contract identification number to generate the corresponding intelligence The control command of the device identification number of the contract is transmitted to the first blockchain for the IoT device corresponding to the device identification number to connect to the first blockchain to obtain.

本案之第二態樣是在提供一種物聯網裝置之控制系統,應用於區塊鏈網路,區塊鏈網路包含第一區塊鏈以及第二區塊鏈,物聯網裝置之控制系統包含:複數個物聯網裝置以及跨鏈伺服器。複數個物聯網裝置,每一物聯網裝置具有對應的裝置識別號。跨鏈伺服器,與該些物聯網裝置及該區塊鏈網路通訊連接,該跨鏈伺服器更用以接收並儲存每一物聯網裝置對應的裝置識別號,每一物聯網裝置並於第一區塊鏈上註冊其對應的裝置識別號,並將裝置識別號填入對 應的智能合約,以將智能合約部署至第二區塊鏈以產生對應智能合約的合約識別號並儲存對應的裝置識別號,其中,跨鏈伺服器根據合約識別號查詢智能合約,產生對應智能合約之裝置識別號的控制指令並傳送到第一區塊鏈,以供對應裝置識別號的物聯網裝置連接至該第一區塊鏈取得。 The second aspect of the case is to provide a control system for an Internet of Things device, which is applied to a blockchain network. The blockchain network includes a first blockchain and a second blockchain. The control system of the Internet of Things device includes : Multiple IoT devices and cross-chain servers. A plurality of IoT devices, each IoT device has a corresponding device identification number. A cross-chain server is in communication with the IoT devices and the blockchain network. The cross-chain server is further used to receive and store the device identification number corresponding to each IoT device. Register its corresponding device identification number on the first blockchain, and fill in the device identification number Smart contract to deploy the smart contract to the second blockchain to generate the contract identification number corresponding to the smart contract and store the corresponding device identification number, where the cross-chain server queries the smart contract according to the contract identification number to generate the corresponding smart The control command of the device identification number of the contract is transmitted to the first blockchain for the IoT device corresponding to the device identification number to connect to the first blockchain to obtain.

100‧‧‧物聯網裝置之控制系統 100‧‧‧Control system of Internet of Things device

110‧‧‧區塊鏈網路 110‧‧‧Blockchain network

110a‧‧‧第一區塊鏈 110a‧‧‧The first blockchain

110b‧‧‧第二區塊鏈 110b‧‧‧second blockchain

120‧‧‧跨鏈伺服器 120‧‧‧Cross-chain server

130、130-1~130-n‧‧‧物聯網裝置 130、130-1~130-n‧‧‧Internet of Things device

140‧‧‧電子裝置 140‧‧‧Electronic device

150‧‧‧商家伺服器 150‧‧‧merchant server

131‧‧‧處理器 131‧‧‧ processor

132‧‧‧通訊模組 132‧‧‧Communication module

133‧‧‧電子鎖頭構件 133‧‧‧Electronic lock components

300、400‧‧‧物聯網裝置之控制方法 300, 400 ‧‧‧ Internet of Things device control method

S310~S340、S410~S430、S411~S416、S421~S429、S431~S437‧‧‧步驟 S310~S340, S410~S430, S411~S416, S421~S429, S431~S437

為讓本發明之上述和其他目的、特徵、優點與實施例能更明顯易懂,所附圖式之說明如下:第1圖係根據本案之一些實施例所繪示之物聯網裝置之控制系統的示意圖;第2圖係根據本案之一些實施例所繪示之物聯網裝置的示意圖;第3圖係根據本案之一些實施例所繪示之物聯網裝置之控制方法的流程圖;第4圖係根據本案之一些實施例所繪示之物聯網裝置之控制方法的流程圖;第5圖係根據本案之一些實施例所繪示之步驟S410的流程圖;第6圖係根據本案之一些實施例所繪示之步驟S420的流程圖;以及第7圖係根據本案之一些實施例所繪示之步驟S430的流程圖。 In order to make the above and other objects, features, advantages and embodiments of the present invention more obvious and understandable, the drawings are described as follows: FIG. 1 is a control system of an Internet of Things device according to some embodiments of the case Figure 2 is a schematic diagram of an IoT device according to some embodiments of the case; Figure 3 is a flowchart of a control method of an IoT device according to some embodiments of the case; Figure 4 It is a flowchart of the control method of the Internet of Things device according to some embodiments of this case; FIG. 5 is a flowchart of step S410 according to some embodiments of this case; FIG. 6 is some implementations according to this case The flowchart of step S420 shown in the example; and FIG. 7 is a flowchart of step S430 shown according to some embodiments of the present case.

以下揭示提供許多不同實施例或例證用以實施本發明的不同特徵。特殊例證中的元件及配置在以下討論中被用來簡化本揭示。所討論的任何例證只用來作解說的用途,並不會以任何方式限制本發明或其例證之範圍和意義。此外,本揭示在不同例證中可能重複引用數字符號且/或字母,這些重複皆為了簡化及闡述,其本身並未指定以下討論中不同實施例且/或配置之間的關係。 The following disclosure provides many different embodiments or illustrations to implement different features of the present invention. The elements and configurations in the specific illustrations are used to simplify this disclosure in the following discussion. Any examples discussed are for illustrative purposes only, and do not limit the scope and meaning of the invention or its examples in any way. In addition, the present disclosure may repeatedly refer to numerical symbols and/or letters in different illustrations. These repetitions are for simplicity and explanation, and do not specify the relationship between different embodiments and/or configurations in the following discussion.

在全篇說明書與申請專利範圍所使用之用詞(terms),除有特別註明外,通常具有每個用詞使用在此領域中、在此揭露之內容中與特殊內容中的平常意義。某些用以描述本揭露之用詞將於下或在此說明書的別處討論,以提供本領域技術人員在有關本揭露之描述上額外的引導。 The terms used throughout the specification and the scope of patent application, unless otherwise specified, usually have the ordinary meaning that each term is used in this field, in the content disclosed here, and in the special content. Certain terms used to describe this disclosure will be discussed below or elsewhere in this specification to provide additional guidance to those skilled in the art in the description of this disclosure.

關於本文中所使用之『耦接』或『連接』,均可指二或多個元件相互直接作實體或電性接觸,或是相互間接作實體或電性接觸,而『耦接』或『連接』還可指二或多個元件相互操作或動作。 With regard to "coupling" or "connection" used in this article, it can mean that two or more components directly make physical or electrical contact with each other, or indirectly make physical or electrical contact with each other, while "coupled" or "connected" "Connected" may also refer to the interoperation or movement of two or more elements.

在本文中,使用第一、第二與第三等等之詞彙,是用於描述各種元件、組件、區域、層與/或區塊是可以被理解的。但是這些元件、組件、區域、層與/或區塊不應該被這些術語所限制。這些詞彙只限於用來辨別單一元件、組件、區域、層與/或區塊。因此,在下文中的一第一元件、組件、區域、層與/或區塊也可被稱為第二元件、組件、區域、層與/或區塊,而不脫離本發明的本意。如本文所用, 詞彙『與/或』包含了列出的關聯項目中的一個或多個的任何組合。本案文件中提到的「及/或」是指表列元件的任一者、全部或至少一者的任意組合。 In this document, the terms first, second, third, etc. are used to describe various elements, components, regions, layers, and/or blocks that can be understood. But these elements, components, regions, layers and/or blocks should not be limited by these terms. These words are only used to identify a single element, component, region, layer and/or block. Therefore, in the following, a first element, component, region, layer and/or block may also be referred to as a second element, component, region, layer and/or block without departing from the original intention of the present invention. As used in this article, The term "and/or" includes any combination of one or more of the associated items listed. The "and/or" mentioned in the document of this case refers to any, all or at least one combination of the listed elements.

請參閱第1圖。第1圖係根據本案之一些實施例所繪示之物聯網裝置之控制系統100的示意圖。如第1圖所繪示,物聯網裝置之控制系統100應用於區塊鏈網路110,區塊鏈網路110包含第一區塊鏈110a以及第二區塊鏈110b。物聯網裝置之控制系統100包含跨鏈伺服器120、複數個物聯網裝置130-1~130-n、電子裝置140以及商家伺服器150。每一物聯網裝置130-1~130-n與區塊鏈網路110以及跨鏈伺服器120通訊連接,跨鏈伺服器120與區塊鏈網路110、電子裝置140以及商家伺服器150通訊連接。 Please refer to Figure 1. FIG. 1 is a schematic diagram of a control system 100 of an Internet of Things device according to some embodiments of the present case. As shown in FIG. 1, the control system 100 of the Internet of Things device is applied to the blockchain network 110, and the blockchain network 110 includes a first blockchain 110a and a second blockchain 110b. The control system 100 of the IoT device includes a cross-chain server 120, a plurality of IoT devices 130-1~130-n, an electronic device 140, and a merchant server 150. Each IoT device 130-1~130-n communicates with the blockchain network 110 and the cross-chain server 120, and the cross-chain server 120 communicates with the blockchain network 110, the electronic device 140, and the merchant server 150 connection.

請參閱第2圖。第2圖係根據本案之一些實施例所繪示之物聯網裝置130-1~130-n的示意圖。每一物聯網裝置130-1~130-n具有對應的裝置識別號,每一物聯網裝置130-1~130-n包含處理器131、通訊模組132以及電子鎖頭構件133。處理器131與通訊模組132以及電子鎖頭構件133電性連接。處理器131用以產生裝置識別號,通訊模組132用以與跨鏈伺服器120以及第一區塊鏈110a通訊連接,以取得控制指令,處理器131用以根據控制指令控制電子鎖頭構件134的上鎖及解鎖。 Please refer to figure 2. FIG. 2 is a schematic diagram of the Internet of Things devices 130-1~130-n according to some embodiments of the present case. Each IoT device 130-1~130-n has a corresponding device identification number. Each IoT device 130-1~130-n includes a processor 131, a communication module 132, and an electronic lock member 133. The processor 131 is electrically connected to the communication module 132 and the electronic lock member 133. The processor 131 is used to generate a device identification number, the communication module 132 is used to communicate with the cross-chain server 120 and the first blockchain 110a to obtain control commands, and the processor 131 is used to control the electronic lock component according to the control commands 134 lock and unlock.

於本揭露各實施例中,在本案揭露說明書和圖式中使用的元件編號和裝置編號中的小寫英文索引1~n,只是為了方便指稱個別的元件和裝置,並非有意將前述元件和 裝置的數量侷限在特定數目。在本案說明書和圖式中,若使用某一元件編號或裝置編號時沒有指明該元件編號或裝置編號的索引,則代表該元件編號或裝置編號是指稱所屬元件群組或裝置群組中不特定的任一元件或裝置。例如,元件編號130-1指稱的對象是物聯網裝置130-1,而元件編號130指稱的對象則是物聯網裝置130-1~130-n中的任一物聯網裝置。又例如,裝置編號130-1指稱的對象是物聯網裝置130-1,而裝置編號130指稱的對象則是物聯網裝置130-1~130-n中的任一物聯網裝置。 In the embodiments of the present disclosure, the lower case English index 1~n in the component numbers and device numbers used in the disclosure specification and drawings in this case is just for convenience to refer to individual components and devices. The number of devices is limited to a certain number. In the specification and drawings of this case, if an element number or device number is used without indicating the index of the element number or device number, it means that the element number or device number refers to the component group or device group to which it belongs Any element or device. For example, the component number 130-1 refers to the Internet of Things device 130-1, and the component number 130 refers to the Internet of Things device 130-1~130-n. For another example, the object referred to by the device number 130-1 is the Internet of Things device 130-1, and the object referred to by the device number 130 is any of the Internet of Things devices 130-1 to 130-n.

於本揭露各實施例中,電子裝置140可以實施為智慧型手機、穿戴式裝置、專用行動裝置或健身機台的控制器。物聯網裝置130可以實施為智能櫃或是其他可連網的裝置,處理器131可以實施為積體電路如微控制單元(microcontroller)、微處理器(microprocessor)、數位訊號處理器(digital signal processor)、特殊應用積體電路(application specific integrated circuit,ASIC)、邏輯電路或其他類似元件或上述元件的組合。商家伺服器150可以實施為提供物聯網裝置130的供應商伺服器。 In the embodiments of the present disclosure, the electronic device 140 may be implemented as a controller of a smart phone, a wearable device, a dedicated mobile device, or a fitness machine. The Internet of Things device 130 can be implemented as a smart cabinet or other network-connectable device, and the processor 131 can be implemented as an integrated circuit such as a microcontroller, a microprocessor, and a digital signal processor ), application specific integrated circuit (ASIC), logic circuit or other similar components or a combination of the above components. The merchant server 150 may be implemented as a vendor server that provides the Internet of Things device 130.

請參閱第3圖,第3圖係根據本案之一些實施例所繪示之物聯網裝置之控制方法300的流程圖。於一實施例中,第3圖所示之物聯網裝置之控制方法300可以應用於第1圖的物聯網裝置之控制系統100以及第2圖的每一物聯網裝置130中,物聯網裝置之控制方法300首先執行步驟S310透過跨鏈伺服器120接收並儲存每一物聯網裝置130對應的裝 置識別號,每一物聯網裝置並於第一區塊鏈110a上註冊其對應的裝置識別號。於一實施例中,第一區塊鏈110a可以實施為IOTA區塊鏈網路,第二區塊鏈110b可以實施為以太坊(Ethereum)區塊鏈網路。於一實施例中,物聯網裝置130的處理器131在掛載物聯網的部屬軟體後即可設定對應每一物聯網裝置130的裝置識別號,接著在跨鏈伺服器120以及第一區塊鏈110a(IOTA區塊鏈網路)上註冊裝置識別號,如此一來,物聯網裝置130即可成為可與IOTA區塊鏈網路連接的裝置。接著,跨鏈伺服器120會接收並儲存每一物聯網裝置130對應的裝置識別號,並且物聯網裝置130會在第一區塊鏈110a上註冊對應的裝置識別號。 Please refer to FIG. 3, which is a flowchart of a method 300 for controlling an Internet of Things device according to some embodiments of the present case. In an embodiment, the control method 300 of the IoT device shown in FIG. 3 can be applied to the control system 100 of the IoT device of FIG. 1 and each IoT device 130 of FIG. The control method 300 first executes step S310 to receive and store the device corresponding to each IoT device 130 through the cross-chain server 120 Set an identification number, and each IoT device registers its corresponding device identification number on the first blockchain 110a. In one embodiment, the first blockchain 110a may be implemented as an IOTA blockchain network, and the second blockchain 110b may be implemented as an Ethereum blockchain network. In an embodiment, the processor 131 of the IoT device 130 can set the device identification number corresponding to each IoT device 130 after mounting the IoT software, and then the cross-chain server 120 and the first block The device identification number is registered on the chain 110a (IOTA blockchain network), so that the IoT device 130 can become a device that can be connected to the IOTA blockchain network. Then, the cross-chain server 120 receives and stores the device identification number corresponding to each IoT device 130, and the IoT device 130 registers the corresponding device identification number on the first blockchain 110a.

承上述,第一區塊鏈110a(IOTA區塊鏈網路)可以用來控制物聯網裝置130的狀態,第二區塊鏈110b(以太坊區塊鏈網路)則是用來記錄物聯網裝置的狀態以及與電子裝置140之間的交易。 According to the above, the first blockchain 110a (IOTA blockchain network) can be used to control the state of the IoT device 130, and the second blockchain 110b (Ethereum blockchain network) is used to record the IoT The status of the device and transactions with the electronic device 140.

接著,物聯網裝置之控制方法300執行步驟S320,透過跨鏈伺服器120將裝置識別號填入對應的智能合約,以及執行步驟S330,將智能合約部署至第二區塊鏈110b以產生對應智能合約的合約識別號並儲存對應的裝置識別號。接續上方實施例,物聯網裝置130連結到第一區塊鏈110a並註冊裝置識別號後,會將裝置識別號傳送至跨鏈伺服器120,跨鏈伺服器120再將對應每一物聯網裝置130的裝置識別號填入智能合約中,智能合約會儲存每一物聯網裝置130的裝置識別號,再將智能合約部署至第二區塊鏈110b 以產生合約識別號,合約識別號在此即為呼叫此智能合約的合約地址(Contract Address)。如此一來,每一物聯網裝置130都可以對應到一個智能合約以及智能合約對應的合約識別號。 Next, the control method 300 of the IoT device executes step S320, fills the device identification number into the corresponding smart contract through the cross-chain server 120, and executes step S330, deploying the smart contract to the second blockchain 110b to generate the corresponding smart The contract identification number of the contract and store the corresponding device identification number. Following the above embodiment, after the IoT device 130 is connected to the first blockchain 110a and the device identification number is registered, the device identification number is transmitted to the cross-chain server 120, and the cross-chain server 120 will correspond to each IoT device The device identification number of 130 is filled in the smart contract, and the smart contract stores the device identification number of each IoT device 130, and then deploys the smart contract to the second blockchain 110b To generate a contract identification number, the contract identification number is the contract address (Contract Address) for calling this smart contract. In this way, each IoT device 130 can correspond to a smart contract and the contract identification number corresponding to the smart contract.

接著,物聯網裝置之控制方法300執行步驟S340,跨鏈伺服器120傳送每一物聯網裝置的合約識別號至商家伺服器150。接續上方實施例,跨鏈伺服器120接收到合約識別號後表示物聯網裝置130已部署到第二區塊鏈110b上,因此第二區塊鏈110b可以透過跨鏈伺服器120追蹤物聯網裝置130,接著,將每一物聯網裝置130對應的合約識別號同步至商家伺服器150,商家伺服器150會記錄每一物聯網裝置130對應的狀態。執行完步驟S310~S340表示物聯網裝置130已經在第一區塊鏈110a以及第二區塊鏈110b註冊完畢,表示“上鏈”成功。 Next, the control method 300 of the IoT device executes step S340, and the cross-chain server 120 transmits the contract identification number of each IoT device to the merchant server 150. Following the above embodiment, after receiving the contract identification number, the cross-chain server 120 indicates that the IoT device 130 has been deployed on the second blockchain 110b, so the second blockchain 110b can track the IoT device through the cross-chain server 120 130. Next, the contract identification number corresponding to each IoT device 130 is synchronized to the merchant server 150, and the merchant server 150 records the status corresponding to each IoT device 130. After performing steps S310 to S340, it indicates that the Internet of Things device 130 has been registered in the first blockchain 110a and the second blockchain 110b, indicating that the “uplink” is successful.

請參閱第4圖,第4圖係根據本案之一些實施例所繪示之物聯網裝置之控制方法400的流程圖,以及第5圖係根據本案之一些實施例所繪示之步驟S410的流程圖。在執行完步驟S310~S340之後,可以接著執行第4圖所示的步驟,物聯網裝置之控制方法400執行步驟S410,利用電子裝置140透過跨鏈伺服器120提出預約請求。於一實施例中,步驟S410係用以透過電子裝置140傳送預約物聯網裝置130的請求,舉例而言使用者可以預約智能櫃A,步驟S410更包含步驟S411~S416。 Please refer to FIG. 4, FIG. 4 is a flowchart of the control method 400 of the Internet of Things device according to some embodiments of the case, and FIG. 5 is a flowchart of step S410 according to some embodiments of the case Figure. After performing steps S310-S340, the steps shown in FIG. 4 may be performed next. The control method 400 of the IoT device executes step S410, and the electronic device 140 makes a reservation request through the cross-chain server 120. In one embodiment, step S410 is used to transmit a request to reserve the Internet of Things device 130 through the electronic device 140. For example, the user can reserve the smart cabinet A. Step S410 further includes steps S411 to S416.

承上述,物聯網裝置之控制方法400執行步驟 S411,藉由電子裝置140傳送對應的身分識別號以及查詢請求至跨鏈伺服器120。於一實施例中,使用者可以透過電子裝置140預約物聯網裝置130,利用電子裝置140發送查詢請求至跨鏈伺服器120,查詢請求係指查詢所有可使用的物聯網裝置130,在本揭露的實施例中即為查詢所有可使用的智能櫃,身分識別號為電子裝置140的識別代碼。 According to the above, the control method 400 of the IoT device performs the steps S411, the electronic device 140 transmits the corresponding identification number and query request to the cross-chain server 120. In an embodiment, the user can reserve the IoT device 130 through the electronic device 140, and use the electronic device 140 to send a query request to the cross-chain server 120. The query request refers to querying all available IoT devices 130, which is disclosed in this disclosure In the embodiment, the query is for all available smart cabinets, and the identification number is the identification code of the electronic device 140.

承上述,物聯網裝置之控制方法400執行步驟S412,藉由跨鏈伺服器120依據裝置識別碼向第二區塊鏈110b提出查詢請求,以查詢每一物聯網裝置130對應的智能合約的使用資訊;步驟S413,藉由跨鏈伺服器120傳送每一物聯網裝置130對應的使用資訊至電子裝置140。於一實施例中,跨鏈伺服器120會根據電子裝置140的裝置識別碼向第二區塊鏈110b查詢智能櫃的使用資訊,使用資訊包含合約識別號、物聯網裝置130的位置、物聯網裝置130對應的狀態等資訊。跨鏈伺服器120在接收到智能櫃的使用資訊後,會將每一智能櫃的使用資訊傳送至電子裝置140。 According to the above, the control method 400 of the IoT device executes step S412, and the cross-chain server 120 makes a query request to the second blockchain 110b according to the device identification code to query the use of the smart contract corresponding to each IoT device 130 Information; Step S413, the cross-chain server 120 is used to send the usage information corresponding to each IoT device 130 to the electronic device 140. In one embodiment, the cross-chain server 120 queries the second blockchain 110b for usage information of the smart cabinet based on the device identification code of the electronic device 140, the usage information includes the contract identification number, the location of the Internet of Things device 130, the Internet of Things Information such as the status corresponding to the device 130. After receiving the usage information of the smart cabinet, the cross-chain server 120 transmits the usage information of each smart cabinet to the electronic device 140.

接著,物聯網裝置之控制方法400執行步驟S414,選擇物聯網裝置130的其中之一,並傳送預約資訊至跨鏈伺服器120。於一實施例中,使用者可以透過電子裝置140選擇智能櫃A,智能櫃A被選擇後由電子裝置140傳送預約資訊至跨鏈伺服器120,其中預約資訊包含身分識別號、合約識別號、被選擇的物聯網裝置130對應的裝置識別號(在此即為智能櫃A對應的裝置識別號)。身分識別號對應於傳送預約資訊的電子裝置140,合約識別號以及裝置識別 號都是對應於被選擇的智能櫃A。 Next, the control method 400 of the IoT device executes step S414, selects one of the IoT devices 130, and transmits reservation information to the cross-chain server 120. In one embodiment, the user can select the smart cabinet A through the electronic device 140. After the smart cabinet A is selected, the electronic device 140 transmits the reservation information to the cross-chain server 120, where the reservation information includes an identity identification number, a contract identification number, The device identification number corresponding to the selected IoT device 130 (here, the device identification number corresponding to the smart cabinet A). The identification number corresponds to the electronic device 140 transmitting the reservation information, the contract identification number and the device identification The numbers correspond to the selected smart cabinet A.

接著,物聯網裝置之控制方法400執行步驟S415,藉由跨鏈伺服器120傳送預約資訊至第二區塊鏈110b,並更新被選擇的物聯網裝置130對應的狀態;以及步驟S416,更新商家伺服器150中被選擇的物聯網裝置130對應的狀態。於一實施例中,透過跨鏈伺服器120傳送預約資訊至第二區塊鏈110b以將智能櫃A的狀態更新為“使用中”,接著再更新商家伺服器150中智能櫃A的狀態。 Next, the control method 400 of the IoT device executes step S415, transmits the reservation information to the second blockchain 110b via the cross-chain server 120, and updates the status corresponding to the selected IoT device 130; and step S416, updates the merchant The state corresponding to the selected Internet of Things device 130 in the server 150. In one embodiment, the reservation information is sent to the second blockchain 110b through the cross-chain server 120 to update the state of the smart cabinet A to "in use", and then the state of the smart cabinet A in the merchant server 150 is updated.

於一實施例中,當跨鏈伺服器120根據合約識別號查詢智能合約時,跨鏈伺服器120產生對應智能合約之裝置識別號的控制指令並傳送到第一區塊鏈110a,由對應裝置識別號的物聯網裝置130連接至該第一區塊鏈取得。舉例而言,如果使用者透過電子裝置140要求要解鎖或上鎖智能櫃A,可以根據合約識別號透過跨鏈伺服器120查詢智能櫃A對應的智能合約,接著跨鏈伺服器120會產生對應的控制指令,送到第一區塊鏈110a,控制智能櫃A可連接至該第一區塊鏈110a取得控制指令。 In one embodiment, when the cross-chain server 120 queries the smart contract according to the contract identification number, the cross-chain server 120 generates a control command corresponding to the device identification number of the smart contract and transmits it to the first blockchain 110a, which is sent by the corresponding device The IoT device 130 with the identification number is connected to the first blockchain to obtain it. For example, if the user requests to unlock or lock the smart cabinet A through the electronic device 140, the user can query the smart contract corresponding to the smart cabinet A through the cross-chain server 120 according to the contract identification number, and then the cross-chain server 120 generates a corresponding Control commands are sent to the first blockchain 110a, and the control smart cabinet A can be connected to the first blockchain 110a to obtain control commands.

承上述,物聯網裝置之控制方法400執行步驟S420,利用電子裝置140透過跨鏈伺服器120以執行智能合約並控制對應智能合約的物聯網裝置130。於一實施例中,步驟S420係用以利用電子裝置140解鎖智能櫃A,步驟S420更包含步驟S421~S429。請進一步參考第6圖,第6圖係根據本案之一些實施例所繪示之步驟S420的流程圖,如第6圖所示,物聯網裝置之控制方法400接著執行步驟 S421,利用電子裝置140讀取物聯網裝置130的其中之一對應的條碼,並取得被選擇的物聯網裝置130對應的合約識別號。於一實施例中,使用者在步驟S411中預約了智能櫃A,此時使用者可以透過電子裝置140掃描智能櫃A櫃體上的條碼或二維條碼,以取得智能櫃A的合約識別號。 According to the above, the control method 400 of the IoT device executes step S420, and the electronic device 140 executes the smart contract through the cross-chain server 120 and controls the IoT device 130 corresponding to the smart contract. In one embodiment, step S420 is used to unlock the smart cabinet A using the electronic device 140. Step S420 further includes steps S421-S429. Please further refer to FIG. 6, which is a flowchart of step S420 according to some embodiments of the present case. As shown in FIG. 6, the control method 400 of the IoT device then executes the steps S421: Use the electronic device 140 to read a bar code corresponding to one of the Internet of Things devices 130, and obtain a contract identification number corresponding to the selected Internet of Things devices 130. In one embodiment, the user has reserved the smart cabinet A in step S411. At this time, the user can scan the barcode or the two-dimensional barcode on the cabinet of the smart cabinet A through the electronic device 140 to obtain the contract identification number of the smart cabinet A .

接著,物聯網裝置之控制方法400接著執行步驟S422,將合約識別號以及操作資訊傳送至跨鏈伺服器120。於一實施例中,操作資訊包含電子裝置140對應的身分識別號以及解鎖請求等訊息。 Next, the control method 400 of the IoT device then executes step S422 to send the contract identification number and operation information to the cross-chain server 120. In one embodiment, the operation information includes information such as the identification number corresponding to the electronic device 140 and the unlock request.

接著,物聯網裝置之控制方法400接著執行步驟S423,根據合約識別號於第二區塊鏈110b上查詢被選擇的物聯網裝置130對應的智能合約;以及步驟S424,第二區塊鏈110b回傳智能合約的內容資訊至跨鏈伺服器120。接續上方實施例,跨鏈伺服器120接收到合約識別號以及解鎖資訊後會向第二區塊鏈110b提出請求,以取得智能櫃A對應的智能合約中的內容資訊,內容資訊包含被選擇的物聯網裝置130對應的裝置識別號以及被選擇的物聯網裝置130對應的狀態。舉例而言,跨鏈伺服器120可以取得智能櫃A對應的裝置識別號(第一區塊鏈110a使用的識別號),智能櫃A當前的使用狀態,在步驟S410執行完畢後智能櫃A的狀態即更新為“使用中”,內容資訊還可以包含電子裝置140的身分識別號。 Next, the control method 400 of the IoT device then executes step S423 to query the smart contract corresponding to the selected IoT device 130 on the second blockchain 110b according to the contract identification number; and step S424, the second blockchain 110b returns The content information of the smart contract is transmitted to the cross-chain server 120. Following the above embodiment, after receiving the contract identification number and unlocking information, the cross-chain server 120 requests the second blockchain 110b to obtain the content information in the smart contract corresponding to the smart cabinet A. The content information includes the selected The device identification number corresponding to the Internet of Things device 130 and the state corresponding to the selected Internet of Things device 130. For example, the cross-chain server 120 can obtain the device identification number corresponding to the smart cabinet A (the identification number used by the first blockchain 110a), the current use status of the smart cabinet A, and the smart cabinet A’s The status is updated to "in use", and the content information may further include the identification number of the electronic device 140.

接著,物聯網裝置之控制方法400接著執行步驟S425,跨鏈伺服器120根據身分識別號以及被選擇的物 聯網裝置130對應的狀態驗證操作資訊,並傳送控制請求至第一區塊鏈110a。於一實施例中,跨鏈伺服器120在根據智能櫃A當前的使用狀態以及電子裝置140的身分識別號與操作資訊比對後,將控制請求傳送至第一區塊鏈110a,等待智能櫃A偵測到控制請求以解鎖智能櫃A。 Next, the control method 400 of the IoT device then executes step S425, the cross-chain server 120 according to the identity identification number and the selected object The state corresponding to the networked device 130 verifies the operation information and sends a control request to the first blockchain 110a. In an embodiment, the cross-chain server 120 transmits the control request to the first blockchain 110a after waiting for the smart cabinet A according to the current usage status of the smart cabinet A and the identification number of the electronic device 140 and the operation information, waiting for the smart cabinet A detects a control request to unlock smart cabinet A.

接著,物聯網裝置之控制方法400接著執行步驟S426,選擇的物聯網裝置130可連接到第一區塊鏈110a取得控制指令,以及步驟S427,被選擇的物聯網裝置130傳送操作紀錄至第一區塊鏈110a。於一實施例中,第一區塊鏈110a接收到跨鏈伺服器120傳送的控制指令後於以儲存,智能櫃A的處理器131可連接到第一區塊鏈110取得控制指令,處理器131會根據控制指令控制電子鎖頭構件134解鎖,接著,處理器131會回傳操作紀錄至第一區塊鏈110a。 Next, the control method 400 of the IoT device then executes step S426, the selected IoT device 130 can be connected to the first blockchain 110a to obtain the control command, and step S427, the selected IoT device 130 transmits the operation record to the first Blockchain 110a. In one embodiment, the first blockchain 110a receives the control command sent by the cross-chain server 120 and stores it. The processor 131 of the smart cabinet A can be connected to the first blockchain 110 to obtain the control command. 131 will control the electronic lock member 134 to unlock according to the control command, and then the processor 131 will return the operation record to the first blockchain 110a.

接著,物聯網裝置之控制方法400接著執行步驟S428,跨鏈伺服器120偵測到操作紀錄後,更新被選擇的物聯網裝置130對應的智能合約;以及步驟S429,跨鏈伺服器120傳送被選擇的物聯網裝置130對應的狀態至電子裝置140。接續上方實施例,當第一區塊鏈110a接收到操作紀錄後,跨鏈伺服器120會偵測到操作紀錄並更新智能櫃A於第二區塊鏈110b上的智能合約,並再回傳智能櫃A對應的狀態至使用者的電子裝置140以及商家伺服器150。舉例而言,如果智能櫃A解鎖後並且是在使用中的狀態可以為“使用中已解鎖”。 Next, the control method 400 of the IoT device then executes step S428. After the cross-chain server 120 detects the operation record, it updates the smart contract corresponding to the selected IoT device 130; and in step S429, the cross-chain server 120 transmits the The state corresponding to the selected IoT device 130 is sent to the electronic device 140. Following the above embodiment, when the first blockchain 110a receives the operation record, the cross-chain server 120 will detect the operation record and update the smart contract of the smart cabinet A on the second blockchain 110b, and then send it back The state corresponding to the smart cabinet A is sent to the user's electronic device 140 and the merchant server 150. For example, if the smart cabinet A is unlocked and in use, the state may be "unlocked in use".

接著,物聯網裝置之控制方法400執行步驟 S430,透過跨鏈伺服器120更新被控制的物聯網裝置130對應的狀態。於一實施例中,步驟S430係用以利用電子裝置140更新智能櫃A的狀態,步驟S430更包含步驟S431~S436。請進一步參考第7圖,第7圖係根據本案之一些實施例所繪示之步驟S430的流程圖,如第7圖所示,物聯網裝置之控制方法400接著執行步驟S431,被選擇的物聯網裝置130傳送狀態更新紀錄至第一區塊鏈110a。於一實施例中,當使用者將智能櫃A上鎖後,智能櫃A會傳送狀態更新紀錄至第一區塊鏈110a。 Next, the control method 400 of the IoT device executes steps S430: Update the status corresponding to the controlled IoT device 130 through the cross-chain server 120. In one embodiment, step S430 is used to update the status of the smart cabinet A using the electronic device 140. Step S430 further includes steps S431 to S436. Please further refer to FIG. 7, which is a flowchart of step S430 according to some embodiments of the present case. As shown in FIG. 7, the control method 400 of the Internet of Things device then executes step S431, the selected object The networked device 130 transmits the status update record to the first blockchain 110a. In one embodiment, when the user locks the smart cabinet A, the smart cabinet A sends a status update record to the first blockchain 110a.

接著,物聯網裝置之控制方法400接著執行步驟S432,電子裝置140傳送被選擇的物聯網裝置130對應的合約識別號以及上鎖資訊至跨鏈伺服器120。於一實施例中,使用者的電子裝置140在使用者關上智能櫃A的櫃門後,會傳送智能櫃A對應的合約識別號以及上鎖資訊至跨鏈伺服器120,以確認智能櫃A已完成上鎖。 Next, the control method 400 of the IoT device then executes step S432, and the electronic device 140 transmits the contract identification number and the lock information corresponding to the selected IoT device 130 to the cross-chain server 120. In one embodiment, after the user closes the door of the smart cabinet A, the user's electronic device 140 transmits the contract identification number and the lock information corresponding to the smart cabinet A to the cross-chain server 120 to confirm the smart cabinet A The lock has been completed.

接著,物聯網裝置之控制方法400接著執行步驟S433,根據合約識別號於第二區塊鏈110b上查詢被選擇的物聯網裝置130對應的智能合約,以及步驟S434,第二區塊鏈110b回傳智能合約的內容資訊至跨鏈伺服器120。於一實施例中,步驟S433~S434的操作方式與步驟S423~S424類似,都是跨鏈伺服器120提出查詢智能合約的請求,第二區塊鏈110b會回傳智能櫃A的智能合約的內容資訊,在此不再贅述。 Next, the control method 400 of the IoT device then executes step S433 to query the smart contract corresponding to the selected IoT device 130 on the second blockchain 110b according to the contract identification number, and step S434, the second blockchain 110b returns The content information of the smart contract is transmitted to the cross-chain server 120. In an embodiment, steps S433~S434 operate in a similar manner to steps S423~S424. Both cross-chain servers 120 make requests to query smart contracts, and the second blockchain 110b will return the smart contract of smart cabinet A. Content information will not be repeated here.

接著,物聯網裝置之控制方法400接著執行步 驟S435,跨鏈伺服器120偵測到狀態更新紀錄後,根據身分識別號以及被選擇的物聯網裝置130對應的狀態驗證上鎖資訊。於一實施例中,跨鏈伺服器120會偵測到智能櫃A的狀態更新紀錄後,會根據智能櫃A當前的使用狀態以及電子裝置140的身分識別號與上鎖資訊比對,以確認智能櫃A已經上鎖。 Next, the control method 400 of the IoT device then executes the steps In step S435, after detecting the status update record, the cross-chain server 120 verifies the lock information according to the identity identification number and the status corresponding to the selected IoT device 130. In an embodiment, after detecting the status update record of the smart cabinet A, the cross-chain server 120 compares the current use status of the smart cabinet A and the identification number of the electronic device 140 with the lock information to confirm Smart cabinet A is locked.

接著,物聯網裝置之控制方法400接著執行步驟S436,上鎖資訊驗證成功後,跨鏈伺服器120更新被選擇的物聯網裝置130對應的該智能合約。於一實施例中,當確認智能櫃A已經上鎖後,跨鏈伺服器120會更新智能櫃A對應的智能合約,以更新智能櫃A的狀態,舉例而言,如果智能櫃A上鎖後並且是在使用中的狀態可以為“使用中已上鎖”。 Next, the control method 400 of the IoT device then executes step S436. After the verification of the lock information is successful, the cross-chain server 120 updates the smart contract corresponding to the selected IoT device 130. In an embodiment, when it is confirmed that the smart cabinet A has been locked, the cross-chain server 120 will update the smart contract corresponding to the smart cabinet A to update the status of the smart cabinet A. For example, if the smart cabinet A is locked And the state in use can be "locked in use".

接著,物聯網裝置之控制方法400接著執行步驟S437,跨鏈伺服器120傳送被選擇的物聯網裝置130對應的狀態至電子裝置140,以及更新商家伺服器150中被選擇的物聯網裝置130對應的狀態。於一實施例中,更新完智能合約後,跨鏈伺服器120會再傳送智能櫃A對應的狀態至電子裝置140,以及更新商家伺服器150中智能櫃A對應的狀態。 Then, the control method 400 of the IoT device then executes step S437, the cross-chain server 120 transmits the status corresponding to the selected IoT device 130 to the electronic device 140, and updates the correspondence of the selected IoT device 130 in the merchant server 150 status. In one embodiment, after the smart contract is updated, the cross-chain server 120 will then send the state corresponding to the smart cabinet A to the electronic device 140, and update the state corresponding to the smart cabinet A in the merchant server 150.

於另一實施例中,使用者也可以選擇不預約物聯網裝置130,也就是不執行步驟S410的流程,僅執行步驟S420~S430的流程,由於步驟S420是解鎖物聯網裝置130以及步驟S430是上鎖物聯網裝置130,因此在一般情況 下步驟S430的流程通常會與步驟S420的流程一起發生,僅有在特殊的異常狀況下步驟S420才會與步驟S430獨立發生,例如使用者未關上櫃門,或是解鎖櫃門發生異常等情況。 In another embodiment, the user can also choose not to reserve the IoT device 130, that is, the process of step S410 is not performed, and only the process of steps S420 to S430 is performed, because step S420 is to unlock the Internet of Things device 130 and step S430 is Lock the IoT device 130, so in general The flow of the next step S430 usually occurs together with the flow of the step S420. Only under special abnormal conditions will the step S420 and the step S430 occur independently, for example, the user does not close the door or unlocks the door and an abnormality occurs. .

由上述本案之實施方式可知,本案主要是改進以往集中式管理的管理僵化問題與安全隱私爭議,以及現有非集中式管理機制因區塊鏈交易時間過長無法進行即時交易等問題。利用物聯網裝置合約管理服務,保留集中式管理彈性部署、數據安全可靠的特性,達到物聯網裝置即時互動,並降低物聯網裝置開發與部署成本的功效。 It can be seen from the implementation of the above case that this case is mainly to improve the management rigidity and security privacy disputes of the previous centralized management, as well as the current non-centralized management mechanism because the blockchain transaction time is too long to conduct real-time transactions. The use of IoT device contract management services retains the features of centralized management, flexible deployment, and data security and reliability to achieve real-time interaction of IoT devices and reduce the cost of IoT device development and deployment costs.

另外,上述例示包含依序的示範步驟,但該些步驟不必依所顯示的順序被執行。以不同順序執行該些步驟皆在本揭示內容的考量範圍內。在本揭示內容之實施例的精神與範圍內,可視情況增加、取代、變更順序及/或省略該些步驟。 In addition, the above example includes exemplary steps in order, but the steps need not be performed in the order shown. Performing these steps in different orders is within the scope of this disclosure. Within the spirit and scope of the embodiments of the present disclosure, the order may be added, replaced, changed, and/or omitted as appropriate.

雖然本案已以實施方式揭示如上,然其並非用以限定本案,任何熟習此技藝者,在不脫離本案之精神和範圍內,當可作各種之更動與潤飾,因此本案之保護範圍當視後附之申請專利範圍所界定者為準。 Although this case has been disclosed as above by way of implementation, it is not intended to limit this case. Anyone who is familiar with this skill can make various changes and modifications within the spirit and scope of this case, so the scope of protection of this case should be considered The scope of the attached patent application shall prevail.

100‧‧‧物聯網裝置之控制系統 100‧‧‧Control system of Internet of Things device

110‧‧‧區塊鏈網路 110‧‧‧Blockchain network

110a‧‧‧第一區塊鏈 110a‧‧‧The first blockchain

110b‧‧‧第二區塊鏈 110b‧‧‧second blockchain

120‧‧‧跨鏈伺服器 120‧‧‧Cross-chain server

130、130-1~130-n‧‧‧物聯網裝置 130、130-1~130-n‧‧‧Internet of Things device

140‧‧‧電子裝置 140‧‧‧Electronic device

150‧‧‧商家伺服器 150‧‧‧merchant server

Claims (14)

一種物聯網裝置之控制方法,應用於複數個物聯網裝置,每一該物聯網裝置具有對應的一裝置識別號,該物聯網裝置之控制方法包含:透過一跨鏈伺服器接收並儲存每一該物聯網裝置對應的該裝置識別號,每一物聯網裝置並於一第一區塊鏈上註冊其對應的該裝置識別號;透過該跨鏈伺服器將該裝置識別號填入對應的一智能合約;以及將該智能合約部署至一第二區塊鏈以產生對應該智能合約的一合約識別號並儲存對應的該裝置識別號;其中,該跨鏈伺服器根據該合約識別號查詢該智能合約,產生對應該智能合約之該裝置識別號的一控制指令並傳送到該第一區塊鏈,以供對應該裝置識別號的物聯網裝置連接到該第一區塊鏈取得。 A control method of an Internet of Things device is applied to a plurality of Internet of Things devices, each of which has a corresponding device identification number. The control method of the Internet of Things device includes: receiving and storing each through a cross-chain server The device identification number corresponding to the IoT device, each IoT device registers its corresponding device identification number on a first blockchain; the device identification number is filled into the corresponding one through the cross-chain server Smart contract; and deploy the smart contract to a second blockchain to generate a contract identification number corresponding to the smart contract and store the corresponding device identification number; wherein, the cross-chain server queries the contract based on the contract identification number The smart contract generates a control command corresponding to the device identification number of the smart contract and transmits it to the first blockchain for the Internet of Things device corresponding to the device identification number to connect to the first blockchain to obtain. 如請求項1所述的物聯網裝置之控制方法,更包含:該跨鏈伺服器傳送每一該物聯網裝置的該合約識別號至一商家伺服器,由該商家伺服器記錄每一該物聯網裝置對應的狀態。 The control method of the IoT device according to claim 1, further comprising: the cross-chain server transmits the contract identification number of each IoT device to a merchant server, and the merchant server records each of the items The status of the connected device. 如請求項1所述的物聯網裝置之控制方法,更包含: 利用一電子裝置透過該跨鏈伺服器提出一預約請求。 The control method of the Internet of Things device according to claim 1, further comprising: An electronic device is used to make a reservation request through the cross-chain server. 如請求項3所述的物聯網裝置之控制方法,其中,利用該電子裝置透過該跨鏈伺服器提出該預約請求,更包含:藉由該電子裝置傳送對應的一身分識別號以及一查詢請求至該跨鏈伺服器;藉由該跨鏈伺服器依據該裝置識別碼向該第二區塊鏈提出該查詢請求,以查詢每一該物聯網裝置對應的該智能合約的該使用資訊;藉由該跨鏈伺服器傳送每一該物聯網裝置對應的該使用資訊至該電子裝置;其中該使用資訊包含該合約識別號、該些物聯網裝置的位置、該些物聯網裝置對應的狀態;選擇該些物聯網裝置的其中之一,並傳送一預約資訊至該跨鏈伺服器;其中該預約資訊包含該身分識別號、該合約識別號、被選擇的物聯網裝置對應的該裝置識別號;藉由該跨鏈伺服器傳送該預約資訊至該第二區塊鏈,並更新被選擇的物聯網裝置對應的狀態;以及更新該商家伺服器中被選擇的物聯網裝置對應的狀態。 The control method of the Internet of Things device according to claim 3, wherein using the electronic device to submit the reservation request through the cross-chain server, further includes: sending a corresponding identification number and a query request by the electronic device To the cross-chain server; the cross-chain server submits the query request to the second blockchain according to the device identification code to query the usage information of the smart contract corresponding to each of the IoT devices; The cross-chain server transmits the usage information corresponding to each IoT device to the electronic device; wherein the usage information includes the contract identification number, the location of the IoT devices, and the status corresponding to the IoT devices; Select one of the IoT devices and send a reservation information to the cross-chain server; wherein the reservation information includes the identity identification number, the contract identification number, and the device identification number corresponding to the selected IoT device Sending the reservation information to the second blockchain through the cross-chain server and updating the status corresponding to the selected IoT device; and updating the status corresponding to the selected IoT device in the merchant server. 如請求項1所述的物聯網裝置之控制方法,更包含:利用一電子裝置透過該跨鏈伺服器以執行該智能合約並控制對應該智能合約的物聯網裝置;以及 透過該跨鏈伺服器更新被控制的物聯網裝置對應的狀態。 The control method of the IoT device according to claim 1, further comprising: using an electronic device to execute the smart contract through the cross-chain server and controlling the IoT device corresponding to the smart contract; and The corresponding state of the controlled IoT device is updated through the cross-chain server. 如請求項5所述的物聯網裝置之控制方法,其中,利用該電子裝置透過該跨鏈伺服器以執行該智能合約並控制對應該智能合約的物聯網裝置,更包含:利用該電子裝置讀取該些物聯網裝置的其中之一對應的一條碼,並取得被選擇的物聯網裝置對應的該合約識別號;將該合約識別號以及一操作資訊傳送至該跨鏈伺服器;根據該合約識別號於該第二區塊鏈上查詢被選擇的物聯網裝置對應的該智能合約;該第二區塊鏈回傳該智能合約的一內容資訊至該跨鏈伺服器;其中,該內容資訊包含被選擇的物聯網裝置對應的該裝置識別號以及被選擇的物聯網裝置對應的狀態;該跨鏈伺服器根據該身分識別號以及被選擇的物聯網裝置對應的狀態驗證該操作資訊,並傳送一控制指令至該第一區塊鏈;被選擇的物聯網裝置連接到該第一區塊鏈取得該控制指令;被選擇的物聯網裝置傳送一操作紀錄至該第一區塊鏈;該跨鏈伺服器偵測到該操作紀錄後,更新被選擇的物聯網裝置對應的該智能合約;以及該跨鏈伺服器傳送被選擇的物聯網裝置對應的狀態至 該電子裝置。 The control method of an IoT device according to claim 5, wherein using the electronic device to execute the smart contract through the cross-chain server and controlling the IoT device corresponding to the smart contract further includes: using the electronic device to read Take a bar code corresponding to one of the IoT devices, and obtain the contract identification number corresponding to the selected IoT device; send the contract identification number and an operation information to the cross-chain server; according to the contract The identification number queries the smart contract corresponding to the selected IoT device on the second blockchain; the second blockchain returns a content information of the smart contract to the cross-chain server; wherein, the content information Including the device identification number corresponding to the selected IoT device and the status corresponding to the selected IoT device; the cross-chain server verifies the operation information according to the identity identification number and the status corresponding to the selected IoT device, and Send a control command to the first blockchain; the selected IoT device connects to the first blockchain to obtain the control command; the selected IoT device sends an operation record to the first blockchain; the After the cross-chain server detects the operation record, it updates the smart contract corresponding to the selected IoT device; and the cross-chain server transmits the status corresponding to the selected IoT device to The electronic device. 如請求項5所述的物聯網裝置之控制方法,其中,透過該跨鏈伺服器更新被控制的物聯網裝置對應的狀態,更包含:被選擇的物聯網裝置傳送一狀態更新紀錄至該第一區塊鏈;該電子裝置傳送被選擇的物聯網裝置對應的該合約識別號以及一上鎖資訊至該跨鏈伺服器;根據該合約識別號於該第二區塊鏈上查詢被選擇的物聯網裝置對應的該智能合約;該第二區塊鏈回傳該智能合約的該內容資訊至該跨鏈伺服器;該跨鏈伺服器偵測到該狀態更新紀錄後,根據該身分識別號以及被選擇的物聯網裝置對應的狀態驗證該上鎖資訊;該上鎖資訊驗證成功後,該跨鏈伺服器更新被選擇的物聯網裝置對應的該智能合約;以及該跨鏈伺服器傳送被選擇的物聯網裝置對應的狀態至該電子裝置,以及更新該商家伺服器中被選擇的物聯網裝置對應的狀態。 The control method of the IoT device according to claim 5, wherein updating the state corresponding to the controlled IoT device through the cross-chain server further includes: the selected IoT device sends a status update record to the first A blockchain; the electronic device sends the contract identification number corresponding to the selected IoT device and a lock information to the cross-chain server; inquires on the second blockchain based on the contract identification number the selected The smart contract corresponding to the Internet of Things device; the second blockchain returns the content information of the smart contract to the cross-chain server; after detecting the status update record, the cross-chain server according to the identity identification number And the state corresponding to the selected IoT device verifies the lock information; after the verification of the lock information is successful, the cross-chain server updates the smart contract corresponding to the selected IoT device; and the cross-chain server transmits the The state corresponding to the selected IoT device is sent to the electronic device, and the state corresponding to the selected IoT device in the merchant server is updated. 一種物聯網裝置之控制系統,應用於一區塊鏈網路,該區塊鏈網路包含一第一區塊鏈以及一第二區塊 鏈,該物聯網裝置之控制系統包含:複數個物聯網裝置,每一該物聯網裝置具有對應的一裝置識別號;以及一跨鏈伺服器,與該些物聯網裝置與該區塊鏈網路通訊連接,該跨鏈伺服器更用以接收並儲存每一該物聯網裝置對應的該裝置識別號,每一物聯網裝置並於該第一區塊鏈上註冊其對應的該裝置識別號,並將該裝置識別號填入對應的一智能合約,以將該智能合約部署至該第二區塊鏈以產生對應該智能合約的一合約識別號並儲存對應的該裝置識別號,其中,該跨鏈伺服器根據該合約識別號查詢該智能合約,產生對應該智能合約之該裝置識別號的一控制指令並傳送到該第一區塊鏈,以供對應該裝置識別號的物聯網裝置連接到第一區塊鏈取得。 A control system of an Internet of Things device applied to a blockchain network, the blockchain network includes a first blockchain and a second block Chain, the control system of the IoT device includes: a plurality of IoT devices, each of which has a corresponding device identification number; and a cross-chain server, the IoT devices and the blockchain network Communication connection, the cross-chain server is further used to receive and store the device identification number corresponding to each IoT device, and each IoT device registers its corresponding device identification number on the first blockchain , And fill the device identification number into a corresponding smart contract to deploy the smart contract to the second blockchain to generate a contract identification number corresponding to the smart contract and store the corresponding device identification number, where, The cross-chain server queries the smart contract according to the contract identification number, generates a control command corresponding to the device identification number of the smart contract and transmits it to the first blockchain for the Internet of Things device corresponding to the device identification number Get connected to the first blockchain. 如請求項8所述的物聯網裝置之控制系統,其中,每一該物聯網裝置更包含:一處理器,用以產生該裝置識別號;一通訊模組,與該處理器電性連接,用以與該跨鏈伺服器以及該第一區塊鏈通訊連接並取得該控制指令;以及一電子鎖頭構件,與該處理器電性連接;其中,該處理器用以根據該控制指令控制該電子鎖頭構件的上鎖及解鎖。 The control system of the Internet of Things device according to claim 8, wherein each of the Internet of Things devices further includes: a processor for generating the device identification number; and a communication module electrically connected to the processor, Used to communicate with the cross-chain server and the first blockchain to obtain the control command; and an electronic lock component electrically connected to the processor; wherein the processor is used to control the control command according to the control command Locking and unlocking of electronic lock components. 如請求項8所述的物聯網裝置之控制系統, 其中,每一該物聯網裝置更包含有一條碼以記錄該裝置識別碼,且該控制系統更包含:一電子裝置,與該跨鏈伺服器通訊連接,用以讀取該條碼後透過該跨鏈伺服器提出以查詢對應該物聯網裝置之一使用資訊。 The control system of the Internet of Things device described in claim 8, Wherein, each of the IoT devices further includes a bar code to record the device identification code, and the control system further includes: an electronic device, which is in communication with the cross-chain server for reading the bar code and then through the cross-chain The server proposes to query usage information corresponding to one of the IoT devices. 如請求項8所述的物聯網裝置之控制系統,其中,該控制系統更包含:一商家伺服器,與該跨鏈伺服器通訊連接,以接收每一該物聯網裝置的該合約識別號,並記錄每一該物聯網裝置對應的狀態;以及一電子裝置,用以傳送對應的一身分識別號以及一查詢請求至該跨鏈伺服器,該跨鏈伺服器依據該裝置識別碼向該第二區塊鏈提出該查詢請求,以查詢每一該物聯網裝置對應的該智能合約的該使用資訊;其中,該跨鏈伺服器用以傳送每一該物聯網裝置對應的該使用資訊至該電子裝置;其中,該電子裝置用以提供選擇該些物聯網裝置的其中之一,並傳送一預約資訊至該跨鏈伺服器;其中,該跨鏈伺服器用以傳送該預約資訊至該第二區塊鏈,並更新被選擇的物聯網裝置對應的狀態,以及更新該商家伺服器中被選擇的物聯網裝置對應的狀態;其中,該使用資訊包含該合約識別號、該些物聯網裝置的位置、該些物聯網裝置對應的狀態;該預約資訊包含該 身分識別號、該合約識別號、被選擇的物聯網裝置對應的該裝置識別號。 The control system of the Internet of Things device according to claim 8, wherein the control system further comprises: a merchant server connected to the cross-chain server to receive the contract identification number of each Internet of Things device, And record the corresponding state of each of the IoT devices; and an electronic device for transmitting a corresponding identity identification number and a query request to the cross-chain server, the cross-chain server sends the first Two blockchains submit the query request to query the usage information of the smart contract corresponding to each IoT device; wherein, the cross-chain server is used to transmit the usage information corresponding to each IoT device to the An electronic device; wherein, the electronic device is used to provide selection of one of the IoT devices and send a reservation information to the cross-chain server; wherein, the cross-chain server is used to send the reservation information to the first Two blockchains, and update the status corresponding to the selected IoT device and the status corresponding to the selected IoT device in the merchant server; wherein, the usage information includes the contract identification number and the IoT devices Location of the Internet of Things, the status of the corresponding IoT devices; the reservation information contains the The identity identification number, the contract identification number, and the device identification number corresponding to the selected IoT device. 如請求項8所述的物聯網裝置之控制系統,其中,該電子裝置更用以透過該跨鏈伺服器以執行該智能合約並控制對應該智能合約的物聯網裝置,以及該跨鏈伺服器用以更新被控制的物聯網裝置對應的狀態。 The control system of the IoT device according to claim 8, wherein the electronic device is further used to execute the smart contract and control the IoT device corresponding to the smart contract through the cross-chain server, and the cross-chain server It is used to update the corresponding state of the controlled IoT device. 如請求項12所述的物聯網裝置之控制系統,其中,利用該電子裝置選擇該些物聯網裝置的其中之一,並取得被選擇的物聯網裝置對應的該合約識別號,該電子裝置用以將該合約識別號以及一操作資訊傳送至該跨鏈伺服器,該跨鏈伺服器用以根據該合約識別號於該第二區塊鏈上查詢被選擇的物聯網裝置對應的該智能合約,並接收該第二區塊鏈回傳該智能合約的一內容資訊;該跨鏈伺服器根據該身分識別號以及被選擇的物聯網裝置對應的狀態驗證該操作資訊,並傳送一控制指令至該第一區塊鏈;接著,被選擇的物聯網裝置用以連接到該第一區塊鏈取得該控制指令,並傳送一操作紀錄至該第一區塊鏈;該跨鏈伺服器用以偵測到該操作紀錄後,更新被選擇的物聯網裝置對應的該智能合約,接著傳送被選擇的物聯網裝置對應的狀態至該電子裝置;以及其中,該內容資訊包含被選擇的物聯網裝置對應的該裝置識別號以及被選擇的物聯網裝置對應的狀態。 The control system of the IoT device according to claim 12, wherein the electronic device is used to select one of the IoT devices and obtain the contract identification number corresponding to the selected IoT device. The electronic device uses To send the contract identification number and an operation information to the cross-chain server, the cross-chain server is used to query the smart contract corresponding to the selected IoT device on the second blockchain according to the contract identification number , And receives the second blockchain to return a piece of content information of the smart contract; the cross-chain server verifies the operation information according to the identity number and the corresponding state of the selected IoT device, and sends a control command to The first blockchain; then, the selected IoT device is used to connect to the first blockchain to obtain the control command and send an operation record to the first blockchain; the cross-chain server is used to After detecting the operation record, update the smart contract corresponding to the selected IoT device, and then transmit the status corresponding to the selected IoT device to the electronic device; and wherein the content information includes the selected IoT device The corresponding device identification number and the status corresponding to the selected IoT device. 如請求項12所述的物聯網裝置之控制系統,其中,被選擇的物聯網裝置用以傳送一狀態更新紀錄至該第一區塊鏈,接著該電子裝置用以傳送被選擇的物聯網裝置對應的該合約識別號以及一上鎖資訊至該跨鏈伺服器;該跨鏈伺服器用以根據該合約識別號於該第二區塊鏈上查詢被選擇的物聯網裝置對應的該智能合約,接著接收該第二區塊鏈回傳的該智能合約的該內容資訊;該跨鏈伺服器用以偵測到該狀態更新紀錄後,根據該身分識別號以及被選擇的物聯網裝置對應的狀態驗證該上鎖資訊,該上鎖資訊驗證成功後,該跨鏈伺服器更新被選擇的物聯網裝置對應的該智能合約,以及傳送被選擇的物聯網裝置對應的狀態至該電子裝置,並更新該商家伺服器中被選擇的物聯網裝置對應的狀態。 The control system of the IoT device according to claim 12, wherein the selected IoT device is used to transmit a status update record to the first blockchain, and then the electronic device is used to transmit the selected IoT device The corresponding contract identification number and a lock information to the cross-chain server; the cross-chain server is used to query the smart contract corresponding to the selected IoT device on the second blockchain according to the contract identification number , And then receive the content information of the smart contract returned by the second blockchain; the cross-chain server is used to detect the status update record, according to the identity number and the selected IoT device corresponding The state verifies the lock information. After the lock information is successfully verified, the cross-chain server updates the smart contract corresponding to the selected IoT device, and transmits the state corresponding to the selected IoT device to the electronic device, and Update the status corresponding to the selected IoT device in the merchant server.
TW107142538A 2018-11-28 2018-11-28 Control method and control system for internet of things device TWI683590B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
TW107142538A TWI683590B (en) 2018-11-28 2018-11-28 Control method and control system for internet of things device
CN201811486652.5A CN111245883A (en) 2018-11-28 2018-12-06 Control method and control system of Internet of things device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW107142538A TWI683590B (en) 2018-11-28 2018-11-28 Control method and control system for internet of things device

Publications (2)

Publication Number Publication Date
TWI683590B true TWI683590B (en) 2020-01-21
TW202021414A TW202021414A (en) 2020-06-01

Family

ID=69942381

Family Applications (1)

Application Number Title Priority Date Filing Date
TW107142538A TWI683590B (en) 2018-11-28 2018-11-28 Control method and control system for internet of things device

Country Status (2)

Country Link
CN (1) CN111245883A (en)
TW (1) TWI683590B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI849928B (en) * 2023-05-24 2024-07-21 樺緯物聯股份有限公司 Network group control method
TWI850379B (en) * 2020-05-13 2024-08-01 微星科技股份有限公司 Payment method and system

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113518103A (en) * 2021-03-01 2021-10-19 唐芮 Industrial Internet of things networking control method and system

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018020377A1 (en) * 2016-07-29 2018-02-01 nChain Holdings Limited Blockchain-implemented method and system
TW201810990A (en) * 2016-07-29 2018-03-16 安地卡及巴布達商區塊鏈控股有限公司 Blockchain-implemented method and system
EP3367289A1 (en) * 2017-02-27 2018-08-29 Nokia Solutions and Networks Oy Internet connection setup between computing devices using blockchains
US20180300382A1 (en) * 2017-04-12 2018-10-18 Vijay K. Madisetti Method and System for Tuning Blockchain Scalability for Fast and Low-Cost Payment and Transaction Processing
US20180302222A1 (en) * 2017-04-18 2018-10-18 Samsung Electronics Co., Ltd. Method and apparatus for access control in distributed blockchain-based internet of things (iot) network
CN108881187A (en) * 2018-05-31 2018-11-23 杭州秘猿科技有限公司 A kind of across chain data transferring method and equipment suitable for permitting chain scene
CN108898390A (en) * 2018-06-27 2018-11-27 阿里巴巴集团控股有限公司 Intelligent contract call method and device, electronic equipment based on block chain

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108737348A (en) * 2017-04-21 2018-11-02 中国科学院信息工程研究所 A kind of internet of things equipment access control method of the intelligent contract based on block chain
CN107392618B (en) * 2017-07-28 2021-02-12 苏州朗润创新知识产权运营有限公司 Method and equipment for implanting intelligent contract
CN107819829B (en) * 2017-10-17 2020-07-07 上海点融信息科技有限责任公司 Method and system for accessing block chain, block chain node point equipment and user terminal
CN107819848A (en) * 2017-11-08 2018-03-20 济南浪潮高新科技投资发展有限公司 A kind of internet of things equipment autonomy interconnected method based on block chain
CN108009878A (en) * 2017-11-24 2018-05-08 深圳市轱辘车联数据技术有限公司 A kind of information processing method and its device
CN108073829B (en) * 2017-12-29 2024-10-15 巍乾全球技术有限责任公司 Method, medium, internet of things device, blockchain platform and internet of things system for recording transportation data of objects
CN108880797B (en) * 2018-06-27 2021-09-24 京信网络系统股份有限公司 Authentication method of Internet of things equipment and Internet of things equipment

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018020377A1 (en) * 2016-07-29 2018-02-01 nChain Holdings Limited Blockchain-implemented method and system
TW201810990A (en) * 2016-07-29 2018-03-16 安地卡及巴布達商區塊鏈控股有限公司 Blockchain-implemented method and system
EP3367289A1 (en) * 2017-02-27 2018-08-29 Nokia Solutions and Networks Oy Internet connection setup between computing devices using blockchains
US20180300382A1 (en) * 2017-04-12 2018-10-18 Vijay K. Madisetti Method and System for Tuning Blockchain Scalability for Fast and Low-Cost Payment and Transaction Processing
US20180302222A1 (en) * 2017-04-18 2018-10-18 Samsung Electronics Co., Ltd. Method and apparatus for access control in distributed blockchain-based internet of things (iot) network
CN108881187A (en) * 2018-05-31 2018-11-23 杭州秘猿科技有限公司 A kind of across chain data transferring method and equipment suitable for permitting chain scene
CN108898390A (en) * 2018-06-27 2018-11-27 阿里巴巴集团控股有限公司 Intelligent contract call method and device, electronic equipment based on block chain

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI850379B (en) * 2020-05-13 2024-08-01 微星科技股份有限公司 Payment method and system
TWI849928B (en) * 2023-05-24 2024-07-21 樺緯物聯股份有限公司 Network group control method

Also Published As

Publication number Publication date
CN111245883A (en) 2020-06-05
TW202021414A (en) 2020-06-01

Similar Documents

Publication Publication Date Title
TWI683590B (en) Control method and control system for internet of things device
CN103679860B (en) Household burglary-resisting system and method for work thereof
CN102308515B (en) Transforming static password systems to become 2-factor authentication
US20170171201A1 (en) Authorization delegation system, information processing apparatus, authorization server, control method, and storage medium
CN109146679A (en) Intelligent contract call method and device, electronic equipment based on block chain
CA2992736C (en) Method and apparatus for providing secure communication among constrained devices
CN103136820A (en) Remote access control system based on terminal fingerprint identification
CN110427785A (en) Acquisition methods and device, the storage medium and electronic device of device-fingerprint
CN103078875B (en) A kind of smart machine mutual authentication method and system
CN103827878B (en) Automate Password Management
US20090119218A1 (en) License management apparatus, license management method, and license authentication program
CN109379336A (en) A kind of uniform authentication method, distributed system and computer readable storage medium
CN109960900A (en) A kind of registration code generating method and system
CN104674503A (en) System and method for controlling washing machine
CN109716331A (en) Meet the shared application deployment with decision service platform mode of application data
CN107534645A (en) Main frame authentication storage
CN106878009A (en) Key updating method and system
US9503449B1 (en) Application centric centralized certificate management system for managing certificates across data centers
CN107078806B (en) The programmed method and operating method and electric interfaces equipment of optical transceiver
CN110210863A (en) Block chain method for secure transactions, device, electronic equipment and storage medium
WO2013087016A1 (en) Safety information transfer system, device and method based on extended parameter set
JP2001126009A (en) Electronic information circulation system, storage medium storing electronic information circulation program and electronic information circulation method
KR101483864B1 (en) Method for Operating Multiple One Time Password based on Near Field Communication for Error Management
CN106846147A (en) A kind of financial transaction management system
CN100466558C (en) Method for realizing tax controlled data monitoring of POS system