CN107462148B - A kind of door state detection method and device - Google Patents

A kind of door state detection method and device Download PDF

Info

Publication number
CN107462148B
CN107462148B CN201710852526.6A CN201710852526A CN107462148B CN 107462148 B CN107462148 B CN 107462148B CN 201710852526 A CN201710852526 A CN 201710852526A CN 107462148 B CN107462148 B CN 107462148B
Authority
CN
China
Prior art keywords
door
magnetic vector
open angle
magnetic
vector
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.)
Active
Application number
CN201710852526.6A
Other languages
Chinese (zh)
Other versions
CN107462148A (en
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.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology 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 Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN201710852526.6A priority Critical patent/CN107462148B/en
Publication of CN107462148A publication Critical patent/CN107462148A/en
Application granted granted Critical
Publication of CN107462148B publication Critical patent/CN107462148B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B7/00Measuring arrangements characterised by the use of electric or magnetic techniques
    • G01B7/30Measuring arrangements characterised by the use of electric or magnetic techniques for measuring angles or tapers; for testing the alignment of axes

Abstract

The invention discloses the embodiment of the present invention to provide a kind of door state detection method and device, to improve the accuracy of door state testing result.This method comprises: obtaining the door that detects of first sensor in the first magnetic vector of current position;According to first magnetic vector and the corresponding relationship of open angle and magnetic vector, the open angle of the door is determined, wherein the open angle is the angle of position when the current location of the door is closed relative to the door;According to identified open angle, the current state of the door is determined.

Description

A kind of door state detection method and device
Technical field
The present invention relates to field of communication technology more particularly to a kind of door state detection method and device.
Background technique
Door is indispensable part in building, is worked with people's lives closely bound up, door state has become anti- The important parameter of the fire monitoring systems such as antitheft.The prior art mainly uses the state of following two method detection door:
One, the opening state and closed state of magnetic induction switch or photoelectric sensor detection door are utilized.But magnetic induction is opened It closes and photoelectric sensor needs to install in door and doorframe two parts, installation is inconvenient, and can only detect the opening and closing two of door Kind state, can not detect open angle.
Two, the angular acceleration and linear acceleration that door is obtained using six-axle acceleration sensor, by processor (Central Processing Unit, CPU) it calculates to obtain open angle according to the angular acceleration and linear acceleration of acquisition.Since six axis accelerate The discreteness of the angular acceleration that sensor obtains and linear acceleration is spent, CPU is by carrying out integral operation to the angular acceleration of acquisition When obtaining open angle, it may occur that calculated result drift causes testing result inaccurate, it is therefore desirable to often carry out calibrating multiple Position.
Summary of the invention
The embodiment of the present invention provides a kind of door state detection method and device, to improve the accurate of door state testing result Property.
Specific technical solution provided in an embodiment of the present invention is as follows:
In a first aspect, the embodiment of the invention provides a kind of door state detection methods, comprising:
First magnetic vector of the door that acquisition first sensor detects in current position;
According to first magnetic vector and the corresponding relationship of open angle and magnetic vector, the enabling of the door is determined Angle, wherein the open angle is the angle of position when the current location of the door is closed relative to the door;
According to identified open angle, the current state of the door is determined.
In possible embodiment, closed according to first magnetic vector and open angle are corresponding with magnetic vector System, determines the open angle of the door, comprising:
Open angle open angle corresponding with the second magnetic vector in the corresponding relationship of magnetic vector is determined as The open angle of the door, wherein second magnetic vector is big with first magnetic vector in the corresponding relationship The smallest magnetic vector of small difference;Alternatively,
Obtain the difference in the open angle and the corresponding relationship of magnetic vector with the size of first magnetic vector In the smallest second magnetic vector and the open angle and the corresponding relationship of magnetic vector in addition to second magnetic vector With the smallest third magnetic vector of difference of the size of first magnetic vector;According to first magnetic vector, described Two magnetic vectors, the third magnetic vector, the corresponding open angle of second magnetic vector and third magnetic field arrow Corresponding open angle is measured, the open angle of the door is calculated.
In possible embodiment, sweared according to first magnetic vector, second magnetic vector, the third magnetic field Amount, the corresponding open angle of second magnetic vector and to the corresponding open angle of the third magnetic vector, calculate institute State the open angle of door, comprising:
The open angle of the door is calculated according to the following formula:
Wherein, X is the open angle for the door being calculated,For first magnetic vector,It is described second Magnetic vector,For the third magnetic vector, X1For the corresponding open angle of second magnetic vector, X2For the third The corresponding open angle of magnetic vector.
In possible embodiment, the method also includes: the door motion profile that acquisition second sensor detects Acceleration in tangential direction;
According to identified open angle, the current state of the door is determined, comprising:
If the open angle of the door is less than the first setting value, and the acceleration in the door motion profile tangential direction is big In the second setting value, it is determined that the door is in close state;Or, however, it is determined that open angle less than the first setting value, and Acceleration in the door motion profile tangential direction is less than third setting value, it is determined that the door is in close state;
If the open angle of the door is greater than or equal to first setting value, it is determined that the door is in the open state.
In possible embodiment, closed according to first magnetic vector and open angle are corresponding with magnetic vector System, before determining open angle, the method also includes:
For each setting position of the door in multiple setting positions, the door that 3rd sensor detects is obtained It is sweared in the door that the angular speed of the setting position and the first sensor detect in the magnetic field of the setting position Amount, and the corresponding open angle in the setting position is calculated according to the angular speed of the setting position;
It is corresponding multiple according to the corresponding multiple open angles in the multiple setting position and the multiple setting position Magnetic vector establishes the corresponding relationship of the open angle and magnetic vector.
In possible embodiment, the door that detects of first sensor is obtained in the first magnetic vector of current position, Include:
Every first magnetic vector of the door that setting duration acquisition first sensor detects in current position;Alternatively, When determining that the position of the door changes, obtains the door that first sensor detects and sweared in the first magnetic field of current position Amount.
In possible embodiment, the method also includes: by the current shape of the open angle of the door and/or the door The equipment that state is sent to the state for monitoring the door.
Second aspect, the embodiment of the invention provides a kind of door state detection devices, comprising:
Module is obtained, for obtaining door that first sensor detects in the first magnetic vector of current position;
Determining module, for the corresponding relationship according to first magnetic vector and open angle and magnetic vector, really The open angle of the fixed door, and according to identified open angle, determine the current state of the door, wherein described to open Door angle is the angle of position when the current location of the door is closed relative to the door.
In possible embodiment, the determining module is specifically used for: the open angle is corresponding with magnetic vector The corresponding open angle of the second magnetic vector is determined as the open angle of the door in relationship, wherein second magnetic vector For the smallest magnetic vector of difference in the corresponding relationship with the size of first magnetic vector;Alternatively,
The acquisition module is also used to: obtain in the open angle and the corresponding relationship of magnetic vector with first magnetic It is removed in the smallest second magnetic vector of the difference of the size of field vector and the open angle and the corresponding relationship of magnetic vector The outer the smallest third magnetic vector of difference with the size of first magnetic vector of second magnetic vector;The determining mould Block is specifically used for: first magnetic vector, second magnetic vector, the third got according to the acquisition module Magnetic vector, the corresponding open angle of second magnetic vector and the corresponding open angle of the third magnetic vector, meter Calculate the open angle of the door.
In possible embodiment, the determining module is specifically used for: obtaining second magnetic field in the acquisition module After vector and the third magnetic vector, the open angle of the door is calculated according to the following formula:
Wherein, X is the open angle for the door being calculated,For first magnetic vector,It is described second Magnetic vector,For the third magnetic vector, X1For the corresponding open angle of second magnetic vector, X2For the third The corresponding open angle of magnetic vector.
In possible embodiment, the module that obtains is also used to: obtaining the door movement that second sensor detects Acceleration on orbit tangent direction;
The determining module is specifically used for: if the open angle of the door, less than the first setting value, and the door moves rail Acceleration in mark tangential direction is greater than the second setting value, it is determined that the door is in close state;Or, however, it is determined that enabling Angle is less than the first setting value, and the acceleration in the door motion profile tangential direction is less than third setting value, it is determined that institute Door is stated to be in close state;If the open angle of the door is greater than or equal to first setting value, it is determined that the door is in Opening state.
In possible embodiment, in the determining module according to first magnetic vector and open angle and magnetic field The corresponding relationship of vector, before determining open angle, the acquisition module is also used to:
For each setting position of the door in multiple setting positions, the door that 3rd sensor detects is obtained It is sweared in the door that the angular speed of the setting position and the first sensor detect in the magnetic field of the setting position Amount;
The determining module is also used to: for each setting position of the door in multiple setting positions, being set according to this The angular speed at the positioning place of setting calculates the corresponding open angle in the setting position;It multiple is opened according to the multiple setting position is corresponding Door angle and the corresponding multiple magnetic vectors in the multiple setting position, it is corresponding with magnetic vector to establish the open angle Relationship.
In possible embodiment, the acquisition module is specifically used for: obtaining first sensor detection every setting duration First magnetic vector of the door arrived in current position;Alternatively,
When determining that the position of the door changes, the door that acquisition first sensor detects is the first of current position Magnetic vector.
In possible embodiment, described device further include: sending module, for by the open angle of the door and/or The equipment that the current state of the door is sent to the state for monitoring the door.
Based on the above-mentioned technical proposal, in the embodiment of the present invention, door state detection device obtains what first sensor detected Door is closed in the first magnetic vector of current position according to first magnetic vector and open angle are corresponding with magnetic vector System, determines the open angle of the door, and according to identified open angle, determine the current state of the door, wherein should Open angle is the angle of position when the current location of door is closed relative to door.The embodiment of the present invention is according to the first magnetic field of acquisition The corresponding relationship of vector and open angle and magnetic vector determines the current open angle of door and state, does not need to carry out Integral operation, and earth magnetic field has continuous consistency within the scope of certain space, door state testing result is more accurate, does not need It continually carries out calibration and resets operation.
Detailed description of the invention
Fig. 1 is a kind of structural schematic diagram of door state detection device provided in an embodiment of the present invention;
Fig. 2 is a kind of flow diagram of door state detection method provided in an embodiment of the present invention;
Fig. 3 is rectangular coordinate system in space schematic diagram where door in the embodiment of the present invention;
Fig. 4 is the concrete structure schematic diagram of door state detection device in the embodiment of the present invention.
Specific embodiment
To make the objectives, technical solutions, and advantages of the present invention clearer, below in conjunction with attached drawing to the present invention make into One step it is described in detail.
Door refers to the door to be moved in a circle around door-hinge to realize open and close function, the first sensing in the embodiment of the present invention Magnetic vector in the corresponding relationship of magnetic vector and open angle and magnetic vector that device detects is door position Earth magnetic field.
As shown in Figure 1, a kind of door state detection device 100 provided in an embodiment of the present invention is including acquisition module 101 and really Cover half block 102.Wherein, module 101 is obtained, for obtaining door that first sensor detects in the first magnetic field of current position Vector;Determining module 102, the first magnetic vector and open angle and magnetic field for being got according to acquisition module 101 are sweared The corresponding relationship of amount determines the open angle of door, and according to identified open angle, determines the current state of this, In, which is the angle of position when the current location of door is closed relative to door.
In one specific embodiment, the function of obtaining module 101 and determining module 102 can be by CPU or micro-control Unit (Microcontroller Unit, MCU) processed is realized.
Fig. 2 schematically illustrates a kind of process of door state detection method provided in an embodiment of the present invention, and this method is Based on door state detection device 100 shown in FIG. 1 realize, the process the following steps are included:
Step 201: first magnetic vector of the door that acquisition first sensor detects in current position.
Specifically, the door that first sensor detects is obtained every setting duration to swear in the first magnetic field of current position Amount;Alternatively, the door that acquisition first sensor detects is the first of current position when determining that the position of the door changes Magnetic vector allows condition checkout gear 100 to power by battery to reduce the power consumption of door state detection device 100, peace Fill easy to use, construction cost is low.Wherein, step 201 is realized by the acquisition module 101 in door state detection device 100.
Step 202: according to the corresponding relationship of the first magnetic vector and open angle and magnetic vector that get, determining The open angle of this, wherein the open angle is the angle of position when the current location of the door is closed relative to the door. Step 202 can be realized by the determining module 102 of door state detection device 100.
Specifically, according to first magnetic vector and the corresponding relationship of the open angle and magnetic vector, door is determined Open angle, including but not limited to one of following two mode:
Mode one, by the difference in the open angle and the corresponding relationship of magnetic vector with the size of first magnetic vector The corresponding open angle of the smallest second magnetic vector is determined as the open angle of this, wherein second magnetic vector is to open The smallest magnetic vector of difference in the corresponding relationship of door angle and magnetic vector with the size of first magnetic vector.
Mode two obtains difference in the open angle and the corresponding relationship of magnetic vector with the size of the first magnetic vector In the smallest second magnetic vector and the open angle and the corresponding relationship of magnetic vector in addition to second magnetic vector with should The smallest third magnetic vector of the difference of the size of first magnetic vector;According to first magnetic vector, second magnetic vector, The third magnetic vector, the corresponding open angle of the second magnetic vector and to the corresponding enabling angle of the third magnetic vector Degree, calculates the open angle of door.Under normal conditions, the magnetic vector and first in open angle and the corresponding relationship of magnetic vector The size of magnetic vector is unequal, according to first magnetic vector, second magnetic vector, the third magnetic vector, this second The corresponding open angle of magnetic vector and the corresponding open angle of third magnetic vector, calculate the open angle of door, can Further increase the computational accuracy of open angle.Wherein, obtain the first magnetic vector, the second magnetic vector, third magnetic vector, The corresponding open angle of second magnetic vector and the corresponding open angle of third magnetic vector can be detected by door state The acquisition module 101 of device 100 is realized.
Specifically, when pass-through mode two determines the open angle of door, the enabling angle of this can be calculated according to the following formula Degree:
Wherein, X is the open angle being calculated,For first magnetic vector,For second magnetic vector, For the third magnetic vector, X1For the corresponding open angle of the second magnetic vector, X2For the corresponding enabling of third magnetic vector Angle.
Step 203: according to identified open angle, determining the current state of this.Wherein, step 203 can pass through The determining module 102 of door state detection device 100 is realized.
In implementation, the magnetic vector detected due to first sensor is there are error, during the open angle for determining door There is also errors, when door is in close state, identified open angle be not equal to zero, but one very close to zero value, because It is lower that this according only to identified open angle judges whether door is in close state accuracy.In order to improve door state detection knot The accuracy of fruit is sentenced on the basis of determining door current open angle in conjunction with the acceleration in door motion profile tangential direction Whether disconnected door is in close state, wherein when door becomes closed state from opening state, the door is in motion profile tangential direction On can generate a biggish acceleration, when door is also at closed state before the current detection moment, the door movement rail Acceleration in mark tangential direction is zero or close to zero.
Specifically, the acceleration in the door motion profile tangential direction that second sensor detects is obtained;If institute is really The open angle of fixed door is less than the first setting value, and the acceleration in the motion profile tangential direction of this is greater than the second setting When value, it is determined that the door is in close state, or, however, it is determined that open angle less than the first setting value, and the door is moving Acceleration on orbit tangent direction is less than third setting value, it is determined that the door is in close state;If the enabling angle of the door Degree is greater than or equal to first setting value, it is determined that the door is in the open state.Wherein, the first setting value and the second setting Value is based on experience value or simulation result determines.Wherein, the door motion profile tangent line side that second sensor detects is obtained Upward acceleration can be realized by the acquisition module 101 of door state detection device 100.
In implementation, according to first magnetic vector and the corresponding relationship of open angle and magnetic vector, determines and open the door Before angle, the corresponding relationship of open angle and magnetic vector is also established.In one specific embodiment, by with lower section Method establishes the corresponding relationship of open angle and magnetic vector: for each setting position of this in multiple setting positions, obtaining The door that this for taking 3rd sensor to detect detects in the angular speed and first sensor of the setting position is at this The magnetic vector of setting position, and the corresponding open angle in the setting position is calculated according to the angular speed of the setting position; According to the corresponding multiple magnetic vectors of the corresponding multiple open angles in multiple setting position and multiple setting position, establish The corresponding relationship of the open angle and magnetic vector.Wherein, the number of the setting position is more, the essence of identified open angle Degree is higher, but memory shared by open angle and the corresponding relationship of magnetic vector is larger, according to open angle and magnetic vector Corresponding relationship determine open angle process needed for the time it is longer, therefore, the number of the setting position needs to comprehensively consider door The hardware configuration of condition checkout gear 100 and the precision of open angle.Specifically, the door that 3rd sensor detects is obtained to exist This that the angular speed and first sensor of each setting position detect can in the magnetic vector of each setting position To realize by the acquisition module 101 of door state detection device 100, which is calculated according to the angular speed of each setting position The corresponding open angle in position and according to the corresponding magnetic of the corresponding open angle in each setting position and each setting position Field vector establishes the corresponding relationship of open angle and magnetic vector, can obtain determining module by door state detection device 100 102 realize.
It should be noted that the embodiment of the present invention is not to the corresponding relationship process for establishing open angle and magnetic vector In, it obtains door that the door that detects of 3rd sensor is detected in the angular speed and first sensor of setting position and sets at this The sequencing of magnetic vector for positioning the place of setting is defined, and can first obtain door in the angular speed of the setting position, can also First to obtain door in the magnetic vector of the setting position, or angular speed and magnetic field of the door in the setting position are obtained simultaneously Vector.
In one specific embodiment, in a space rectangular coordinate system, Z axis is door-hinge place for door institute as shown in Figure 3 Direction, X-axis and Y-axis composition plane be door motion profile where plane.First sensor at least detects door each When setting position, angular speed in X-direction and Y direction, 3rd sensor detects door at each setting position, X-axis side Earth magnetic field size in, Y direction and Z-direction, door state detection device 100 obtain each setting using integral operation The corresponding open angle in position, according to the corresponding open angle in each setting position being calculated and each setting position pair The earth magnetic field in X-direction, Y direction and Z-direction answered, establishes the corresponding relationship of open angle and magnetic vector.
In implementation, after determining the current open angle of door and state, by the current shape of identified open angle and/or door The equipment that state is sent to the state for monitoring the door.Wherein, the current state of identified open angle and/or door is sent out The process for giving the equipment of the state for monitoring door is realized by the sending module 103 of door state detection device 100.
Specifically, door state detection device 100 can pass through wired mode or wireless mode (such as bluetooth, infrared) transmission Identified open angle and/or the current state of door.For example, door state detection device 100 can by with for monitoring institute Low-power consumption bluetooth (Bluetooth Low Energy, the BLE) connection established between the equipment of the state of door is stated, it is identified to open Door angle and/or the current state of door.For another example, door state detection device 100 can be by itself input/output (input/ Output, I/O) the current state of identified door is sent to the equipment for the state for being used to monitor door to interface or door state detects Identified open angle is sent to the state for being used to monitor door by the serial line interface of itself by other modules of device 100 Equipment or door state detection device 100 other modules.
It should be noted that first sensor, second sensor and 3rd sensor can be distinguished in the embodiment of the present invention For the sensor for measuring door position earth magnetic field, for measure door position acceleration sensor and Sensor or first sensor, second sensor and 3rd sensor for measuring door position angular speed are energy Enough while measuring an integrated sensor in position earth magnetic field, acceleration and angular speed, such as nine axis gyroscopes.
Based on the above-mentioned technical proposal, in the embodiment of the present invention, door state detection device obtains what first sensor detected Door is closed in the first magnetic vector of current position according to first magnetic vector and open angle are corresponding with magnetic vector System, determines the open angle of the door, and according to identified open angle, determine the current state of the door, wherein should Open angle is the angle of position when the current location of door is closed relative to door.The embodiment of the present invention is according to the first magnetic field of acquisition The corresponding relationship of vector and open angle and magnetic vector determines the current open angle of door and state, does not need to carry out Integral operation, and earth magnetic field has continuous consistency within the scope of certain space, door state testing result is more accurate, does not need It continually carries out calibration and resets operation.
In one specific embodiment, the specific structure of door state detection device 100 is as shown in figure 4, include nine axis tops Spiral shell instrument 401, MCU 402, BLE Bluetooth chip 403 and power supply 404.Wherein, nine axis gyroscopes 401 are for measuring door in X-axis, Y-axis Model with angular speed, magnetic field strength and the acceleration in Z-direction, such as nine axis gyroscopes 401 can be MPU9250, Nine axis gyroscope of MPU9250 being capable of the above-mentioned 9 kinds of parameters of quick high accuracy acquisition;MCU 402 is surveyed for obtaining nine axis gyroscopes 401 The angular speed and magnetic field strength measured, the angular speed that is measured according to nine axis gyroscopes 401 calculate that door position is corresponding to open Door angle, establishes the corresponding relationship of open angle and magnetic vector, and the magnetic field strength measured according to nine axis gyroscopes 401 With the open angle of foundation and the corresponding relationship of magnetic vector, the current open angle of door is determined, and according to identified enabling Angle determines the current state of door, such as the model of MCU 402 can be EFM32ZG110F32, and EFM32ZG110F32 has Low-power consumption M0+ kernel, suspend mode operating current is very low, and the speed of service is fast after wake-up;BLE Bluetooth chip 403 is used for MCU 402 The current open angle of identified door and/or state are sent to the equipment for monitoring door state, example BLE Bluetooth chip 403 Can be CC2640, CC2640 be bluetooth SOC (System-on-a-Chip) chip with BLE protocol stack, can be realized with It bluetooth host and is connected with the long of mobile phone, interaction data;Power supply 404 is used to be nine axis gyroscopes 401, MCU 402 and BLE bluetooth Chip 403 is powered.
When MCU 402EFM32ZG110F32 enters EM2 suspend mode, operating current is about 2uA;Nine axis gyroscopes When 401MPU9250A suspend mode, operating current 8uA, BLE Bluetooth chip 403CC2640 is built as bluetooth slave with bluetooth host Founding after connecting average power consumption when not having data interaction is 10uA, so average power consumption is about when door state detection device suspend mode 20uA.If waking up within door state detection device every 1 second primary, reading current magnetic field intensity value after waking up, 2 milli of wakeup time Second, operating current is about 2mA.Average power consumption when door state detection device operates normally, which is calculated, according to above data is about 24uA, the electric current consumed when along with data interaction, average power consumption are about 30uA, and power consumption is lower, and power supply 404 can be electricity at this time Pond.Using common button cell CR2450 as example, the cell voltage 3V, capacity 550mAh, effective percentage are 70%, door state detection The apparatus module normal use time up to 535 days, fully meets the requirement of low-power consumption.
MCU 402 further includes I/O interface and serial line interface, wherein I/O interface is used for transmission the current state of door and (opens State or closed state) and the process for the corresponding relationship for establishing open angle and magnetic vector is controlled.Specifically, door Condition checkout gear 100 exports high level or low level by an output port in the I/O interface, detects to the door state The opening and closing two states of the external feedback door of device 100, wherein output port output high level indicates that door is currently located In opening state, output port output low level indicates that door is currently at closed state or the output port exports low electricity Flat to indicate that door is currently at opening state, output port output high level indicates that door is currently at closed state.Door state inspection Survey device 100 pass through by an input port in the I/O interface be set as high level enter establish open angle and magnetic field arrow The process of the corresponding relationship of amount, by the input port be set as low level exit establish open angle it is corresponding with magnetic vector close The process of system, or entered by setting low level for the input port and establish the corresponding relationship of open angle and magnetic vector Process, set high level for the input port and exit to establish the process of the corresponding relationship of open angle and magnetic vector.String Mouth is used for transmission the current open angle of door, at the same can also be arranged by serial port command enter and exit establish open angle with The process of the corresponding relationship of magnetic vector.
It should be understood by those skilled in the art that, the embodiment of the present invention can provide as method, system or computer program Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the present invention Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the present invention, which can be used in one or more, The shape for the computer program product implemented in usable storage medium (including but not limited to magnetic disk storage and optical memory etc.) Formula.
The present invention be referring to according to the method for the embodiment of the present invention, the process of equipment (system) and computer program product Figure and/or block diagram describe.It should be understood that every one stream in flowchart and/or the block diagram can be realized by computer program instructions The combination of process and/or box in journey and/or box and flowchart and/or the block diagram.It can provide these computer programs Instruct the processor of general purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce A raw machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for real The device for the function of being specified in present one or more flows of the flowchart and/or one or more blocks of the block diagram.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates, Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one The step of function of being specified in a box or multiple boxes.
Obviously, various changes and modifications can be made to the invention without departing from essence of the invention by those skilled in the art Mind and range.In this way, if these modifications and changes of the present invention belongs to the range of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to include these modifications and variations.

Claims (12)

1. a kind of door state detection method characterized by comprising
First magnetic vector of the door that acquisition first sensor detects in current position;
According to first magnetic vector and the corresponding relationship of open angle and magnetic vector, the enabling angle of the door is determined Degree, wherein the open angle is the angle of position when the current location of the door is closed relative to the door;
According to identified open angle, the current state of the door is determined;
Wherein, according to first magnetic vector and the corresponding relationship of open angle and magnetic vector, opening for the door is determined Door angle, comprising:
It obtains minimum with the difference of the size of first magnetic vector in the open angle and the corresponding relationship of magnetic vector The second magnetic vector and the open angle and the corresponding relationship of magnetic vector in addition to second magnetic vector and institute State the smallest third magnetic vector of difference of the size of the first magnetic vector;According to first magnetic vector, second magnetic Field vector, the third magnetic vector, the corresponding open angle of second magnetic vector and the third magnetic vector pair The open angle answered calculates the open angle of the door.
2. the method as described in claim 1, which is characterized in that according to first magnetic vector, second magnetic vector, The third magnetic vector, the corresponding open angle of second magnetic vector and the corresponding enabling of the third magnetic vector Angle, comprising:
The open angle of the door is calculated according to the following formula:
Wherein, X is the open angle for the door being calculated,For first magnetic vector,For second magnetic field arrow Amount,For the third magnetic vector, X1For the corresponding open angle of second magnetic vector, X2For third magnetic field arrow Measure corresponding open angle.
3. the method as described in claim 1, which is characterized in that the method also includes:
Obtain the acceleration in the door motion profile tangential direction that second sensor detects;
According to identified open angle, the current state of the door is determined, comprising:
If the open angle of the door is less than the first setting value, and the acceleration in the door motion profile tangential direction is greater than the Two setting values, it is determined that the door is in close state;Or, however, it is determined that open angle less than the first setting value, and it is described Acceleration in door motion profile tangential direction is less than third setting value, it is determined that the door is in close state;
If the open angle of the door is greater than or equal to first setting value, it is determined that the door is in the open state.
4. the method according to claim 1, which is characterized in that according to first magnetic vector and enabling angle The corresponding relationship of degree and magnetic vector, before determining open angle, the method also includes:
For each setting position of the door in multiple setting positions, the door that acquisition 3rd sensor detects is at this The door that the angular speed of setting position and the first sensor detect the setting position magnetic vector, and The corresponding open angle in the setting position is calculated according to the angular speed of the setting position;
According to the corresponding multiple magnetic fields of the corresponding multiple open angles in the multiple setting position and the multiple setting position Vector establishes the corresponding relationship of the open angle and magnetic vector.
5. the method according to claim 1, which is characterized in that the door that acquisition first sensor detects is current The first magnetic vector at position, comprising:
Door that the first sensor detects is obtained in the first magnetic vector of current position every setting duration;Alternatively,
When determining that the position of the door changes, door that the first sensor detects is obtained the first of current position Magnetic vector.
6. the method according to claim 1, which is characterized in that the method also includes:
The current state of the open angle of the door and/or the door is sent to the equipment for being used to monitor the state of the door.
7. a kind of door state detection device characterized by comprising
Module is obtained, for obtaining door that first sensor detects in the first magnetic vector of current position;
Determining module determines institute for the corresponding relationship according to first magnetic vector and open angle and magnetic vector The open angle of door is stated, and according to identified open angle, determines the current state of the door, wherein the enabling angle Degree is the angle of position when the current location of the door is closed relative to the door;
Wherein, the acquisition module is also used to: being obtained in the open angle and the corresponding relationship of magnetic vector with described first In the smallest second magnetic vector of the difference of the size of magnetic vector and the open angle and the corresponding relationship of magnetic vector In addition to second magnetic vector with the smallest third magnetic vector of the difference of the size of first magnetic vector;The determination Module is specifically used for: first magnetic vector, second magnetic vector, described the got according to the acquisition module Three magnetic vectors, the corresponding open angle of second magnetic vector and the corresponding open angle of the third magnetic vector, Calculate the open angle of the door.
8. device as claimed in claim 7, which is characterized in that the determining module is specifically used for:
After the acquisition module obtains second magnetic vector and the third magnetic vector, count according to the following formula Calculate the open angle of the door:
Wherein, X is the open angle for the door being calculated,For first magnetic vector,For second magnetic field arrow Amount,For the third magnetic vector, X1For the corresponding open angle of second magnetic vector, X2For third magnetic field arrow Measure corresponding open angle.
9. device as claimed in claim 7, which is characterized in that the acquisition module is also used to:
Obtain the acceleration in the door motion profile tangential direction that second sensor detects;
The determining module is specifically used for:
If the open angle of the door is less than the first setting value, and the acceleration in the door motion profile tangential direction is greater than the Two setting values, it is determined that the door is in close state;Or, however, it is determined that open angle less than the first setting value, and it is described Acceleration in door motion profile tangential direction is less than third setting value, it is determined that the door is in close state;
If the open angle of the door is greater than or equal to first setting value, it is determined that the door is in the open state.
10. the device as described in claim 7-9 any one, which is characterized in that in the determining module according to described first The corresponding relationship of magnetic vector and open angle and magnetic vector, before determining open angle, the acquisition module is also used to:
For each setting position of the door in multiple setting positions, the door that acquisition 3rd sensor detects is at this Magnetic vector of the door that the angular speed of setting position and the first sensor detect in the setting position;
The determining module is also used to: for each setting position of the door in multiple setting positions, according to the setting position The angular speed at the place of setting calculates the corresponding open angle in the setting position;According to the corresponding multiple enabling angles in the multiple setting position Degree and the corresponding multiple magnetic vectors in the multiple setting position establish open angle pass corresponding with magnetic vector System.
11. the device as described in claim 7-9 any one, which is characterized in that the acquisition module is specifically used for:
Every first magnetic vector of the door that setting duration acquisition first sensor detects in current position;Alternatively,
When determining that the position of the door changes, the door that detects of first sensor is obtained in the first magnetic field of current position Vector.
12. the device as described in claim 7-9 any one, which is characterized in that further include:
Sending module is used to monitor the door for the current state of the open angle of the door and/or the door to be sent to State equipment.
CN201710852526.6A 2017-09-19 2017-09-19 A kind of door state detection method and device Active CN107462148B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710852526.6A CN107462148B (en) 2017-09-19 2017-09-19 A kind of door state detection method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710852526.6A CN107462148B (en) 2017-09-19 2017-09-19 A kind of door state detection method and device

Publications (2)

Publication Number Publication Date
CN107462148A CN107462148A (en) 2017-12-12
CN107462148B true CN107462148B (en) 2019-09-17

Family

ID=60551617

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710852526.6A Active CN107462148B (en) 2017-09-19 2017-09-19 A kind of door state detection method and device

Country Status (1)

Country Link
CN (1) CN107462148B (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107663974A (en) 2017-09-21 2018-02-06 云丁网络技术(北京)有限公司 A kind of automatic locking method of smart lock and smart lock
EP3543573A1 (en) * 2018-03-19 2019-09-25 Universiteit Antwerpen Monitoring an operating state of a valve
CN108678558B (en) * 2018-05-22 2020-06-19 深圳中泰智丰物联网科技有限公司 Door lock control method and door lock
US10755554B2 (en) 2018-09-28 2020-08-25 Nortek Security & Control Llc Vector magnetic tamper detection for sensors
CN109629914A (en) * 2018-11-23 2019-04-16 深圳市慧星辰科技有限公司 Earth induction door lock autocontrol method
CN111121705A (en) * 2019-05-07 2020-05-08 浙江利尔达客思智能科技有限公司 System and method for detecting door opening state based on six-axis detection
CN111735452A (en) * 2019-12-30 2020-10-02 江苏金陵智造研究院有限公司 Low-power consumption container door opening monitoring facilities based on little acceleration sensor
CN113390440B (en) * 2020-03-11 2023-10-20 深圳绿米联创科技有限公司 Method, device and storage medium for detecting position state of target object
CN113496560A (en) * 2020-03-21 2021-10-12 云丁网络技术(北京)有限公司 Intelligent lock control method and system
CN113465286B (en) * 2020-07-14 2022-12-20 青岛海信电子产业控股股份有限公司 Intelligent refrigerator, angle determination and food material identification method
CN114061437A (en) * 2020-07-31 2022-02-18 罗伯特·博世有限公司 Method and apparatus for detecting the condition of a door or window
CN112462089A (en) * 2020-12-08 2021-03-09 北京自如信息科技有限公司 Method and device for calibrating state of electronic door, electronic door and readable storage medium
GB2602002A (en) * 2020-12-11 2022-06-22 Insure Firetec Ltd Apparatus and a method for determining the position or state of a door

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101206549A (en) * 2006-12-20 2008-06-25 敦南科技股份有限公司 Motion detecting device and method capable of sensing rotating and incline change information
CN101722987A (en) * 2009-12-23 2010-06-09 奇瑞汽车股份有限公司 Detection device and detection method for automotive steering angle
CN101726242A (en) * 2009-12-25 2010-06-09 奇瑞汽车股份有限公司 Detection device and detection method for position of automotive rotary headlamp
CN105612565A (en) * 2013-10-07 2016-05-25 罗伯特·博世有限公司 Device and method for determining a state of an object which is to be monitored
CN105829832A (en) * 2013-10-23 2016-08-03 罗伯特·博世有限公司 Method and apparatus for determining an angle of rotation of an object about an axis of rotation
CN106711607A (en) * 2015-07-31 2017-05-24 中国电信股份有限公司 Remote measuring method and device for antenna azimuth angle and network management system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7280936B1 (en) * 2006-04-21 2007-10-09 Motorola, Inc. Method and system for personal inertial navigation measurements

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101206549A (en) * 2006-12-20 2008-06-25 敦南科技股份有限公司 Motion detecting device and method capable of sensing rotating and incline change information
CN101722987A (en) * 2009-12-23 2010-06-09 奇瑞汽车股份有限公司 Detection device and detection method for automotive steering angle
CN101726242A (en) * 2009-12-25 2010-06-09 奇瑞汽车股份有限公司 Detection device and detection method for position of automotive rotary headlamp
CN105612565A (en) * 2013-10-07 2016-05-25 罗伯特·博世有限公司 Device and method for determining a state of an object which is to be monitored
CN105829832A (en) * 2013-10-23 2016-08-03 罗伯特·博世有限公司 Method and apparatus for determining an angle of rotation of an object about an axis of rotation
CN106711607A (en) * 2015-07-31 2017-05-24 中国电信股份有限公司 Remote measuring method and device for antenna azimuth angle and network management system

Also Published As

Publication number Publication date
CN107462148A (en) 2017-12-12

Similar Documents

Publication Publication Date Title
CN107462148B (en) A kind of door state detection method and device
CN103933722B (en) A kind of dumb-bell motion detection apparatus and dumb-bell method for testing motion
CN102818913B (en) Detection device and detection method for hummotion information
US8441371B2 (en) Method and mechanism for assisted diagnosis and maintenance of health monitoring system
CN104697497B (en) A kind of digital obliquity sensor and its nonlinear temperature compensation method
CN104571605B (en) The control method and system of a kind of intelligent electronic device
CN103680063B (en) Based on mobile phone accelerometer and gyrostatic old person abnormal condition decision method
CN104697481A (en) Device and method for measuring suspension center displacement of pumping unit based on three-axis acceleration sensor
CN106610438B (en) A kind of falling from high altitude detection method based on 3-axis acceleration
CN104578411B (en) A kind of PMU data accesses the multi-source data safety check after AGC and failure locking method
CN106885566A (en) A kind of method of wearable motion sensor and its anti-magnetic interference
CN107055245A (en) A kind of elevator method of real-time and device
CN113137976B (en) Inertial navigation system positioning performance evaluation method, device, equipment and storage medium
CN202710598U (en) Human motion information detection device
CN108609449A (en) A kind of sensor-based intelligent elevator detector and detection method
CN107037235A (en) A kind of braking glide quantity flexible measurement method and measurement apparatus
CN111336985A (en) Monitoring method and device for goaf iron tower, storage medium and electronic equipment
CN102914414A (en) Vibration measuring instrument based on Android platform mobile phone and detection method thereof
CN106017429B (en) A kind of intelligent fish lead flow measurement method and its circuit based on 3 d pose
CN104655149A (en) Test system of inertial navigation system
CN103630125A (en) Electronic compass calibration reminding system based on gyroscope and realization method thereof
CN202533120U (en) Wide-range gas flowmeter integrating instrument
Gallano et al. Design and implementation of phasor measurement unit with IoT technology
CN209355948U (en) A kind of system improving test micro inertial measurement unit efficiency
CN107575211A (en) A kind of online calibration method of pump unit dynamometer

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
GR01 Patent grant
GR01 Patent grant