The above and other technical features and advantages of the present invention will be described in more detail below in conjunction with the accompanying drawings.
 Such as figure 1 with figure 2 As shown, figure 1 Is the structure diagram of the smart lighting system based on the blockchain anti-tampering technology; figure 2 Is a schematic diagram of the operation of the blockchain system; the smart lighting system based on the blockchain anti-tampering technology of the present invention includes a single light controller, a centralized controller, a back-end server, and a blockchain underlying subsystem; the single light control The device is installed on the LED lamp and connected to the LED lamp through the NEMA interface. The single lamp controller includes a first communication module, a first memory, a first clock module, and a sensor module; the centralized controller is installed in the computer room The internal and the background server are connected by a network cable, the centralized controller includes a second communication module, a second clock module, and a second memory, and the blockchain bottom layer subsystem runs on the background server.
 The first communication module and the second communication module may both adopt Zigbee communication modules.
 Specifically, the underlying subsystem of the blockchain includes data blocks, timestamps, hash tables, P2P networks, SHA-256 algorithms, Kafka consensus algorithms, etc. The underlying subsystem of the blockchain will After the lighting system runs, the core data of the smart lighting system (such as user configuration files, network configuration files, IDs, etc.) are entered into the chain and uploaded to the verification node, and synchronized with each verification node in real time. The data stored in the chain cannot be tampered with.
 Specifically, the working circuit of the single-lamp controller includes a single-chip microcomputer MSP430F2553, the sensor module adopts a TSL2561 light-sensing chip, and the LED lamps are operated according to the instructions of the centralized controller and the sensor illuminance information collected by the sensor module. Switch control and brightness adjustment control.
 Specifically, the centralized controller includes a single-chip microcomputer MSP430F5325, which forwards control instructions to the single-lamp controller or receives abnormal information uploaded by the single-lamp controller through the second communication module, and the centralized controller acts as a verification The node regularly receives the hash value sent by the background server, and if the received value is inconsistent with the hash value received for the first time, it will refuse to execute the switch and brightness command sent by the background server and report an exception .
 Specifically, the background server can set the system switching time and adjust the brightness of the street lights, store the collected on-off status, brightness, voltage and current information, perform abnormal processing, form a contract energy report, etc., and receive the said in the form of a smart contract The abnormal situation reported by the underlying subsystem of the blockchain is notified to manual intervention and investigation or the system is automatically restored.
 The working process of the present invention is as follows:
 When the smart lighting system is working, the single-lamp controller receives the timing instructions from the centralized controller through the clock module and stores them, and then adjusts the on and off of street lights on time every day; through the sensor module Receive illuminance information and automatically adjust brightness and upload brightness data; calculate street lamp power consumption by detecting current and voltage and upload power data.
 When the smart lighting system is working, the centralized controller forwards the switch and brightness instruction of the background server to the single-lamp controller and receives the fault information uploaded by the single-lamp controller. In addition, the centralized control As a verification node, the device synchronizes with the background server regularly. If the received hash value is not compliant, it will refuse to execute the switch and brightness instructions sent by the background server, and report an exception.
 When the smart lighting system is working, the underlying subsystem of the blockchain will put the core data of the smart lighting system (such as user configuration files, network configuration files, ID, etc.) into the chain and upload to the verification node after the system is running , Synchronize with each of the verification nodes in real time, and report an exception when an unknown intrusion occurs.
 When the smart lighting system is working, the server software sets the switching time of the system and adjusts the brightness of the street lights, stores the collected on and off status, brightness data, voltage and current information, performs fault handling, forms contract energy reports, etc., and uses smart In the form of a contract, the abnormal situation reported by the underlying subsystem of the blockchain is received to notify manual intervention or automatic restoration of the system.
 The invention uses blockchain technology to protect the core data of the system; it has the function of automatically adjusting the brightness of the street lamp according to the brightness of the light; it has a Zigbee wireless transmission system, self-organizing network; it has a NEMA interface, plug and unplug; automatically detects current and voltage, and generates contract energy Report.
 The foregoing descriptions are only preferred embodiments of the present invention, which are only illustrative and not restrictive to the present invention. Those skilled in the art understand that many changes, modifications, and even equivalents can be made to the present invention within the spirit and scope defined by the claims of the present invention, but they will all fall within the protection scope of the present invention.