CN112399394A - Intelligent electric energy meter system based on Bluetooth communication and communication method thereof - Google Patents

Intelligent electric energy meter system based on Bluetooth communication and communication method thereof Download PDF

Info

Publication number
CN112399394A
CN112399394A CN202011197345.2A CN202011197345A CN112399394A CN 112399394 A CN112399394 A CN 112399394A CN 202011197345 A CN202011197345 A CN 202011197345A CN 112399394 A CN112399394 A CN 112399394A
Authority
CN
China
Prior art keywords
electric energy
energy meter
bluetooth
circuit breaker
miniature circuit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011197345.2A
Other languages
Chinese (zh)
Inventor
熊德智
周纲
尹梅
刘小平
柳青
温和
胡军华
陈浩
杨茂涛
卿曦
肖湘奇
曾伟杰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
State Grid Corp of China SGCC
State Grid Hunan Electric Power Co Ltd
Metering Center of State Grid Hunan Electric Power Co Ltd
Original Assignee
State Grid Corp of China SGCC
State Grid Hunan Electric Power Co Ltd
Metering Center of State Grid Hunan Electric Power Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by State Grid Corp of China SGCC, State Grid Hunan Electric Power Co Ltd, Metering Center of State Grid Hunan Electric Power Co Ltd filed Critical State Grid Corp of China SGCC
Priority to CN202011197345.2A priority Critical patent/CN112399394A/en
Publication of CN112399394A publication Critical patent/CN112399394A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • GPHYSICS
    • G08SIGNALLING
    • G08CTRANSMISSION SYSTEMS FOR MEASURED VALUES, CONTROL OR SIMILAR SIGNALS
    • G08C17/00Arrangements for transmitting signals characterised by the use of a wireless electrical link
    • G08C17/02Arrangements for transmitting signals characterised by the use of a wireless electrical link using a radio link
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/06Authentication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0212Power saving arrangements in terminal devices managed by the network, e.g. network or access point is master and terminal is slave
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses an intelligent electric energy meter system based on Bluetooth communication and a communication method thereof, wherein the system comprises an electric energy meter, an intelligent miniature circuit breaker, a terminal module and a Bluetooth module; the Bluetooth module adopts a Bluetooth module or an SOC mode; when the Bluetooth module is adopted, the Bluetooth module comprises a first Bluetooth module and a second Bluetooth module, and the electric energy meter is connected with the intelligent miniature circuit breaker and the slave equipment through the first Bluetooth module; the electric energy meter is connected with the terminal module sequentially through the first Bluetooth module and the second Bluetooth module; when the SOC mode is adopted, the electric energy meter is connected with the intelligent miniature circuit breaker, the slave and the terminal module through the integrated Bluetooth; when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with the intelligent miniature circuit breaker or other slave devices; when the electric energy meter is used as a slave, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication. The invention has the advantages of high safety and reliability, low power consumption, good stability and the like.

Description

Intelligent electric energy meter system based on Bluetooth communication and communication method thereof
Technical Field
The invention mainly relates to the technical field of intelligent electric energy meters, in particular to an intelligent electric energy meter system based on Bluetooth communication and a communication method thereof.
Background
The new generation of electric energy meter (IR46 modularized electric energy meter) has higher and higher requirements on data communication, in the existing electric energy meter technical system in China, the communication part is mainly realized by communication modules (power line carrier, micropower wireless and the like), RS485 and infrared at present, and from the practical application, the RS485 and infrared two modes have obvious defects, such as difficult RS485 wiring construction and low communication speed; the infrared communication is unreliable, the speed is slow, and the two technologies are obviously not suitable for the development trend of the future electric energy meter technology, and a high-speed and reliable local communication technology is urgently needed to replace RS485 and infrared.
The Bluetooth technology is upgraded through a plurality of versions, is widely applied to the field of Internet of things at present, is a mature communication technology, is completely nationalized, does not have monopoly problems, and can effectively make up the bottleneck of local communication of the electric energy meter.
In particular, bluetooth is a radio technology that supports short-range communication (typically within 10 m) of devices, enabling wireless information exchange between numerous devices including mobile phones, PDAs, wireless headsets, laptops, related peripherals, etc. By using the bluetooth technology, the communication between mobile communication terminal devices can be effectively simplified, and the communication between the devices and the Internet can also be successfully simplified, so that the data transmission becomes faster and more efficient, and the way is widened for wireless communication.
Bluetooth, as a small-range wireless connection technology, can implement data communication and voice communication between devices with convenience, rapidness, flexibility, safety, low cost and low power consumption, so that the Bluetooth is one of the mainstream technologies for implementing wireless personal area network communication at present, can bring wider application when being connected with other networks, is a top-end open wireless communication, can enable various digital devices to communicate wirelessly, and is one of wireless network transmission technologies.
Bluetooth is an open global specification for wireless data and voice communication that establishes an ad hoc connection for fixed and mobile device communication environments based on low-cost short-range wireless connections. The essence of the method is to establish a universal Radio Air Interface (Radio Air Interface) for the communication environment between fixed devices or mobile devices, and further combine the communication technology with the computer technology, so that various 3C devices can realize mutual communication or operation in a short distance range without mutual connection of wires or cables. Briefly, bluetooth technology is a technology for transmitting data to each other between various 3C devices using low power radio. Bluetooth operates in the 2.4GHz ISM (i.e., Industrial, scientific, medical) band, which is common worldwide, using the IEEE802.11 protocol. As an emerging short-range wireless communication technology, the development of low-rate wireless personal area networks is being strongly driven.
However, problems with bluetooth generally include the following:
(1) power consumption problems with bluetooth. Bluetooth is not very frequent in transmitting data, and consumes less energy in the process of transmitting data, but in order to respond to a connection request in time, polling access in the waiting process is very energy-consuming.
(2) The connection process of bluetooth is cumbersome. The connection process of bluetooth involves many information transmission and verification processes, which seemingly does not allow the user to feel a complicated connection procedure, but the repeated data encryption and decryption processes and the authentication process required for each connection are a great waste of computing resources of the device.
(3) The security problem of bluetooth. The first pairing of bluetooth needs the user to pass through PIN code verification, and PIN code generally only comprises the digit, and the digit is very few, generally is 4 ~ 6 bits. After the PIN is generated, the device automatically encrypts the PIN using the Bluetooth's own E2 or E3 encryption algorithm, and then transmits the PIN for authentication. In this process, it is highly likely that a hacker will crack the PIN code by intercepting the data packet, disguising it as a target bluetooth device to connect, or using a "brute force attack". In addition, the security of the encryption algorithm used in the process of transmitting data by bluetooth is still to be improved. The reason for this is that the bluetooth technology itself, and the design goal of bluetooth is to form a base station-less local area network (similar to ad hoc mode of WLAN) between devices to perform short-range communication between multiple devices, and in order to ensure privacy and security, the bluetooth protocol requires that identity authentication must be performed before each connection.
Disclosure of Invention
The technical problem to be solved by the invention is as follows: aiming at the problems in the prior art, the invention provides a safe, reliable and high-reliability intelligent electric energy meter system based on Bluetooth communication and a communication method thereof.
In order to solve the technical problems, the technical scheme provided by the invention is as follows:
an intelligent electric energy meter system based on Bluetooth communication comprises an electric energy meter, an intelligent miniature circuit breaker, a terminal module and a Bluetooth module; the Bluetooth module adopts a Bluetooth module or an SOC (system on chip), wherein the SOC is an integrated Bluetooth protocol stack of the electric energy meter; when the Bluetooth module is adopted, the Bluetooth module comprises a first Bluetooth module and a second Bluetooth module, and the electric energy meter is connected with the intelligent miniature circuit breaker and the slave equipment through the first Bluetooth module; the electric energy meter is connected with the terminal module sequentially through the first Bluetooth module and the second Bluetooth module; when the SOC mode is adopted, the electric energy meter is connected with the intelligent miniature circuit breaker, the slave and the terminal module through the integrated Bluetooth; when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with the intelligent miniature circuit breaker or other slave devices to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
As a further improvement of the above technical solution:
the Bluetooth module is single-mode low-power Bluetooth and is 4.0 version.
The invention also discloses a communication method of the intelligent electric energy meter system based on the Bluetooth communication, which comprises two modes of a Bluetooth module or an SOC, wherein when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with the intelligent miniature circuit breaker or other slave devices to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
As a further improvement of the above technical solution:
the method for connecting the electric energy meter and the intelligent miniature circuit breaker based on the fee control mode comprises the following steps of: the host computer needs to carry out Bluetooth authentication before the electric energy meter is operated through the Bluetooth module, and opens the operation authority, if the authentication is not passed, only the meter number, the communication address, the record number, the current date, the current time, the current electric energy and the current remaining amount can be read out, and other information is not allowed to be read out; writing data: the host computer needs to perform Bluetooth authentication before writing operation on the electric energy meter through the Bluetooth module, the authentication is not passed, all information is not allowed to be set, and only a Bluetooth authentication command is supported; the electric energy meter and the external intelligent miniature circuit breaker are in data interaction: the electric energy meter and the intelligent miniature circuit breaker are uniquely corresponding, the electric energy meter cannot operate other intelligent miniature circuit breakers, and the intelligent miniature circuit breaker cannot allow other electric energy meters to control; the electric energy meter has different read or write authorities to the intelligent miniature circuit breaker, and the read data can be confirmed, and the intelligent miniature circuit breaker identity authentication is needed when switching on or off or writing parameters; the Bluetooth of the electric energy meter is powered on and always keeps a working state, and the Bluetooth of the intelligent miniature circuit breaker is in a periodic awakening mode; the intelligent miniature circuit breaker is awakened by Bluetooth and then successfully connected with the electric energy meter, and if the random number password of the electric energy meter is not received for confirmation or the identity authentication of the intelligent miniature circuit breaker is not written, the connection is automatically disconnected within a preset time, so that an attacker is prevented from being maliciously connected.
The matching method of the electric energy meter and the intelligent miniature circuit breaker is also disclosed:
the terminal module completes identity authentication with the electric energy meter;
the Bluetooth MAC address of the intelligent miniature circuit breaker is set into the electric energy meter through the second type of parameters, the electric energy meter establishes data connection with the intelligent miniature circuit breaker according to the Bluetooth MAC address of the intelligent miniature circuit breaker, and meanwhile, the asset number of the intelligent miniature circuit breaker is written into an ESAM file of the electric energy meter through the first type of parameters;
the electric energy meter ESAM discretely generates various keys for controlling the intelligent miniature circuit breaker by using the asset number of the intelligent miniature circuit breaker, and the safety between the electric energy meter and the intelligent miniature circuit breaker is ensured by the keys; before the intelligent miniature circuit breaker is installed, discrete keys are installed according to the asset number of the intelligent miniature circuit breaker.
The intelligent miniature circuit breaker identity authentication and random password production process comprises the following steps:
after the electric energy meter is electrified, communication connection is established with the intelligent miniature circuit breaker by matching the MAC address;
the identity authentication of the intelligent miniature circuit breaker is carried out, and a returned random number is used as a random password after the identity authentication of the intelligent miniature circuit breaker is passed;
after passing the identity authentication, the intelligent miniature circuit breaker enters an identity authentication state, parameter modification and switching-on and switching-off operations can be carried out, and otherwise, an error is returned; the identity authentication process of the intelligent miniature circuit breaker is used for authentication before switching-on or writing operation, and data reading is not needed; the random password is used for data reading confirmation of the electric energy meter and the intelligent miniature circuit breaker, and is also used for an attacker to forge the Bluetooth MAC of the electric energy meter and frequently establish illegal connection with the intelligent miniature circuit breaker.
The process of reading the data of the intelligent miniature circuit breaker by the electric energy meter comprises the following steps:
the electric energy meter is connected with the intelligent miniature circuit breaker through the MAC address;
the electric energy meter sends a random password to the intelligent miniature circuit breaker, after the intelligent miniature circuit breaker confirms the random password, the reading authority is opened, and the electric energy meter can start to read the data of the intelligent miniature circuit breaker;
after the data reading is finished, the electric energy meter is disconnected, and if no data frame communication exists in the preset time, the intelligent miniature circuit breaker is actively disconnected;
wherein the process of electric energy meter control intelligent miniature circuit breaker does:
the terminal module completes identity authentication with the electric energy meter and issues a remote switching-on/off command to the electric energy meter;
after the electric energy meter correctly analyzes the ciphertext, the electric energy meter and the intelligent miniature circuit breaker perform identity authentication, and the electric energy meter directly exits after failure;
after the identity authentication of the intelligent miniature circuit breaker is passed, the writing operation is opened, and the electric energy meter can remotely open and close the intelligent miniature circuit breaker or write parameters of the ciphertext;
and when the switch is switched on or the data writing is finished, the electric energy meter is disconnected, and if the intelligent miniature circuit breaker does not have any data frame communication within the preset time, the intelligent miniature circuit breaker actively disconnects.
The electric energy meter has three working states, which are respectively: a broadcast state, a standby state, and a connection state;
when the electric energy meter is in a broadcast state, the electric energy meter waits for a period of time after sending broadcast each time, a random delay is generated before broadcasting each time and added in the broadcast, so that data collision caused by simultaneous broadcasting of a plurality of electric energy meters is avoided; the broadcasting electric energy meter respectively sends broadcasting data in different channels each time; after the electric energy meter sends the broadcast data, waiting for the terminal module to initiate a scanning request;
when the electric energy meter is in a connection state and does not need to be connected with the terminal module any more, the electric energy meter is actively disconnected and enters a standby state; if the electric energy meter is in a connection state and no data is transmitted for a period of time, the electric energy meter is actively disconnected and enters a standby state; when the connection is disconnected due to the loss of the connection, the electric energy meter tries to reconnect the terminal module, is not connected with any terminal equipment for a period of time, and automatically enters a standby state in order to reduce the power consumption of the electric energy meter;
when the electric energy meter is in a standby state and a terminal module sends a connection request to try to connect with the electric energy meter, the electric energy meter tries to connect with the terminal module for a period of time, whether the terminal module is in a white list or not is judged, if the terminal module is in the white list, the terminal module is connected with the terminal module, the electric energy meter enters a connection state, the electric energy meter is a slave machine, and the terminal module is a host machine; after a period of time, the electric energy meter attempts to connect with any terminal module and is allowed to connect with a new terminal module; if the connection is not successfully established for a period of time, the attempt to connect is stopped and the power meter remains in a "standby state".
The connection process of the electric energy meter and the terminal module is as follows: the electric energy meter works in a peripheral equipment mode, and the terminal module works in a central equipment mode; the electric energy meter sends broadcast, the terminal module scans the electric energy meter which is sending broadcast, when the electric energy meter receives the scanning request of the terminal module, the terminal module sends scanning response data to the terminal module, and after the terminal module receives the scanning response data, the terminal module initiates a connection request.
The electric energy meter and the intelligent miniature circuit breaker are communicated in a unique communication mode through Bluetooth, and the intelligent electric meter performs switching-on and switching-off operation on paired electric meters through a Bluetooth channel; the necessary configuration needs to be carried out on the two parties before communication; after the intelligent miniature circuit breaker and the electric energy meter are configured, the intelligent miniature circuit breaker and the electric energy meter can be connected, a unique communication path is established between the electric energy meter and the intelligent miniature circuit breaker through unique Mac identification, and communication data are encrypted and decrypted through a configured secret key.
Compared with the prior art, the invention has the advantages that:
the Bluetooth module power-on initialization method completes application layer protocol research, a BLE module framework and an SOC application framework of the high-reliability intelligent micro-break based on Bluetooth, and realizes series processes of power-on initialization and the like of the high-reliability intelligent micro-break Bluetooth module; the safety mechanism of the Bluetooth intelligent micro-breaking read-write data, remote control and information feedback based on the fee control mode realizes safety information interaction between the Bluetooth micro circuit breaker and the electric energy meter, and improves the Bluetooth pairing reliability under the electromagnetic interference environment of the Bluetooth micro circuit breaker and the overall reliability under the environment of long-term no-drop of the Bluetooth and temperature and humidity alternation under the complex environment.
The external circuit breaker of the new-generation electric energy meter is connected with the intelligent electric energy meter in a wireless Bluetooth mode, and the external circuit breaker of the new-generation electric energy meter is connected with the replaced intelligent electric energy meter in a wired level mode; the interaction, comprehensive perception, data fusion and intelligent application of the low-voltage distribution network to data information are realized, and the construction of an electric power internet of things and an intelligent power grid is supported; the accurate and automatic pairing between the new-generation electric energy meter and the external circuit breaker is realized, and the problem of controlling the 'house-crossing' is prevented; technical support is provided for detection of a new generation of Bluetooth intelligent miniature circuit breaker, and reliability and stability of a later-stage network access miniature circuit breaker are ensured; the technical problems of Bluetooth pairing reliability in an electromagnetic interference environment, long-term no-disconnection of Bluetooth in a complex environment, reliability in a temperature and humidity alternating environment and the like are solved.
The invention selects the low-power Bluetooth to replace RS485 and infrared, and has very low static and dynamic communication power consumption; the Bluetooth with low power consumption has a newly added broadcast signal function, and has unique advantages in the automatic line and the table body check of the electric energy meter; the connection speed of low time delay, the bluetooth of low energy supports equipment connection setting and data transmission of millisecond level, and the scene is worked simultaneously to many electric energy meters very much to be fit for, and classic bluetooth is restricted by the agreement, and the connection time needs the second level above.
Drawings
Fig. 1 is a block diagram of an embodiment of a bluetooth module according to the present invention.
FIG. 2 is a block diagram of an embodiment of an SOC implementation of the present invention.
Fig. 3 is a flowchart of a bluetooth power-on method of the present invention.
Figure 4 is a flow diagram of intelligent micro-broken BLE multi-connection management in the present invention.
Figure 5 is a flow chart of intelligent micro-break BLE data interaction in the present invention.
FIG. 6 is a flow chart of the slave device data interaction of the present invention.
Detailed Description
The invention is further described below with reference to the figures and the specific embodiments of the description.
The composition and practice of the bluetooth system will now be explained:
the existing bluetooth system composition technology mainly comprises a bottom hardware module, a middle protocol layer, a high-level application and the like, which are respectively introduced as follows:
a. bottom hardware module
The underlying hardware modules in a bluetooth technology system are managed by baseband, frequency hopping, and links. Wherein, the baseband completes the transmission of Bluetooth data and frequency hopping; the wireless frequency hopping layer is microwave which does not need authorization and passes through the 2.4GHz ISM frequency band, data stream transmission and filtering are realized on the wireless frequency modulation layer, and conditions which are required to be met by the normal work of the Bluetooth transceiver in the frequency band are mainly defined; link management enables secure control of link establishment, connection and tear down.
b. Intermediate protocol layer
The intermediate protocol layer in the Bluetooth technology system mainly comprises four parts of a service discovery protocol, a logic link control and adaptation protocol, a telephone communication protocol and a serial port simulation protocol. Wherein the service discovery protocol layer is used for providing a mechanism for an upper layer application program to facilitate the use of the service in the network; the logical link control and adaptation protocol is responsible for data disassembly and assembly, multiplexing protocol and controlling service quality, and is the basis for realizing the functions of other protocol layers.
c. High level applications
In a bluetooth technology composition system, the higher layer application is the part of the framework that is located at the top of the protocol layer. The high-level application of the Bluetooth technology mainly comprises file transmission, network and local area network access. The heterogeneous high-level applications are a kind of wireless communication realized by a certain application mode through a corresponding application program.
The current practice of bluetooth technology is based on the following:
(1) bluetooth-name, MAC address, broadcasting function and registration cost of intelligent miniature circuit breaker
The Bluetooth name is a name of a specific Bluetooth device of Bluetooth, and is scanned and displayed from a mobile phone at ordinary times and is used for auxiliary device management. In the electric energy meter Bluetooth scheme, after power is on, the electric energy meter MCU actively modifies the Bluetooth name into an electric energy meter communication address (through serial port communication, similar to modifying a carrier module communication address). The Bluetooth MAC address is very important in Bluetooth communication, the Bluetooth communication depends on the MAC address, and the host can be quickly connected with Bluetooth equipment (millisecond level) on the premise of knowing the Bluetooth MAC address.
The low power consumption Bluetooth has an automatic information broadcasting function in a slave mode, and the host can distinguish the Bluetooth name and the MAC address according to the received slave broadcasting information. In general, after the slave is powered on and reset, the broadcast bluetooth name and MAC information are sent out in a 20ms cycle within 30 seconds (a longer time max can be set to 2600 seconds), and after 30 seconds, the broadcast is sent out every 645ms to reduce power consumption.
The bluetooth device performs one scan in 10ms in the master mode to receive broadcast information of the slave.
Considering that the low-power-consumption Bluetooth only has 3 broadcast channels, if the number of Bluetooth in the range is large, the problem of mutual signal interference exists, which means that for the electric energy meter, because the Bluetooth is based on local communication, it is necessary to control the transmission power of the Bluetooth, and the Bluetooth signal range cannot be too large, so that the interference to people is prevented, and the channel congestion is prevented, so that the communication efficiency is influenced.
By adopting the broadcasting function, the host can automatically scan out the Bluetooth MAC address of the electric energy meter on the premise of knowing the communication address of the electric energy meter, so that connection and data communication are carried out.
In the design of the Bluetooth scheme of the electric energy meter, a Bluetooth module in the electric energy meter is called as a slave, and Bluetooth modules of a table body, an automatic line, a palm machine, a collector and the like are called as a host. In an application scenario, after the host acquires the MAC addresses of the slaves (through file reading, manual input or broadcast scanning), connection is established, and then one-to-one communication is performed, and the host does not establish connection with a plurality of slaves at the same time.
(2) Intelligent micro circuit breaker application Bluetooth-compatibility
Bluetooth low energy technology can in turn build two types of devices: a dual mode device BR/EDR (Basic Rate/Enhanced Data Rate) and a single mode device BLE (Bluetooth Low energy). The BR/EDR is basic rate communication, is downward compatible with a traditional Bluetooth 3.0 and below version, and is suitable for equipment (such as a Bluetooth headset) receiving a large amount of data. BLE appears in the bluetooth 4.0 protocol, is mainly used to implement continuous connection between a mobile terminal module and peripheral accessories, and is a short-range wireless communication technology with extremely low power consumption.
The dual mode device supports both classic bluetooth and bluetooth low energy. Single mode devices only support bluetooth low energy. There is certainly a third type-only classic bluetooth enabled devices, typical dual mode devices are smartphones, tablets, PCs, etc., and the protocol interoperability is as follows:
TABLE 1 compatibility of Single mode, Dual mode and classic Bluetooth
Single mode bluetooth Dual-mode Bluetooth Classic Bluetooth
Single mode bluetooth Interworking, low power Bluetooth protocol Interworking, low power Bluetooth protocol Do not intercommunicate
Dual-mode Bluetooth Interworking, low power Bluetooth protocol Interworking, dual protocol Interworking, classic Bluetooth protocol
Classic Bluetooth Do not intercommunicate Interworking, classic Bluetooth protocol Interworking, classic Bluetooth protocol
In the invention, the scheme of low-power consumption Bluetooth is definitely selected for the electric energy meter, and in the application scene of the electric energy meter, besides electric power equipment such as the electric energy meter, a platform body and a collector, the electric energy meter is very necessary to support other equipment such as a mobile phone and a tablet personal computer, because the diversity of application modes can be mined from a demand level.
As can be seen from table 1, the electric energy meter uses a single-mode bluetooth with low power consumption, and no problem exists in the compatibility on the premise of ensuring that the master and slave devices all use V4.0 and subsequent versions.
As shown in fig. 1 and fig. 2, the intelligent electric energy meter system based on bluetooth communication of the present embodiment includes an electric energy meter, an intelligent miniature circuit breaker, a terminal module and a bluetooth module; the Bluetooth module adopts a Bluetooth module or an SOC (system on chip), wherein the SOC is an integrated Bluetooth protocol stack of the electric energy meter; when the Bluetooth module is adopted, the Bluetooth module comprises a first Bluetooth module and a second Bluetooth module, and the electric energy meter is connected with the intelligent miniature circuit breaker and the slave equipment through the first Bluetooth module; the electric energy meter is connected with the terminal module sequentially through the first Bluetooth module and the second Bluetooth module; when the SOC mode is adopted, the electric energy meter is connected with the intelligent miniature circuit breaker, the slave and the terminal module through the integrated Bluetooth; when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with the intelligent miniature circuit breaker or other slave devices to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
In the embodiment, the low-power single-mode Bluetooth is used, so that the static and dynamic communication power consumption is very low; the Bluetooth with low power consumption has a newly added broadcast signal function, and has unique advantages in the automatic line and the table body check of the electric energy meter; the connection speed of low time delay, the bluetooth of low energy supports equipment connection setting and data transmission of millisecond level, and the scene is worked simultaneously to many electric energy meters very much to be fit for, and classic bluetooth is restricted by the agreement, and the connection time needs the second level above.
The invention also correspondingly discloses a communication method of the intelligent electric energy meter system based on the Bluetooth communication, which comprises two modes of a Bluetooth module or an SOC, wherein when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with an intelligent miniature circuit breaker or other slave equipment to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
Specifically, in a bluetooth communication scenario, two roles of a master and a slave are defined, the master initiates data connection actively, the slave responds to establish connection, the bluetooth supports a master-slave coexistence mode, the master may be a collector, a platform automation line, a handheld device and an electric energy meter, the slave may be an electric energy meter, an external load intelligent miniature circuit breaker and the like, and a typical network topology thereof is shown in fig. 1 and fig. 2. The intelligent micro-breaker and related equipment use two modes of a Bluetooth module and an SOC (system on chip) by using Bluetooth, wherein the SOC mode is that a Bluetooth protocol stack is integrated by a main MCU of the electric energy meter, and the application block diagram of the Bluetooth module is shown in figure 1; the Bluetooth SOC application block diagram is shown in figure 2; in various application scenes, the Bluetooth of the electric energy meter works in a master multi-slave mode and is used as a host, and the electric energy meter actively initiates data connection with intelligent micro-disconnection or other slave equipment to carry out Bluetooth communication; as a slave, the electric energy meter receives a connection request from the platform body, the automatic line and the handheld device/APP to carry out Bluetooth communication.
As shown in fig. 3, in this embodiment, the intelligent micro-broken bluetooth module sends a command requesting to configure system parameters to the electric energy meter, and the electric energy meter returns the system parameters to the bluetooth module after receiving the request command; the system parameters comprise local MAC addresses, a list of 3 slave MAC addresses and Bluetooth names;
the Bluetooth module configures the MAC address and the Bluetooth name (equipment name) of the Bluetooth module according to the system parameters;
the Bluetooth module starts broadcasting, waits to be connected by the host, and simultaneously establishes connection with the slave according to communication requirements according to the legality of the MAC address list of the slave.
Note: the slave machine may be a periodic wake-up working mechanism, and the electric energy meter bluetooth module should start broadcast listening, and if the existence of the slave machine cannot be confirmed, an error should be reported or reported.
In this embodiment, the bluetooth intelligent micro-breaker (intelligent micro-breaker, or load switch) connection security policy based on the fee control mode is further included, and the policy includes the following aspects:
a. reading data: the host computer needs to carry out Bluetooth authentication before the operation of the electric energy meter through Bluetooth and opens the operation authority. The authentication is not passed, only the table number, the communication address, the record number, the current date, the current time, the current electric energy and the current remaining amount can be read out, and other information is not allowed to be read out.
b. Writing data: the host computer needs to carry out Bluetooth authentication before writing operation on the electric energy meter through Bluetooth, the authentication does not pass, all information is not allowed to be set, and only a Bluetooth authentication command is supported.
c. The electric energy meter and the external switch are in data interaction: the electric energy meter and the switch are uniquely corresponding, the electric energy meter can not operate other switches, and the switch also does not allow other electric energy meters to control. The electric energy meter has different reading or writing authorities to the switch, the read data can be confirmed, and switch-on or switch-off or writing parameters need to be authenticated.
The Bluetooth of the electric energy meter is powered on and always kept in a working state, the Bluetooth of the switch is in a periodic awakening mode (meeting the power consumption requirement of the switch), and the default time is generally 2 seconds.
After the switch is awakened by the Bluetooth, the connection with the electric energy meter is successfully established, and if the random number password confirmation or the identity authentication of the operation switch of the electric energy meter is not received within 1 second, the connection is automatically disconnected so as to prevent the vicious connection of an attacker.
d. Matching of the electric energy meter and the intelligent micro-breaking:
the master station or the handheld device completes identity authentication with the electric energy meter;
the Bluetooth MAC address of the switch is set in the electric energy meter through two types of parameters (ciphertext + MAC), the electric energy meter establishes data connection with the switch according to the Bluetooth MAC address of the switch, and meanwhile, the switch asset number is written into an ESAM file of the electric energy meter through one type of parameter (plaintext + MAC);
the ESAM of the electric energy meter discretely generates various keys for controlling the switch by utilizing the switch asset number, and the safety between the electric energy meter and the switch is ensured by the keys.
Note: before the load switch is installed, a discrete key is installed according to the switch asset number.
e. Intelligent micro-breaking identity authentication and random password production
After the electric energy meter is electrified, communication connection is established with the switch by matching the MAC address;
switch identity authentication: the switch identity authentication is in a remote identity authentication process in Q/GDW 365-2013 technical Specification for information exchange and safety authentication of intelligent electric energy meters;
after the switch identity authentication is passed, returning 4-byte random numbers as random passwords;
after the switch passes the identity authentication, the switch enters an identity authentication state, parameter modification and switching-on and switching-off operations can be carried out, and otherwise, an error is returned.
Note: the switch identity authentication process is used for authentication before switching on and switching off or writing operation, and data reading is not needed.
Note: the random password is used for data reading confirmation of the electric energy meter and the switch, and is also used for an attacker to fake the Bluetooth MAC of the electric energy meter and frequently establish illegal connection with the switch.
f. Intelligent micro-breaking data read by electric energy meter
The electric energy meter is connected with the switch through the MAC address;
the electric energy meter sends a random password to the switch, after the switch confirms the random password, the read authority is opened, and the electric energy meter can start to read the switch data;
and after the data is read, the electric energy meter is disconnected, if the switch does not have any data frame communication within 60 seconds, the connection is actively disconnected (note: the authority of the switch identity authentication process is higher than that of random password confirmation, and if the switch is in an authentication state, the read authority is directly opened).
g. Electric energy meter control switch
The master station or the handheld device completes identity authentication with the electric energy meter and issues a remote switch opening and closing command to the electric energy meter;
after the electric energy meter correctly analyzes the ciphertext, the electric energy meter and the switch perform switch identity authentication, and the electric energy meter directly exits after failure;
after the switch identity authentication is passed, the write operation is opened, and the electric energy meter can remotely open and close the switch or write parameters to the switch by ciphertext (note: the plaintext safety of the Bluetooth connection state is ensured by the encryption of a Bluetooth link layer AES128, and the switch in the connection state can not be scanned by other Bluetooth equipment hosts and is in a hidden state);
and after the switch is switched on or the data is written, the electric energy meter is disconnected, and if the switch does not have any data frame communication within 60 seconds, the switch is actively disconnected.
In this embodiment, the electric energy meter has 3 operating states, which are respectively: broadcast state, standby state, connected state.
When the electric energy meter is in a broadcast state, the electric energy meter stands by for 0.02 to 10.24 seconds after sending broadcast each time, a random delay of 0 to 10ms is generated before broadcast each time, and the delay is added in the broadcast so as to avoid data collision caused by simultaneous broadcast of a plurality of electric energy meters. And the broadcast electric energy meter respectively transmits broadcast data in each channel every time. After the electric energy meter sends the broadcast data, waiting for the acquisition equipment to initiate a scanning request;
when the electric energy meter is in a connection state and does not need to be connected with a terminal module (such as acquisition equipment), the electric energy meter is actively disconnected and enters a standby state. If the electric energy meter is in a connection state and no data is transmitted for more than 5 seconds, the electric energy meter is actively disconnected and enters a standby state. When the connection is broken due to a loss of connection, the power meter attempts to reconnect the harvesting device. The power meter is not connected with any acquisition equipment for more than 30 seconds, and the power meter automatically enters a standby state in order to reduce the power consumption of the power meter;
when the electric energy meter is in a standby state and connection requests sent by the acquisition equipment are tried to be connected with the electric energy meter, the electric energy meter is tried to be connected with the acquisition equipment within the first 10 seconds, whether the acquisition equipment is in a white list or not is judged, if the acquisition equipment is in the white list, the acquisition equipment is connected with the acquisition equipment, the electric energy meter enters a connection state, the electric energy meter is slave equipment, and the acquisition equipment is master equipment; after more than 10 seconds, the electric energy meter tries to connect with any acquisition equipment, and the electric energy meter is allowed to connect with new acquisition equipment; if the connection is not successfully established within 30 seconds, the attempt of connection is stopped, and the electric energy meter is kept in a standby state "
In this first draft example, the connection process of electric energy meter and collection equipment does: the electric energy meter works in a peripheral equipment mode, and the acquisition equipment works in a central equipment mode. The electric energy meter sends broadcast, the acquisition equipment scans the electric energy meter which is sending the broadcast, and after the electric energy meter receives the scanning request of the acquisition equipment, the scanning response data is sent to the acquisition equipment. And after receiving the scanning response data, the acquisition equipment initiates a connection request.
In addition, the invention also relates to a Bluetooth-based intelligent micro-break reading/writing data, control and accurate automatic pairing technology, which comprises the following specific steps:
(1) intelligent micro-broken BLE multi-connection management
The intelligent micro-disconnection supports one master and multiple slaves, namely a multi-connection mode, and is required to simultaneously support the work of reading/writing data (as a slave), controlling slave equipment (as a master) and the like, and the multi-connection management flow is shown in fig. 6.
Note: after the electric energy meter is connected with the host, if no valid frame is received within 30 seconds, the electric energy meter is automatically disconnected, and if the electric energy meter is abnormally disconnected for 3 times continuously, the main connection equipment is listed in a blacklist for 5 minutes.
(2) Intelligent micro-break data flow direction control
After the intelligent micro-break establishes connection with other equipment, because of the condition of simultaneous connection with a plurality of equipment, when the intelligent micro-break receives data, the intelligent micro-break judges which equipment is sent from according to the content of the data; when the intelligent micro-interrupt needs to send data to a certain device, the direction of the Bluetooth data is controlled through CTRL0 and CTRL1 pins (see the recommended hardware interface in detail), and the format is as follows:
serial number CTRL0 (level) CTRL1 (level) Direction indicator
1 L L To the direction of the host
2 H L To the slave 1 direction (default load switch)
3 L H To the slave device 2
4 H H To the slave device 3
The intelligent micro-interrupt data interaction flow is shown in fig. 5.
(3) Slave device interaction flow
The slave device, typically a handheld terminal of a user, starts the broadcast function after being powered on, and waits to be connected by the intelligent micro-disconnection, as shown in fig. 6.
In this embodiment, the method for automatically pairing the bluetooth circuit breaker and the electric energy meter includes:
1) the Bluetooth circuit breaker generates an 8-bit random number as an automatic pairing feature code;
2) the Bluetooth circuit breaker modulates and sends the automatic matching feature codes to a cable line in a reactive current mode;
3) meanwhile, the Bluetooth circuit breaker sends the automatic pairing feature code by using Bluetooth broadcasting;
4) the method comprises the steps of checking a slave list after an electric energy meter is initialized, and initiating an automatic meter searching breaker when a breaker slave is detected not to be set; starting to sample and record current data, and demodulating the automatic matching feature code through an algorithm when the current data is sufficiently sampled;
5) the electric energy meter Bluetooth module scans Bluetooth broadcast, and when the Bluetooth scans that the automatic matching feature codes in one or more broadcast packets are consistent with the automatic matching feature codes on the cable, the Bluetooth breaker address is recorded; scanning for a certain time to obtain a Bluetooth breaker list which can be installed behind the electric energy meter, and connecting one of the Bluetooth breakers;
6) the electric energy meter generates an 8-bit random number as a new automatic pairing feature code and sends a command for changing the automatic pairing feature code to the Bluetooth circuit breaker;
7) after the Bluetooth circuit breaker receives the command, the data sent on the cable line is changed into a new automatic pairing feature code and the change of the electric energy meter is completed;
8) delaying for a short time after the electric energy meter receives the reply, sampling again and recording current data, and demodulating the automatic pairing feature code through an algorithm when the current data is sufficiently sampled;
9) and when the automatic pairing feature code obtained by demodulating the electric energy meter again is consistent with the new automatic pairing feature code, the circuit breaker can be confirmed to be a circuit breaker installed behind the electric energy meter. Storing the breaker address;
10) when the automatic matching feature code obtained by demodulating the electric energy meter again is inconsistent with the new automatic matching feature code, disconnecting the connected Bluetooth circuit breaker, deleting the address of the Bluetooth circuit breaker in the scanning list, setting and connecting the next Bluetooth circuit breaker, and turning to the step 6); and if the scanning list is empty, the circuit breaker after the automatic searching list is considered to be failed.
In this embodiment, the pairing data encoding method is as follows:
1) data rate: 60 ms/bit;
2) modulation mode: and modulating data by adopting an OOK mode. I.e., switched mode, with current high indicating data 0 and no current low indicating data 1;
3) data frame format: data idle bit, start bit, data bit, insertion bit, check bit and end bit;
4) idle bit: 6 bit 1, i.e. 360ms duration of no current time;
5) the initial position: 1 bit 0;
6) data bit/insertion bit: the low bit of the data is in front and the high bit is in back; one insertion bit is inserted into each 4-bit data, the height of the data bit is 1 and the height of the data bit is 0, the insertion bit is opposite to the previous data bit so as to ensure that the data does not have continuous 6-bit height or low, and in each edge, the data demodulation algorithm can be automatically calibrated all the time so as to ensure that the data does not misplace;
7) checking the bit: odd check, make data bit, insert bit, check bit keep odd number 1;
8) an end bit: 1 bit 0.
In other embodiments, the pairing method of bluetooth communication between the corresponding electric energy meter and the intelligent miniature circuit breaker may also include the following steps:
s01, acquiring bar codes and MAC addresses of the electric energy meter and the breaker from a database of a power company by adopting a terminal module, and storing the bar codes and the MAC addresses in the terminal module;
s02, scanning the bar code on the breaker by adopting a terminal module, and connecting the terminal module with the breaker by Bluetooth; acquiring a circuit breaker pairing code from a database according to the scanned bar code information and performing pairing connection;
after the pairing is successful, connection is established successfully, the terminal module obtains the Mac address of the electric energy meter from the database by scanning the bar code of the electric energy meter, a communication key is manually set, then the obtained Mac address of the electric energy meter and the communication key are issued to the circuit breaker, and after the issuing is successful, the connection is manually disconnected;
s03, the terminal module scans the bar code on the electric energy meter, and the terminal module is connected with the electric energy meter through Bluetooth; acquiring pairing codes of the electric energy meters from a database according to the scanned bar code information and carrying out pairing connection;
after the pairing is successful, connection is established successfully, the terminal module obtains the Mac address of the breaker from the database by scanning the bar code of the breaker, a communication key which is the same as the communication key in the step S2 is set manually, then the Mac address and the communication key of the breaker are issued to the electric energy meter, and after the issuing is successful, the connection is disconnected manually;
and S04, after the configuration of the circuit breaker and the electric energy meter is completed, the circuit breaker and the electric energy meter can be connected, the electric energy meter and the circuit breaker are identified through unique Mac addresses, a unique communication path is established, and the communication data are encrypted and decrypted through the key configured in the steps.
The electric energy meter and the circuit breaker are communicated in a unique communication mode through Bluetooth, the intelligent electric meter performs switching-on and switching-off operation on the paired electric meters through a Bluetooth channel, and necessary configuration needs to be performed on the electric energy meter and the circuit breaker before communication; after the circuit breaker and the meter end module are configured, the circuit breaker and the meter end module can be connected, a unique communication path is established between the electric energy meter and the circuit breaker through unique Mac identification, and communication data are encrypted and decrypted through a configured secret key.
The on-site pairing method applied to the Bluetooth communication between the electric energy meter and the breaker can simply and quickly complete on-site pairing between the electric energy meter and the breaker, so that the electric energy meter and the breaker can be correctly and effectively communicated, and the situation that the intelligent electric meter of the A family controls the breaker of the B family due to mismatching between the electric energy meter and the breaker on the site is avoided; wherein adopt bluetooth communication mode, with low costs, the simple operation, stability is high.
In this embodiment, the supporting design of intelligent ammeter includes:
1) the metering core samples and stores current effective value data with a certain length at regular time;
2) the metering core and the management core are added with data interfaces to transmit the streaming data;
3) the management core checks the slave list and sends a starting search table external circuit breaker;
4) the management core is added with a command response for searching the breaker outside the meter;
5) the Bluetooth module is added with a Bluetooth broadcast function of a scanning analytic circuit breaker.
In this embodiment, the automatic pairing process includes:
1) checking a slave list, and starting to sample current data when the slave of the Bluetooth circuit breaker is not set;
2) current data sampling requirements: sampling one data every 10ms at a sampling rate of 100 Hz; sampling depth 240, sampling time 2.4S; data type 16 bit unsigned integer, store according to the little end mode;
item Parameter(s) Description of the invention
Sampling rate 100Hz Sampling one data per 10ms
Depth of sampling 240 Sampling time 2.4S
Data type 16 bit unsigned integer Storage in small end mode
3) The electric energy meter management core sends a meter-searching starting circuit breaker instruction to the Bluetooth module;
4) waiting for the Bluetooth module to report a search result or require to re-sample current data;
5) the management core receives a resampling current instruction and begins resampling;
6) after sampling, sending a reply to the Bluetooth module;
7) and the Bluetooth module reports the searching result.
The following describes the automatic pairing communication between the MCU and the pairing module in conjunction with a specific embodiment:
data format: data-in consisting of multiple bytes is all in little-endian mode without special indication, i.e. low byte at low address and high byte at high address.
The default values of the serial port communication parameters are as follows: 38400bps, a 1-bit start bit, an 8-bit data bit, a 1-bit even parity bit, and a 1-bit stop bit.
The data response timeout time is not more than 500ms, and the data byte delay of each frame is not more than 500 ms.
(1) Data frame structure
Figure BDA0002754400260000181
The relevant description is as follows:
4 bytes of FE, which is used for awakening the serial port, has no other use, can be sent or not sent, and is not recommended to be used as the mark for judging the frame header; 68H: frame start character as data frame start identification; the length of the data is L1L2, namely data identification + data; M5-M0: the address of the target device, if cmd, must be full FF, and if not, is the Mac address of the target device, i.e. the device indicating that the frame data is to be sent to the specified MAC; c: control codes are used for explaining the functions of the frame data, such as 00H: transparent transmission, 01H: setting parameters of the module; 02H: reading the module parameters; D0-Dn: data CS: frame check code, 1 byte, using checksum mode, data from 1 st 68, adding up the sum of data before CS, and taking the lowest 1 byte, if the checksum is calculated to be 1F5H, taking F5 (CS is 1F5 h% 256); 16H, 16H: the end symbol indicates the end of 1 frame data.
(2) Description of pairing code
(a) The electric energy meter sends a breaker request frame after starting the automatic searching meter:
the functions are as follows: sending the collected current data, and starting a Bluetooth module to automatically search a circuit breaker behind the meter;
control code: 04;
data length: the L1L2 format is as follows:
68H L1L2 FFFFFFFFFFFF 00 00 68H 04 04 00 00 01 D0-Dn CS 16H
response frame:
68H L1L2 898989898989 00 00 68H 84 04 00 00 01 D0 CS 16H
starting an automatic circuit breaker searching process:
the data is current fingerprint data sampled by the electric energy meter; each sampling point data is 16-bit unsigned integer type, large-end mode and unit milliampere;
the current fingerprint algorithm can identify that the circuit breaker feature code returns to start successfully (00), and returns to start failure if the circuit breaker feature code is identified incorrectly (02).
(b) Bluetooth module requires resampling
The functions are as follows: the bluetooth module requires the current data to be re-sampled.
Control code: 04;
data length: the L1L2 format is as follows:
68H L1L2 898989898989 00 00 68H 84 04 00 00 02 D0~D1 CS 16H
response frame:
68H L1L2 FFFFFFFFFFFF 00 00 68H 04 04 00 00 02 D0~Dn CS 16H
starting current fingerprint data acquisition of the electric energy meter, wherein 2 bytes of data are sampling time, and the value is 0-65535, unit: 10 milliseconds. And returning the collected data after the time for collecting the data by the electric energy meter (the data format is the same as that of the circuit breaker 04000001 after starting the automatic meter searching).
(3) Bluetooth module reports circuit breaker success after automatic look-up table
The functions are as follows: the Bluetooth module reports the success of the breaker after the automatic searching table.
Control code: 84;
data length: the L1L2 format is as follows:
68H L1L2 898989898989 00 00 68H 84 04 00 00 03 D0~Dn CS 16H
automatic look for after-table circuit breaker result reporting
The search was successful: reporting the length of 7 bytes, and searching a result (00 success) +6 bytes of MAC address of the Bluetooth breaker;
failure of search: and reporting the length of 1 byte, and searching the result (01 fails).
The above is only a preferred embodiment of the present invention, and the protection scope of the present invention is not limited to the above-mentioned embodiments, and all technical solutions belonging to the idea of the present invention belong to the protection scope of the present invention. It should be noted that modifications and embellishments within the scope of the invention may be made by those skilled in the art without departing from the principle of the invention.

Claims (10)

1. An intelligent electric energy meter system based on Bluetooth communication is characterized by comprising an electric energy meter, an intelligent miniature circuit breaker, a terminal module and a Bluetooth module; the Bluetooth module adopts a Bluetooth module or an SOC (system on chip), wherein the SOC is an integrated Bluetooth protocol stack of the electric energy meter; when the Bluetooth module is adopted, the Bluetooth module comprises a first Bluetooth module and a second Bluetooth module, and the electric energy meter is connected with the intelligent miniature circuit breaker and the slave equipment through the first Bluetooth module; the electric energy meter is connected with the terminal module sequentially through the first Bluetooth module and the second Bluetooth module; when the SOC mode is adopted, the electric energy meter is connected with the intelligent miniature circuit breaker, the slave and the terminal module through the integrated Bluetooth; when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with the intelligent miniature circuit breaker or other slave devices to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
2. The intelligent electric energy meter system based on Bluetooth communication of claim 1, wherein the Bluetooth module is single mode Bluetooth Low energy and is version 4.0.
3. The communication method of the intelligent electric energy meter system based on the Bluetooth communication is characterized by comprising two modes of a Bluetooth module or an SOC (system on chip), wherein when the electric energy meter works in a master multi-slave mode, the electric energy meter is used as a host, and the electric energy meter actively initiates data connection with an intelligent miniature circuit breaker or other slave equipment to carry out Bluetooth communication; when the electric energy meter is used as a slave machine, the electric energy meter receives the connection request from the terminal module to carry out Bluetooth communication.
4. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 3, further comprising a connection method of the electric energy meter and the intelligent miniature circuit breaker based on the fee control mode, comprising reading data: the host computer needs to carry out Bluetooth authentication before the electric energy meter is operated through the Bluetooth module, and opens the operation authority, if the authentication is not passed, only the meter number, the communication address, the record number, the current date, the current time, the current electric energy and the current remaining amount can be read out, and other information is not allowed to be read out; writing data: the host computer needs to perform Bluetooth authentication before writing operation on the electric energy meter through the Bluetooth module, the authentication is not passed, all information is not allowed to be set, and only a Bluetooth authentication command is supported; the electric energy meter and the external intelligent miniature circuit breaker are in data interaction: the electric energy meter and the intelligent miniature circuit breaker are uniquely corresponding, the electric energy meter cannot operate other intelligent miniature circuit breakers, and the intelligent miniature circuit breaker cannot allow other electric energy meters to control; the electric energy meter has different read or write authorities to the intelligent miniature circuit breaker, and the read data can be confirmed, and the intelligent miniature circuit breaker identity authentication is needed when switching on or off or writing parameters; the Bluetooth of the electric energy meter is powered on and always keeps a working state, and the Bluetooth of the intelligent miniature circuit breaker is in a periodic awakening mode; the intelligent miniature circuit breaker is awakened by Bluetooth and then successfully connected with the electric energy meter, and if the random number password of the electric energy meter is not received for confirmation or the identity authentication of the intelligent miniature circuit breaker is not written, the connection is automatically disconnected within a preset time, so that an attacker is prevented from being maliciously connected.
5. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 4, further comprising a matching method of the electric energy meter and the intelligent miniature circuit breaker, wherein the matching method comprises the following steps:
the terminal module completes identity authentication with the electric energy meter;
the Bluetooth MAC address of the intelligent miniature circuit breaker is set into the electric energy meter through the second type of parameters, the electric energy meter establishes data connection with the intelligent miniature circuit breaker according to the Bluetooth MAC address of the intelligent miniature circuit breaker, and meanwhile, the asset number of the intelligent miniature circuit breaker is written into an ESAM file of the electric energy meter through the first type of parameters;
the electric energy meter ESAM discretely generates various keys for controlling the intelligent miniature circuit breaker by using the asset number of the intelligent miniature circuit breaker, and the safety between the electric energy meter and the intelligent miniature circuit breaker is ensured by the keys; before the intelligent miniature circuit breaker is installed, discrete keys are installed according to the asset number of the intelligent miniature circuit breaker.
6. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 5, wherein the procedures of the identity authentication of the intelligent miniature circuit breaker and the random password production are as follows:
after the electric energy meter is electrified, communication connection is established with the intelligent miniature circuit breaker by matching the MAC address;
the identity authentication of the intelligent miniature circuit breaker is carried out, and a returned random number is used as a random password after the identity authentication of the intelligent miniature circuit breaker is passed;
after passing the identity authentication, the intelligent miniature circuit breaker enters an identity authentication state, parameter modification and switching-on and switching-off operations can be carried out, and otherwise, an error is returned; the identity authentication process of the intelligent miniature circuit breaker is used for authentication before switching-on or writing operation, and data reading is not needed; the random password is used for data reading confirmation of the electric energy meter and the intelligent miniature circuit breaker, and is also used for an attacker to forge the Bluetooth MAC of the electric energy meter and frequently establish illegal connection with the intelligent miniature circuit breaker.
7. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 6, wherein the process of reading the data of the intelligent miniature circuit breaker by the electric energy meter comprises the following steps:
the electric energy meter is connected with the intelligent miniature circuit breaker through the MAC address;
the electric energy meter sends a random password to the intelligent miniature circuit breaker, after the intelligent miniature circuit breaker confirms the random password, the reading authority is opened, and the electric energy meter can start to read the data of the intelligent miniature circuit breaker;
after the data reading is finished, the electric energy meter is disconnected, and if no data frame communication exists in the preset time, the intelligent miniature circuit breaker is actively disconnected;
wherein the process of electric energy meter control intelligent miniature circuit breaker does:
the terminal module completes identity authentication with the electric energy meter and issues a remote switching-on/off command to the electric energy meter;
after the electric energy meter correctly analyzes the ciphertext, the electric energy meter and the intelligent miniature circuit breaker perform identity authentication, and the electric energy meter directly exits after failure;
after the identity authentication of the intelligent miniature circuit breaker is passed, the writing operation is opened, and the electric energy meter can remotely open and close the intelligent miniature circuit breaker or write parameters of the ciphertext;
and when the switch is switched on or the data writing is finished, the electric energy meter is disconnected, and if the intelligent miniature circuit breaker does not have any data frame communication within the preset time, the intelligent miniature circuit breaker actively disconnects.
8. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 7, wherein the electric energy meter has three working states, which are respectively: a broadcast state, a standby state, and a connection state;
when the electric energy meter is in a broadcast state, the electric energy meter waits for a period of time after sending broadcast each time, a random delay is generated before broadcasting each time and added in the broadcast, so that data collision caused by simultaneous broadcasting of a plurality of electric energy meters is avoided; the broadcasting electric energy meter respectively sends broadcasting data in different channels each time; after the electric energy meter sends the broadcast data, waiting for the terminal module to initiate a scanning request;
when the electric energy meter is in a connection state and does not need to be connected with the terminal module any more, the electric energy meter is actively disconnected and enters a standby state; if the electric energy meter is in a connection state and no data is transmitted for a period of time, the electric energy meter is actively disconnected and enters a standby state; when the connection is disconnected due to the loss of the connection, the electric energy meter tries to reconnect the terminal module, is not connected with any terminal equipment for a period of time, and automatically enters a standby state in order to reduce the power consumption of the electric energy meter;
when the electric energy meter is in a standby state and a terminal module sends a connection request to try to connect with the electric energy meter, the electric energy meter tries to connect with the terminal module for a period of time, whether the terminal module is in a white list or not is judged, if the terminal module is in the white list, the terminal module is connected with the terminal module, the electric energy meter enters a connection state, the electric energy meter is a slave machine, and the terminal module is a host machine; after a period of time, the electric energy meter attempts to connect with any terminal module and is allowed to connect with a new terminal module; if the connection is not successfully established for a period of time, the attempt to connect is stopped and the power meter remains in a "standby state".
9. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claim 8, wherein the connection process of the electric energy meter and the terminal module is as follows: the electric energy meter works in a peripheral equipment mode, and the terminal module works in a central equipment mode; the electric energy meter sends broadcast, the terminal module scans the electric energy meter which is sending broadcast, when the electric energy meter receives the scanning request of the terminal module, the terminal module sends scanning response data to the terminal module, and after the terminal module receives the scanning response data, the terminal module initiates a connection request.
10. The communication method of the intelligent electric energy meter system based on the Bluetooth communication as claimed in claims 3 to 9, wherein the electric energy meter and the intelligent miniature circuit breaker use Bluetooth as a unique communication mode, and the intelligent electric meters perform switching operation on the paired electric meters through a Bluetooth channel; the necessary configuration needs to be carried out on the two parties before communication; after the intelligent miniature circuit breaker and the electric energy meter are configured, the intelligent miniature circuit breaker and the electric energy meter can be connected, a unique communication path is established between the electric energy meter and the intelligent miniature circuit breaker through unique Mac identification, and communication data are encrypted and decrypted through a configured secret key.
CN202011197345.2A 2020-10-30 2020-10-30 Intelligent electric energy meter system based on Bluetooth communication and communication method thereof Pending CN112399394A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011197345.2A CN112399394A (en) 2020-10-30 2020-10-30 Intelligent electric energy meter system based on Bluetooth communication and communication method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011197345.2A CN112399394A (en) 2020-10-30 2020-10-30 Intelligent electric energy meter system based on Bluetooth communication and communication method thereof

Publications (1)

Publication Number Publication Date
CN112399394A true CN112399394A (en) 2021-02-23

Family

ID=74597785

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011197345.2A Pending CN112399394A (en) 2020-10-30 2020-10-30 Intelligent electric energy meter system based on Bluetooth communication and communication method thereof

Country Status (1)

Country Link
CN (1) CN112399394A (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113064115A (en) * 2021-04-27 2021-07-02 安徽南瑞中天电力电子有限公司 Electric energy meter calibration tool based on low-power-consumption Bluetooth communication and meter calibration method thereof
CN113129573A (en) * 2021-03-11 2021-07-16 科陆国际技术有限公司 Automatic connection method and system of electric energy meter and computer readable storage medium
CN113138335A (en) * 2021-04-16 2021-07-20 中国电力科学研究院有限公司 Method and system for detecting Bluetooth circuit breaker
CN113242126A (en) * 2021-06-09 2021-08-10 国网湖南省电力有限公司 Identity authentication-based pairing method and system for smart electric meter and Bluetooth circuit breaker
CN113784325A (en) * 2021-09-08 2021-12-10 宁波迦南智能电气股份有限公司 Electric energy meter and circuit breaker automatic pairing method based on power line carrier
CN114025337A (en) * 2021-10-19 2022-02-08 山东电工电气集团新能科技有限公司 Internet of things communication system based on Bluetooth communication and communication method thereof
CN114401503A (en) * 2022-01-17 2022-04-26 南方电网电力科技股份有限公司 Bluetooth meter checking connection method and related device for intelligent electric meter
CN114979830A (en) * 2022-05-19 2022-08-30 宁夏隆基宁光仪表股份有限公司 BLE-based intelligent water meter cluster data transmission method and system and control equipment
CN115002941A (en) * 2022-08-08 2022-09-02 浙江正泰仪器仪表有限责任公司 Communication method of Bluetooth electric energy meter
CN115915078A (en) * 2022-09-30 2023-04-04 国网冀北电力有限公司计量中心 Bluetooth communication electric energy meter safety communication authentication method based on 3DES
CN116321096A (en) * 2023-05-24 2023-06-23 深圳市拓普泰克技术股份有限公司 Automatic pairing method, device and equipment for wireless products
CN117222045A (en) * 2023-11-09 2023-12-12 广东浩宁达实业有限公司 Electric energy meter quick connection method based on Bluetooth communication technology
CN118301196A (en) * 2023-12-22 2024-07-05 浙江正泰仪器仪表有限责任公司 Relay control method, device, equipment and medium of multi-user electric energy meter

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015180111A (en) * 2015-06-29 2015-10-08 パナソニックIpマネジメント株式会社 Information terminal, communication device and distribution board
CN205484454U (en) * 2016-01-08 2016-08-17 辽宁北方节能股份有限公司 BLE bluetooth low -power consumption intelligent ammeter
CN107222831A (en) * 2017-05-05 2017-09-29 浙江大学 A kind of man-machine interaction type intelligent electric meter and management method based on bluetooth communication
CN208189020U (en) * 2018-05-17 2018-12-04 深圳市新越微电子有限公司 A kind of intelligent electric energy meter supplements repeating installation with money
CN110045166A (en) * 2019-04-10 2019-07-23 珠海优特电力科技股份有限公司 Ammeter, the control method of ammeter and readable storage medium storing program for executing
CN111372232A (en) * 2020-03-13 2020-07-03 国家电网有限公司 Method and system for first connection pairing of electric energy meter and Bluetooth circuit breaker
CN210924886U (en) * 2019-12-27 2020-07-03 广东电科院能源技术有限责任公司 Electric energy meter communication device
CN111479253A (en) * 2020-04-21 2020-07-31 山东卓文信息科技有限公司 Intelligent power distribution system based on Bluetooth networking communication and working method
CN111683356A (en) * 2020-05-20 2020-09-18 江苏林洋能源股份有限公司 Pairing method applied to Bluetooth communication between intelligent electric meter and circuit breaker
CN111796145A (en) * 2020-07-03 2020-10-20 山东德源电力科技股份有限公司 Method and system for communication and control of external circuit breaker of electric energy meter
CN111812402A (en) * 2020-06-29 2020-10-23 北京智芯微电子科技有限公司 Intelligent electric meter and automatic connection method of circuit breaker and intelligent electric meter

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2015180111A (en) * 2015-06-29 2015-10-08 パナソニックIpマネジメント株式会社 Information terminal, communication device and distribution board
CN205484454U (en) * 2016-01-08 2016-08-17 辽宁北方节能股份有限公司 BLE bluetooth low -power consumption intelligent ammeter
CN107222831A (en) * 2017-05-05 2017-09-29 浙江大学 A kind of man-machine interaction type intelligent electric meter and management method based on bluetooth communication
CN208189020U (en) * 2018-05-17 2018-12-04 深圳市新越微电子有限公司 A kind of intelligent electric energy meter supplements repeating installation with money
CN110045166A (en) * 2019-04-10 2019-07-23 珠海优特电力科技股份有限公司 Ammeter, the control method of ammeter and readable storage medium storing program for executing
CN210924886U (en) * 2019-12-27 2020-07-03 广东电科院能源技术有限责任公司 Electric energy meter communication device
CN111372232A (en) * 2020-03-13 2020-07-03 国家电网有限公司 Method and system for first connection pairing of electric energy meter and Bluetooth circuit breaker
CN111479253A (en) * 2020-04-21 2020-07-31 山东卓文信息科技有限公司 Intelligent power distribution system based on Bluetooth networking communication and working method
CN111683356A (en) * 2020-05-20 2020-09-18 江苏林洋能源股份有限公司 Pairing method applied to Bluetooth communication between intelligent electric meter and circuit breaker
CN111812402A (en) * 2020-06-29 2020-10-23 北京智芯微电子科技有限公司 Intelligent electric meter and automatic connection method of circuit breaker and intelligent electric meter
CN111796145A (en) * 2020-07-03 2020-10-20 山东德源电力科技股份有限公司 Method and system for communication and control of external circuit breaker of electric energy meter

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
崔海媛, 北京:海洋出版社 *

Cited By (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113129573A (en) * 2021-03-11 2021-07-16 科陆国际技术有限公司 Automatic connection method and system of electric energy meter and computer readable storage medium
CN113138335A (en) * 2021-04-16 2021-07-20 中国电力科学研究院有限公司 Method and system for detecting Bluetooth circuit breaker
CN113064115A (en) * 2021-04-27 2021-07-02 安徽南瑞中天电力电子有限公司 Electric energy meter calibration tool based on low-power-consumption Bluetooth communication and meter calibration method thereof
CN113064115B (en) * 2021-04-27 2024-06-04 安徽南瑞中天电力电子有限公司 Electric energy meter calibrating tool and method based on low-power consumption Bluetooth communication
CN113242126A (en) * 2021-06-09 2021-08-10 国网湖南省电力有限公司 Identity authentication-based pairing method and system for smart electric meter and Bluetooth circuit breaker
CN113242126B (en) * 2021-06-09 2022-06-21 国网湖南省电力有限公司 Identity authentication-based pairing method and system for smart electric meter and Bluetooth circuit breaker
CN113784325A (en) * 2021-09-08 2021-12-10 宁波迦南智能电气股份有限公司 Electric energy meter and circuit breaker automatic pairing method based on power line carrier
CN114025337A (en) * 2021-10-19 2022-02-08 山东电工电气集团新能科技有限公司 Internet of things communication system based on Bluetooth communication and communication method thereof
CN114401503B (en) * 2022-01-17 2024-01-09 南方电网电力科技股份有限公司 Bluetooth meter checking connection method and related device of intelligent electric meter
CN114401503A (en) * 2022-01-17 2022-04-26 南方电网电力科技股份有限公司 Bluetooth meter checking connection method and related device for intelligent electric meter
CN114979830A (en) * 2022-05-19 2022-08-30 宁夏隆基宁光仪表股份有限公司 BLE-based intelligent water meter cluster data transmission method and system and control equipment
CN115002941A (en) * 2022-08-08 2022-09-02 浙江正泰仪器仪表有限责任公司 Communication method of Bluetooth electric energy meter
CN115915078A (en) * 2022-09-30 2023-04-04 国网冀北电力有限公司计量中心 Bluetooth communication electric energy meter safety communication authentication method based on 3DES
CN116321096A (en) * 2023-05-24 2023-06-23 深圳市拓普泰克技术股份有限公司 Automatic pairing method, device and equipment for wireless products
CN116321096B (en) * 2023-05-24 2023-08-11 深圳市拓普泰克技术股份有限公司 Automatic pairing method, device and equipment for wireless products
CN117222045A (en) * 2023-11-09 2023-12-12 广东浩宁达实业有限公司 Electric energy meter quick connection method based on Bluetooth communication technology
CN117222045B (en) * 2023-11-09 2024-04-26 广东浩宁达实业有限公司 Electric energy meter quick connection method based on Bluetooth communication technology
CN118301196A (en) * 2023-12-22 2024-07-05 浙江正泰仪器仪表有限责任公司 Relay control method, device, equipment and medium of multi-user electric energy meter

Similar Documents

Publication Publication Date Title
CN112399394A (en) Intelligent electric energy meter system based on Bluetooth communication and communication method thereof
CN112399393A (en) Intelligent electric energy meter device and communication method thereof
CN113366439B (en) Method and device for connecting Bluetooth device
EP2355585B1 (en) Connecting wireless communications, wireless communications terminal and wireless communications system
CN101997575B (en) Short-range communication is used to carry out system, the method and apparatus of wireless network connection
CN101884178B (en) Method and system for communication in near field communication network
US20080089519A1 (en) Secure key exchange algorithm for wireless protocols
KR101257564B1 (en) Wireless usb device and wireless usb communication system
CN104050742A (en) Intelligent door and control method and system thereof
CN109688570A (en) Bluetooth connecting method, system and storage medium
CN110249608A (en) Device pairing
US20180159728A1 (en) Communication method for wi-fi internet of things equipment and wi-fi internet of things system
US20070287421A1 (en) Method and system for providing continuity of service with an existing communication network
CN103051504A (en) Electric appliance control method and electric appliance control system
JP2005117458A (en) Radio connection system, radio connection control method, access point device and communication equipment
CN103580844A (en) Mobile phone software and method for conducting full-duplex digital communication through peripheral based on standard Bluetooth headset jack
CN202551353U (en) Wireless unvarnished transmission terminal device and wireless system equipped therewith
CN208112977U (en) A kind of mobile SIM card pond and mobile SIM card cell system
CN113132997A (en) Communication method, device and system of intelligent household equipment
KR20100042679A (en) Method for remotely controlling a portable terminal and system therefor
KR100617132B1 (en) Mobile terminal and method for file sharing using thereof
CN211378259U (en) Intelligent household equipment and communication system thereof
CN105992202A (en) Method for communication through detection request frame embedded data under unrelated WIFI environment
Martelli Bluetooth low energy
CN105992209A (en) Method for communication through beacon frame embedded data under unrelated WIFI environment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20210223

WD01 Invention patent application deemed withdrawn after publication