Summary of the invention
For above-mentioned technical problem, the object of the present invention is to provide a kind of mobile ancillary chamber inner position method and system based on intelligent mobile phone platform, it is while utilizing indoor radio signal, the mobile message of user is attached in position fixing process, positioning precision is high, worst error is little, can continue to provide accurate location in real-time position fixing process.
For reaching this object, the present invention by the following technical solutions:
An indoor orientation method is assisted in movement based on intelligent mobile phone platform, and it comprises the steps:
A, structure fingerprint database;
Determine place and the location reference point in indoor environment with logical implication;
Gather received signal strength (RSSI) value of each location reference point, it can be used as the RSSI fingerprint of location reference point;
By the positional information of described location reference point and the RSSI fingerprint corresponding with it stored in database, complete the structure of fingerprint database;
B, structure move database;
The RSSI fingerprint of user position is mated with RSSI fingerprint in described fingerprint database, according to matching result, obtains a location estimation;
Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user;
According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user;
In conjunction with described location estimation, described moving direction information and moving distance information are processed, and by result stored in database, complete the structure of move database: by the moving direction information in each timeslice between original position with end position with moving distance information with compared with the value of indoor environment map calculation, if difference exceedes set threshold value, then abandon the moving direction information in this timeslice and moving distance information, and average recorded information identical with end position for original position in each timeslice gathered for user's moving direction and displacement and standard deviation, stored in move database,
C, consumer positioning position;
Receive the Location Request that user sends, and gather the RSSI fingerprint of user position according to this Location Request;
Described RSSI fingerprint is mated with RSSI fingerprint in described fingerprint database, returns the set comprising fixed qty position candidate according to matching result;
Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user;
According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user;
According to the moving direction information of the data in described move database, user and the moving distance information of user, the position candidate comprised described in calculating in the set of fixed qty position candidate is the probability of user position, obtains user position.
Especially, in described step B, the RSSI fingerprint of user position is mated with RSSI fingerprint in described fingerprint database, specifically comprises:
The dissimilar degree of RSSI fingerprint in the RSSI fingerprint of user position and described fingerprint database is calculated according to formula (a), the minimum RSSI fingerprint of dissmilarity degree is matching result, and the position of its correspondence is then as a location estimation of user position;
Wherein, if the quantity of the WAP (wireless access point) (AP) in indoor whole region is n, n is positive integer, then the RSSI fingerprint of user position can be expressed as F=(f
1, f
2..., f
n), wherein f
irepresent from the RSSI fingerprint of i-th WAP (wireless access point), same, the arbitrary RSSI fingerprint in fingerprint database be F'=(f '
1, f '
2..., f '
n).
Especially, according to the change information of user's acceleration of accelerometer collection in mobile phone in described step B, obtain the moving distance information of user, specifically comprise:
According to the change information of user's acceleration that accelerometer in mobile phone gathers, calculate the walking step number of user, and calculate the step-length of user according to the height of user, gone out the moving distance information of user by described step number and step size computation.
Especially, described step C specifically comprises:
Receive the Location Request that user sends first time, the RSSI fingerprint of user position is gathered according to this Location Request, calculate the dissimilar degree of RSSI fingerprint in the RSSI fingerprint of this user position and described fingerprint database, return the set comprising fixed qty position candidate, and using the location estimation of position corresponding for RSSI fingerprint minimum for degree dissimilar in this set as user position;
In the next time interval, user moves to reposition, then gather the RSSI fingerprint of this reposition, calculate the average of the bearing data that digital compass gathers within the described time interval in mobile phone, obtain the moving direction information of user, according to the change information of user's acceleration that accelerometer in mobile phone gathers within the described time interval, obtain the moving distance information of user;
Calculate the dissimilar degree of RSSI fingerprint in the RSSI fingerprint of described reposition and described fingerprint database, obtain the set comprising fixed qty position candidate, and calculate by formula (b) probability that each position candidate is described reposition;
Wherein, suppose that location candidate set is L={l
1, l
2..., l
k, position candidate l
icorresponding dissimilar degree is m
i, F is the RSSI fingerprint of reposition, P (X=l
i| F) be reposition X be l
iprobability;
The moving direction information of described user and the moving distance information of user are modeled as Gaussian Profile, in move database, the average of user's moving direction and displacement and standard deviation are average and the standard deviation of Gaussian Profile, under the moving direction d calculating user within the described time interval according to formula (c) and displacement o condition, reposition X is l
iprobability;
Wherein, the direction d of given position i to j and distance o, definition 0-1 stochastic variable V
i,j, its value is that 1 and if only if that user through such direction d and distance o from i to j, thus can obtain P (V
i,j=1)=D
i,j(d, α) O
i,j(o, β); D
i,j(d, α) and O
i,j(o, β) is corresponding siding-to-siding block length is α and β Gaussian Profile discretization, and X' is described location estimation, and its value set is S={s
1, s
2..., s
k;
Formula (b) and formula (c) are processed, obtains and utilize the RSSI fingerprint of reposition, user's moving direction information and moving distance information assessment reposition X to be l simultaneously
ithe formula (d) of probability, and to calculate reposition X according to formula (d) be l
iprobability, obtain the positional information of described reposition;
Wherein, P (X=l
i| F) for reposition X be l
iprobability.
The invention also discloses a kind of movement based on intelligent mobile phone platform and assist indoor locating system, it comprises:
Fingerprint database construction unit, for gathering received signal strength (RSSI) value of each location reference point, it can be used as the RSSI fingerprint of location reference point, by the positional information of described location reference point and the RSSI fingerprint corresponding with it stored in database, complete the structure of fingerprint database;
Move database construction unit, for being mated with RSSI fingerprint in described fingerprint database by the RSSI fingerprint of user position, according to matching result, obtains a location estimation; Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user; According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user; And in conjunction with described location estimation, described moving direction information and moving distance information are processed, and by result stored in database, complete the structure of move database; Wherein, location estimation described in described combination to process with moving distance information described moving direction information and specifically comprises: by the moving direction information in each timeslice between original position with end position with moving distance information with compared with the value of indoor environment map calculation, if difference exceedes set threshold value, then abandon the moving direction information in this timeslice and moving distance information, and average recorded information identical with end position for original position in each timeslice gathered for user's moving direction and displacement and standard deviation, stored in move database;
Engine of positioning unit, for receiving the Location Request that user sends, mating the RSSI fingerprint of the user position of collection with RSSI fingerprint in described fingerprint database, returning the set comprising fixed qty position candidate according to matching result; Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user; According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user; And according to the moving direction information of the data in described move database, user and the moving distance information of user, the position candidate comprised described in calculating in the set of fixed qty position candidate is the probability of user position, obtain user position
The present invention is after receiving the Location Request that user sends, the RSSI fingerprint of user position will be gathered according to this Location Request, and described RSSI fingerprint is mated with RSSI fingerprint in described fingerprint database, the set comprising fixed qty position candidate is returned according to matching result.Then according to the moving direction information of the data in move database, user and the moving distance information of user, the position candidate comprised described in calculating in the set of fixed qty position candidate is the probability of user position, obtains user position.Compared with traditional indoor orientation method, the present invention is while utilizing indoor radio signal, and be attached in position fixing process by the mobile message of user, positioning precision is high, and worst error is little, can continue to provide accurate location in real-time position fixing process.
Embodiment
For making the object, technical solutions and advantages of the present invention clearly, below in conjunction with drawings and Examples, the invention will be further described.
Please refer to shown in Fig. 1, the mobile ancillary chamber inner position method flow diagram based on intelligent mobile phone platform that Fig. 1 provides for the embodiment of the present invention.
Indoor orientation method is assisted to comprise the steps: based on the movement of intelligent mobile phone platform in the present embodiment
Step S101, structure fingerprint database.Specific implementation process is as follows:
Step S1011, determine place and the location reference point in indoor environment with logical implication.
As shown in Figure 2, the location reference point that provides for the embodiment of the present invention of Fig. 2 and WAP (wireless access point) dispose situation schematic diagram.In figure, whole office hall size is 40.8 meters × 16 meters, wherein there are some support columns, baffle plate, office desk and chair etc., the location reference point that the circle of numbering 1 to 28 represents, asterisk represents the placement location of WAP (wireless access point).
Indoor environment is investigated, determines place and the location reference point with logical implication.In whole indoor plane region, (1 meter to 5 meters) is for determining location reference point in interval at a certain distance.The selection of these location reference point can be turning, corridor, have the place of logical implication as counseling platform, phone, bar desk etc. in gateway, room or any indoor environment.Described have logical implication and refer to that location comparison is special, has its specific function.
Step S1012, gather received signal strength (RSSI) value of each location reference point, it can be used as the RSSI fingerprint of location reference point.
Certain time gathers received signal strength (RSSI) value from periphery WAP (wireless access point) (AP) for such as one minute.Consider that human body is towards the interference to wireless signal, RSSI value four in all directions calculates the average of the RSSI value from all WAP (wireless access point) towards equalization collection, and it can be used as the RSSI fingerprint in this place.
Step S1013, by the positional information of described location reference point and the RSSI fingerprint corresponding with it stored in database, complete the structure of fingerprint database.
Step S102, structure move database.
For the user in a movement, its two the most basic mobile attributes are direction and distance, and they determine the motion track of mobile subscriber within certain period jointly.On the other hand, embedded digital compass, accelerometer in smart mobile phone popular at present, wherein digital compass gives the direction of mobile phone front end relative to north, earth magnetic field, and accelerometer gives the trend of mobile phone velocity variations.The application of these transducers on mobile phone makes the motion track catching user become possibility.User arbitrarily can walk in the indoor environment building fingerprint database.Generally, user's handheld mobile phone, wherein mobile phone front end indicated direction consistent with user's moving direction (the usual placement of user's mobile phone when send short messages, online etc. operates, this condition can be relaxed further).Mobile phone periodically perception, from the received signal strength of periphery WAP (wireless access point), and generates RSSI fingerprint according to this, and the RSS fingerprint current according to user comes estimating user position.Meanwhile, digital compass embedded in mobile phone and accelerometer continue to record moving direction information and the moving distance information that each RSS fingerprint generates interval, so just obtain the relative position information between adjacent position.
The detailed process building move database is as follows:
Step S1021, the RSSI fingerprint of user position to be mated with RSSI fingerprint in described fingerprint database, according to matching result, obtain a location estimation.
The dissimilar degree of RSSI fingerprint in the RSSI fingerprint of user position and described fingerprint database is calculated according to formula (a), the minimum RSSI fingerprint of dissmilarity degree is matching result, and the position of its correspondence is then as a location estimation of user position;
Wherein, if the quantity of the WAP (wireless access point) (AP) in indoor whole region is n, n is positive integer, then the RSSI fingerprint of user position can be expressed as F=(f
1, f
2..., f
n), wherein f
irepresent from the RSSI fingerprint of i-th WAP (wireless access point), same, the arbitrary RSSI fingerprint in fingerprint database be F'=(f '
1, f '
2..., f '
n).
In step S1022, calculating mobile phone, the average of the bearing data that digital compass gathers, obtains the moving direction information of user.
When foregoing mobile phone modes of emplacement, the direction of user's movement is the reading of digital compass, namely relative to the angle in north, battery magnetic field.Calculate the digital compass reading average of user in induction RSSI fingerprint interval as the moving direction in during this period of time.In addition, the method of estimation of user shift position when also putting arbitrarily with a kind of mobile phone, the Fourier transform of its resolving acceleration meter induced signal is at the component of two northwards and westwards, try to achieve the approximate range of the angle of moving direction and mobile phone sensing, recycling indoor can be walked path and try to achieve a fine estimation value by the feature that wall limits.
Step S1023, the change information of user's acceleration gathered according to accelerometer in mobile phone, obtain the moving distance information of user.
When after the pin kiss the earth that user steps, acceleration is forward by appearance maximum.Such continuous print normal table is walked about the peak value also making accelerometer readings present series of periodic.According to such characteristic, each step that people walks can be detected.
As shown in Figure 3, the acceleration change feature schematic diagram of user's walking that provides for the embodiment of the present invention of Fig. 3.Clearly can observe accekeration and periodically occur lofty peak value from figure.The acceleration (Acceleration) of user represented by curve in the drawings, has marked each step (steps) detected by cross symbols.According to the change information of user's acceleration that accelerometer in mobile phone gathers, calculate the walking step number of user, and calculate the step-length of user according to the height of user, gone out the moving distance information of user by described step number and step size computation.
Step S1024, in conjunction with described location estimation, described moving direction information and moving distance information to be processed, and by result stored in database, complete the structure of move database.
In order to the data that more effectively mass-rent gets, the data in each timeslice are recombinated.If the station location marker number (ID) of initial time is larger than the station location marker number of finish time in a period of time interval, so reverse initial time and the station location marker of finish time number (namely make the station location marker of initial time number less), the moving direction in this timeslice is reversed.Mutual accessibility in position is (if can reach position D2 from position D1 through certain path, then can reach position D1 from position D2 through inverse path) setting up (all setting up most indoor environment), such restructuring effectively can reduce the time of mass-rent.
On the other hand, because now location estimation only depends on RSSI fingerprint, mass-rent data may bring larger error due to the location estimation of mistake.Therefore by the moving direction information in each timeslice between original position with end position with moving distance information with compared with the value of indoor environment map calculation, if difference exceedes set threshold value, then abandon the moving direction information in this timeslice and moving distance information, and average recorded information identical with end position for original position in each timeslice gathered for user's moving direction and displacement and standard deviation, stored in move database.Wherein, described threshold size can adjust flexibly according to the requirement of positioning precision, and the difference of such as moving direction is more than 20 degree, and the difference of displacement is more than 3 meters.
Step S103, consumer positioning position.
The Location Request that step S1031, reception user first time send, the RSSI fingerprint of user position is gathered according to this Location Request, calculate the dissimilar degree of RSSI fingerprint in the RSSI fingerprint of this user position and described fingerprint database, return the set comprising fixed qty position candidate, and using the location estimation of position corresponding for RSSI fingerprint minimum for degree dissimilar in this set as user position.
Step S1032, in the next time interval, user moves to reposition, then gather the RSSI fingerprint of this reposition, calculate the average of the bearing data that digital compass gathers within the described time interval in mobile phone, obtain the moving direction information of user, according to the change information of user's acceleration that accelerometer in mobile phone gathers within the described time interval, obtain the moving distance information of user.
The dissimilar degree of RSSI fingerprint in step S1033, the RSSI fingerprint calculating described reposition and described fingerprint database, obtain the set comprising fixed qty position candidate, and calculate by formula (b) probability that each position candidate is described reposition;
Wherein, suppose that location candidate set is L={l
1, l
2..., l
k, position candidate l
icorresponding dissimilar degree is m
i, F is the RSSI fingerprint of reposition, P (X=l
i| F) be reposition X be l
iprobability.
Step S1034, the moving direction information of described user and the moving distance information of user are modeled as Gaussian Profile, in move database, the average of user's moving direction and displacement and standard deviation are average and the standard deviation of Gaussian Profile, under the moving direction d calculating user within the described time interval according to formula (c) and displacement o condition, reposition X is l
iprobability;
Wherein, the direction d of given position i to j and distance o, definition 0-1 stochastic variable V
i,j, its value is that 1 and if only if that user through such direction d and distance o from i to j, thus can obtain P (V
i,j=1)=D
i,j(d, α) O
i,j(o, β); D
i,j(d, α) and O
i,j(o, β) is corresponding siding-to-siding block length is α and β Gaussian Profile discretization, and X' is described location estimation, and its value set is S={s
1, s
2..., s
k.As shown in Figure 4, direction and distance schematic diagram between the adjacent position of user mobile phone record that provides for the embodiment of the present invention of Fig. 4.In the whole run trace of user, user is respectively through A, B, C, D and E totally five positions, digital compass embedded in the mobile phone of each position and accelerometer continue the mobile message of recording user, moving direction and the range coordinate of B, C, D and E tetra-positions correspond to (d1, o1), (d2, o2), (d3, o3), (d4, o4).
Step S1035, formula (b) and formula (c) to be processed, obtain that to utilize the RSSI fingerprint of reposition, user's moving direction information and moving distance information to assess reposition X be l simultaneously
ithe formula (d) of probability, and to calculate reposition X according to formula (d) be l
iprobability, obtain the positional information of described reposition;
Wherein, P (X=l
i| F) for reposition X be l
iprobability.
Please refer to shown in Fig. 5, the mobile ancillary chamber inner position system construction drawing based on intelligent mobile phone platform that Fig. 5 provides for the embodiment of the present invention.
Indoor locating system is assisted to comprise fingerprint database construction unit 501, move database construction unit 502 and engine of positioning unit 503 based on the movement of intelligent mobile phone platform in the present embodiment.
Described fingerprint database construction unit 501 is for gathering received signal strength (RSSI) value of each location reference point, it can be used as the RSSI fingerprint of location reference point, by the positional information of described location reference point and the RSSI fingerprint corresponding with it stored in database, complete the structure of fingerprint database.
Certain time gathers received signal strength (RSSI) value from periphery WAP (wireless access point) (AP) for such as one minute.Consider that human body is towards the interference to wireless signal, RSSI value four in all directions is towards equalization collection, calculate the average from the RSSI value of all WAP (wireless access point), and it can be used as the RSSI fingerprint in this place, then by the positional information of described location reference point and the RSSI fingerprint corresponding with it stored in database, complete the structure of fingerprint database.
Described move database construction unit 502, for being mated with RSSI fingerprint in described fingerprint database by the RSSI fingerprint of user position, according to matching result, obtains a location estimation; Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user; According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user; And in conjunction with described location estimation, described moving direction information and moving distance information are processed, and by result stored in database, complete the structure of move database.
The dissimilar degree of RSSI fingerprint in the RSSI fingerprint of user position and described fingerprint database is calculated according to formula (a), the minimum RSSI fingerprint of dissmilarity degree is matching result, and the position of its correspondence is then as a location estimation of user position;
Wherein, if the quantity of the WAP (wireless access point) (AP) in indoor whole region is n, n is positive integer, then the RSSI fingerprint of user position can be expressed as F=(f
1, f
2..., f
n), wherein f
irepresent from the RSSI fingerprint of i-th WAP (wireless access point), same, the arbitrary RSSI fingerprint in fingerprint database be F'=(f '
1, f '
2..., f '
n).
When foregoing mobile phone modes of emplacement, the direction of user's movement is the reading of digital compass, namely relative to the angle in north, battery magnetic field.Calculate the digital compass reading average of user in induction RSSI fingerprint interval as the moving direction in during this period of time.In addition, the method of estimation of user shift position when also putting arbitrarily with a kind of mobile phone, the Fourier transform of its resolving acceleration meter induced signal is at the component of two northwards and westwards, try to achieve the approximate range of the angle of moving direction and mobile phone sensing, recycling indoor can be walked path and try to achieve a fine estimation value by the feature that wall limits.
According to the change information of user's acceleration that accelerometer in mobile phone gathers, calculate the walking step number of user, and calculate the step-length of user according to the height of user, gone out the moving distance information of user by described step number and step size computation.
By the moving direction information in each timeslice between original position with end position with moving distance information with compared with the value of indoor environment map calculation, if difference exceedes set threshold value, then abandon the moving direction information in this timeslice and moving distance information, and average recorded information identical with end position for original position in each timeslice gathered for user's moving direction and displacement and standard deviation, stored in move database.Wherein, described threshold size can adjust flexibly according to the requirement of positioning precision, and the difference of such as moving direction is more than 20 degree, and the difference of displacement is more than 3 meters.
The Location Request that described engine of positioning unit 503 sends for receiving user, mates the RSSI fingerprint of the user position of collection with RSSI fingerprint in described fingerprint database, returns the set comprising fixed qty position candidate according to matching result; Calculate the average of the bearing data that digital compass gathers in mobile phone, obtain the moving direction information of user; According to the change information of user's acceleration that accelerometer in mobile phone gathers, obtain the moving distance information of user; And according to the moving direction information of the data in described move database, user and the moving distance information of user, the position candidate comprised described in calculating in the set of fixed qty position candidate is the probability of user position, obtain user position.
Receive the Location Request that user sends first time, the RSSI fingerprint of user position is gathered according to this Location Request, calculate the dissimilar degree of RSSI fingerprint in the RSSI fingerprint of this user position and described fingerprint database, return the set comprising fixed qty position candidate, and using the location estimation of position corresponding for RSSI fingerprint minimum for degree dissimilar in this set as user position.
In the next time interval, user moves to reposition, then gather the RSSI fingerprint of this reposition, calculate the average of the bearing data that digital compass gathers within the described time interval in mobile phone, obtain the moving direction information of user, according to the change information of user's acceleration that accelerometer in mobile phone gathers within the described time interval, obtain the moving distance information of user.
Calculate the dissimilar degree of RSSI fingerprint in the RSSI fingerprint of described reposition and described fingerprint database, obtain the set comprising fixed qty position candidate, and calculate by formula (b) probability that each position candidate is described reposition;
Wherein, suppose that location candidate set is L={l
1, l
2..., l
k, position candidate l
icorresponding dissimilar degree is m
i, F is the RSSI fingerprint of reposition, P (X=l
i| F) be reposition X be l
iprobability.
The moving direction information of described user and the moving distance information of user are modeled as Gaussian Profile, in move database, the average of user's moving direction and displacement and standard deviation are average and the standard deviation of Gaussian Profile, under the moving direction d calculating user within the described time interval according to formula (c) and displacement o condition, reposition X is l
iprobability;
Wherein, the direction d of given position i to j and distance o, definition 0-1 stochastic variable V
i,j, its value is that 1 and if only if that user through such direction d and distance o from i to j, thus can obtain P (V
i,j=1)=D
i,j(d, α) O
i,j(o, β); D
i,j(d, α) and O
i,j(o, β) is corresponding siding-to-siding block length is α and β Gaussian Profile discretization, and X' is described location estimation, and its value set is S={s
1, s
2..., s
k;
Formula (b) and formula (c) are processed, obtains and utilize the RSSI fingerprint of reposition, user's moving direction information and moving distance information assessment reposition X to be l simultaneously
ithe formula (d) of probability, and to calculate reposition X according to formula (d) be l
iprobability, obtain the positional information of described reposition;
Wherein, P (X=l
i| F) for reposition X be l
iprobability.
Compared with traditional indoor orientation method, technical scheme of the present invention is while utilizing indoor radio signal, and be attached in position fixing process by the mobile message of user, positioning precision is high, and worst error is little, can continue to provide accurate location in real-time position fixing process.
Above are only preferred embodiment of the present invention and institute's application technology principle, be anyly familiar with those skilled in the art in the technical scope that the present invention discloses, the change that can expect easily or replacement, all should be encompassed in protection scope of the present invention.