CN104391271A - Distance measurement method and device - Google Patents

Distance measurement method and device Download PDF

Info

Publication number
CN104391271A
CN104391271A CN201410353782.7A CN201410353782A CN104391271A CN 104391271 A CN104391271 A CN 104391271A CN 201410353782 A CN201410353782 A CN 201410353782A CN 104391271 A CN104391271 A CN 104391271A
Authority
CN
China
Prior art keywords
mobile terminal
coordinate information
primary importance
distance
place
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
CN201410353782.7A
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.)
Guiyang Longmaster Information and Technology Co ltd
Original Assignee
Guiyang Longmaster Information and 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 Guiyang Longmaster Information and Technology Co ltd filed Critical Guiyang Longmaster Information and Technology Co ltd
Priority to CN201410353782.7A priority Critical patent/CN104391271A/en
Publication of CN104391271A publication Critical patent/CN104391271A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S19/00Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
    • G01S19/38Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system
    • G01S19/39Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system the satellite radio beacon positioning system transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
    • G01S19/42Determining position
    • G01S19/51Relative positioning

Abstract

The invention discloses a distance measurement method and device. The method comprises determining coordinate information of a first position where a mobile terminal is located and coordinate information of a second position where the mobile terminal is located based on a global positioning system GPS positioning function of the mobile terminal; and obtaining the distance between the first position and the second position according to the coordinate information of the first position and the coordinate information of the second position. According to the technical scheme provided in the invention, distance measurement can be realized through software without integrating a distance-measuring circuit to the inner portion of a mobile phone, so that complexity and cost of the mobile phone are reduced; and since a user always carries the mobile terminal (such as the mobile phone), the demand of measuring the distance anytime and anywhere by the user is guaranteed.

Description

Distance-finding method and device
Technical field
The present invention relates to the communications field, in particular to a kind of distance-finding method and device.
Background technology
In daily life, often needing to carry out Distance geometry measurement of length, in the ordinary course of things, is all use tape measure or tape measuring.The volume of tape measure is little, but range is also little, and tape measure range is large, but volume is large.Also needing tester to walk up and down when measuring, using inconvenience.Also ultrasonic range finder and infrared range-measurement system is had can to carry out range observation easily on the market, but on the high side.In some scenes, user needs according to actual conditions the distance knowing point-to-point transmission, but user may not carry with above-mentioned range finding article, therefore cannot accomplish to find range whenever and wherever possible.
Mobile terminal (such as, smart mobile phone) has the abundant screen of powerful data-handling capacity and displaying contents.But the application of smart mobile phone mainly comprises at present: make a phone call, send short messages, online, sees a film, plays games.The powerful processing power of smart mobile phone also has very large application potential to excavate.By coordinating various mobile phone peripherals, smart mobile phone can for people bring more convenient.
In correlation technique, the range finding implementation method of carrying out finding range in conjunction with mobile phone is all range-measuring circuit (such as, laser ranging circuit) is integrated into interior of mobile phone realize, and therefore needs to carry out Cell Phone Design specially, thus adds complexity and the cost of mobile phone.
Summary of the invention
Fundamental purpose of the present invention is open a kind of distance-finding method and device, range-measuring circuit is integrated into interior of mobile phone realization range finding, needs to carry out Cell Phone Design specially, add the complexity of mobile phone and the problem of cost to solve in correlation technique.
According to an aspect of the present invention, a kind of distance-finding method is provided.
Distance-finding method according to the present invention comprises: based on the GPS positioning function of mobile terminal, determines the coordinate information of the coordinate information of the primary importance residing for above-mentioned mobile terminal and the second place residing for above-mentioned mobile terminal; According to the coordinate information of above-mentioned primary importance and the coordinate information of said second position, obtain the distance between above-mentioned primary importance and said second position.
According to a further aspect in the invention, a kind of distance measuring equipment is provided.
Distance measuring equipment according to the present invention comprises: the first determination module, for the GPS positioning function based on mobile terminal, determines the coordinate information of the coordinate information of the primary importance residing for above-mentioned mobile terminal and the second place residing for above-mentioned mobile terminal; Acquisition module, according to the coordinate information of above-mentioned primary importance and the coordinate information of said second position, obtains the distance between above-mentioned primary importance and said second position.
Compared with prior art, the embodiment of the present invention at least has the following advantages: because user often can carry mobile terminal (such as mobile phone), ensure that the demand that user can find range whenever and wherever possible.And based on GPS (the Global Positioning System of mobile terminal, referred to as GPS) positioning function, by software simulating range observation, without the need to range-measuring circuit is integrated into interior of mobile phone, thus reduce complexity and the cost of mobile phone.
Accompanying drawing explanation
Fig. 1 is the process flow diagram of the distance-finding method according to the embodiment of the present invention;
Fig. 2 is the process flow diagram of the distance-finding method according to the preferred embodiment of the present invention one;
Fig. 3 is the process flow diagram of the distance-finding method according to the preferred embodiment of the present invention two;
Fig. 4 is the structured flowchart of the distance measuring equipment according to the embodiment of the present invention;
Fig. 5 is the structured flowchart of the distance measuring equipment according to the preferred embodiment of the present invention one; And
Fig. 6 is the structured flowchart of the distance measuring equipment according to the preferred embodiment of the present invention two.
Embodiment
Below in conjunction with Figure of description, specific implementation of the present invention is made a detailed description.
Fig. 1 is the process flow diagram of the distance-finding method according to the embodiment of the present invention.As shown in Figure 1, this distance-finding method mainly comprises following process:
Step S101: based on the GPS positioning function of mobile terminal, determines the coordinate information of the coordinate information of the primary importance residing for above-mentioned mobile terminal and the second place residing for above-mentioned mobile terminal;
Step S103: according to the coordinate information of above-mentioned primary importance and the coordinate information of said second position, obtain the distance between above-mentioned primary importance and said second position.
In correlation technique, user may not carry with tape measure, tape measure, and the specialty such as ultrasonic range finder and infrared range-measurement system range finding article, therefore cannot accomplish to find range whenever and wherever possible.The range finding implementation method of carrying out finding range in conjunction with mobile phone is all range-measuring circuit (such as, laser ranging circuit) is integrated into interior of mobile phone realize, and therefore needs to carry out Cell Phone Design specially, thus adds complexity and the cost of mobile phone.In the method shown in Fig. 1, based on the GPS positioning function of mobile terminal, by software simulating range observation, without the need to range-measuring circuit is integrated into interior of mobile phone, thus reduce complexity and the cost of mobile phone.
Wherein, above-mentioned mobile terminal can be mobile phone, iPad, digital camera etc.Above-mentioned coordinate information can be latitude and longitude value.
Preferably, before execution above-mentioned steps S101, following process can also be comprised: based on above-mentioned GPS positioning function, export the coordinate information of the position residing for above-mentioned mobile terminal in real time; Response user chooses operational order, determines above-mentioned primary importance and said second position.
In preferred implementation process, after user opens distance measurement function, based on the GPS positioning function of mobile terminal, can output mobile terminal is current in real time coordinate position, such as, longitude 112 ° 13.12 ', 25 ° 11.33 ', latitude.When user determines the starting point that will measure, perform in this position and choose operation, such as, clicking operation, then mobile terminal is according to the operational order of user, determines that current location is starting point (i.e. above-mentioned primary importance); When user determines the terminating point that will measure, perform in this position and choose operation, such as, clicking operation, then mobile terminal is according to the operational order of user, determines that current location is terminating point (i.e. said second position).
Such as, can by the DDMS view of Eclipse, the change in location of analog machine, after changing longitude and latitude, clicks send, then working procedure, and in the application, the dynamic position obtaining mobile terminal, then shows current positional information.
Obtain positional information and be divided into three steps:
1. add-on system authority, supports the access to LBS hardware
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION">
</uses-permission>
2. obtain the LocationManager object of system service
LocationManager loctionManager;
String contextService=Context.LOCATION_SERVICE;
// by system service, obtain LocationManager object
loctionManager=(LocationManager)getSystemService(contextService);
3. obtain location provider, by location provider, obtain positional information, concrete location provider can be specified, also can provide a standard set, allow system according to the optimal location provider of matches criteria, positional information provides it to provide by position.
A. position (specifying concrete location provider) is obtained by GPS location provider
String provider=LocationManager.GPS_PROVIDER;
Location location=loctionManager.getLastKnownLocation(provider);
B. use standard set, allow system automatically select available optimum position provider, position is provided
Criteria criteria=new Criteria();
Criteria.setAccuracy (Criteria.ACCURACY_FINE); // high precision
Criteria.setAltitudeRequired (false); // do not require height above sea level
Criteria.setBearingRequired (false); // do not require orientation
Criteria.setCostAllowed (true); // allow cost
Criteria.setPowerRequirement (Criteria.POWER_LOW); // low-power consumption
// from available location provider, mate the best provider of above standard
String provider=loctionManager.getBestProvider(criteria,true);
// obtain the last position changed
Location location=loctionManager.getLastKnownLocation(provider);
The change of monitoring position
// monitoring position changes, and 2 seconds once, distance more than 10 meters
loctionManager.requestLocationUpdates(provider,2000,10,locationListener);
// position audiomonitor
private final LocationListener locationListener=new LocationListener(){
@Override
public void onStatusChanged(String provider,int status,Bundle extras){
}
@Override
public void onProviderEnabled(String provider){
}
@Override
public void onProviderDisabled(String provider){
}
// trigger when change in location
@Override
public void onLocationChanged(Location location){
// use new location to upgrade TextView display
updateWithNewLocation(location);
}
};
By changing position longitude and latitude, program can upgrade the positional information of TextView display automatically.
In step s 103, distance L between above-mentioned primary importance and said second position can be obtained by following formula:
L=[(longitude coordinate of the longitude coordinate-second place of primary importance) ^2 ﹢ (latitude coordinate of the latitude coordinate-second place of primary importance) ^2] ^ (1/2)
Further illustrate below in conjunction with example.
First, degree of carrying out is needed to divide conversion to the coordinate of the starting point got and the coordinate of terminating point:
By degree point unit data degree of being converted to unit data: degree=degree+point/60
Such as:
Starting point longitude=116 ° 20.12 '
Starting point latitude=39 ° 12.34 '
Then longitude degree of being converted to unit data, longitude=116+20.12/60=116.33533 °
Then latitude degree of being converted to unit data, latitude=39+12.34/60=39.20567 °
NTU longitude=116.33533 × 100000=11633533 (NTU)
NTU latitude=39.20567 × 100000=3920567 (NTU)
Terminating point longitude=116 ° 20.7 '
Terminating point latitude=39 ° 12.275 '
Then longitude degree of being converted to unit data, longitude=116+20.7/60=116.34500 °
Then latitude degree of being converted to unit data, latitude=39+12.275/60=39.20458 °
NTU longitude=116.34500 × 100000=11634500 (NTU)
NTU latitude=39.20458 × 100000=3920458 (NTU)
Then can calculate the distance between starting point and ending point according to the latitude and longitude coordinates of starting point and the latitude and longitude coordinates of terminating point:
L=[(11633533-11634500)^2﹢(3920567-3920458)^2]^(1/2)
=(935089+11881)^(1/2)=973.123836(m)
Above-mentioned preferred implementation is further described below in conjunction with Fig. 2.
Fig. 2 is the process flow diagram of the distance-finding method according to the preferred embodiment of the present invention one.As shown in Figure 2, this distance-finding method comprises following process:
Step S201: carry in the process of mobile terminal movement user, based on above-mentioned GPS positioning function, exports the coordinate information of the position residing for above-mentioned mobile terminal in real time.
Step S203: when user performs clicking operation, the operational order of mobile terminal response user, determines above-mentioned primary importance and said second position.
Step S205: the coordinate information determining the coordinate information of the primary importance residing for above-mentioned mobile terminal and the second place residing for above-mentioned mobile terminal.
Step S207: according to the coordinate information of above-mentioned primary importance and the coordinate information of said second position, obtain the distance between above-mentioned primary importance and said second position.
Preferably, before execution step S101, following process can also be comprised: the setting operation instruction of response user, arranges distance parameter to be pointed out; After performing in step S103 the distance obtained between above-mentioned primary importance and said second position, following process can also be comprised: when determining that above-mentioned primary importance is consistent with the distance between said second position and above-mentioned distance parameter, point out above-mentioned user.
In preferred implementation process, user can be pointed out in the following manner: phonetic synthesis service (TTS) function activating above-mentioned mobile terminal, the above-mentioned user of voice message.Certainly, can also reminding user by other means, such as, play cuing music.
Above-mentioned preferred implementation is further described below in conjunction with an example.
Such as, when user needs to find destination, this user is searched by map and determines that destination is a positive north orientation of buildings 850 meters, then this user can arrange this buildings is starting point, and distance parameter to be pointed out 850 meters can be set, in concrete traveling process, when the distance that mobile terminal is determined between this buildings and this destination is 850 meters, activate phonetic synthesis service (TTS) function of above-mentioned mobile terminal, this user of voice message.
Above-mentioned preferred implementation is further described below in conjunction with Fig. 3.
Fig. 3 is the process flow diagram of the distance-finding method according to the preferred embodiment of the present invention one.As shown in Figure 3, this distance-finding method comprises following process:
Step S301: carry in the process of mobile terminal movement user, based on above-mentioned GPS positioning function, exports the coordinate information of the position residing for above-mentioned mobile terminal in real time.
Step S303: when user performs setting operation, the operation of mobile terminal response user, arranges initial point position and distance parameter to be pointed out.
Step S305: the coordinate information of above-mentioned mobile terminal determination initial point position, and in user's traveling process, calculate the distance between current location and this starting point in real time.
Step S307: when the distance parameter of mobile terminal determination current location and the distance between this starting point and above-mentioned setting is consistent, activate phonetic synthesis service (TTS) function of above-mentioned mobile terminal, this user of voice message.
Fig. 4 is the structured flowchart of the distance measuring equipment according to the embodiment of the present invention.As shown in Figure 4, this distance measuring equipment comprises: the first determination module 40, for the GPS positioning function based on mobile terminal, determines the coordinate information of the coordinate information of the primary importance residing for above-mentioned mobile terminal and the second place residing for above-mentioned mobile terminal; Acquisition module 42, according to the coordinate information of above-mentioned primary importance and the coordinate information of said second position, obtains the distance between above-mentioned primary importance and said second position.
In the device shown in Fig. 4, based on the GPS positioning function of mobile terminal, by software simulating range observation, without the need to range-measuring circuit is integrated into interior of mobile phone, thus reduce complexity and the cost of mobile phone.
Wherein, above-mentioned mobile terminal can be mobile phone, iPad, digital camera etc.Above-mentioned coordinate information can be latitude and longitude value.
Preferably, as shown in Figure 5, said apparatus can also comprise: output module 44, for based on above-mentioned GPS positioning function, exports the coordinate information of the position residing for above-mentioned mobile terminal in real time; Second determination module 46, is connected between output module and the second determination module, chooses operational order, determine above-mentioned primary importance and said second position for what respond user.
Preferably, as shown in Figure 6, said apparatus can also comprise: arrange module 48, is connected with the first determination module 40, for responding the setting operation instruction of user, arranges distance parameter to be pointed out; Reminding module 50, is connected with acquisition module 42, for when determining that above-mentioned primary importance is consistent with the distance between said second position and above-mentioned distance parameter, points out above-mentioned user.
Preferably, as shown in Figure 6, reminding module 50 may further include: activate unit 500, for activating the phonetic synthesis service function of above-mentioned mobile terminal; Phonetic synthesis service unit 502, for the above-mentioned user of voice message.
In sum, by above-described embodiment provided by the invention, based on the GPS positioning function of mobile terminal, by software simulating range observation, without the need to range-measuring circuit is integrated into interior of mobile phone, thus reduce complexity and the cost of mobile phone.In addition, because user often can carry mobile terminal (such as mobile phone), also effectively ensure that the demand that user can find range whenever and wherever possible.
Be only several specific embodiment of the present invention above, but the present invention is not limited thereto, the changes that any person skilled in the art can think of all should fall into protection scope of the present invention.

Claims (10)

1. a distance-finding method, is characterized in that, comprising:
Based on the global position system GPS positioning function of mobile terminal, determine the coordinate information of the coordinate information of the primary importance residing for described mobile terminal and the second place residing for described mobile terminal;
According to the coordinate information of described primary importance and the coordinate information of the described second place, obtain the distance between described primary importance and the described second place.
2. method according to claim 1, is characterized in that, before determining the coordinate information of the coordinate information of the primary importance residing for described mobile terminal and the second place residing for described mobile terminal, also comprises:
Based on described GPS positioning function, export the coordinate information of the position residing for described mobile terminal in real time;
Response user chooses operational order, determines described primary importance and the described second place.
3. method according to claim 1, is characterized in that,
Before determining the coordinate information of the coordinate information of the primary importance residing for described mobile terminal and the second place residing for described mobile terminal, also comprise: the setting operation instruction of response user, arranges distance parameter to be pointed out and described primary importance;
After obtaining the distance between described primary importance and the described second place, also comprise: when the distance determined between described primary importance with the described second place and described distance parameter consistent time, point out described user.
4. method according to claim 3, is characterized in that, points out described user to comprise: the phonetic synthesis service function activating described mobile terminal, user described in voice message.
5. method according to any one of claim 1 to 4, described coordinate information comprises: latitude and longitude value.
6. a distance measuring equipment, is characterized in that, comprising:
First determination module, for the GPS positioning function based on mobile terminal, determines the coordinate information of the coordinate information of the primary importance residing for described mobile terminal and the second place residing for described mobile terminal;
Acquisition module, according to the coordinate information of described primary importance and the coordinate information of the described second place, obtains the distance between described primary importance and the described second place.
7. device according to claim 6, is characterized in that, also comprises:
Output module, for based on described GPS positioning function, exports the coordinate information of the position residing for described mobile terminal in real time;
Second determination module, chooses operational order for what respond user, determines described primary importance and the described second place.
8. device according to claim 6, is characterized in that, also comprises:
Module is set, for responding the setting operation instruction of user, distance parameter to be pointed out and described primary importance are set;
Reminding module, for the distance determined between described primary importance with the described second place and described distance parameter consistent time, point out described user.
9. device according to claim 8, is characterized in that, described reminding module comprises:
Activate unit, for activating the phonetic synthesis service function of described mobile terminal;
Phonetic synthesis service unit, for user described in voice message.
10. the device according to any one of claim 6 to 9, described coordinate information comprises: latitude and longitude value.
CN201410353782.7A 2014-07-24 2014-07-24 Distance measurement method and device Pending CN104391271A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410353782.7A CN104391271A (en) 2014-07-24 2014-07-24 Distance measurement method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410353782.7A CN104391271A (en) 2014-07-24 2014-07-24 Distance measurement method and device

Publications (1)

Publication Number Publication Date
CN104391271A true CN104391271A (en) 2015-03-04

Family

ID=52609195

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410353782.7A Pending CN104391271A (en) 2014-07-24 2014-07-24 Distance measurement method and device

Country Status (1)

Country Link
CN (1) CN104391271A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106249263A (en) * 2016-07-06 2016-12-21 北京南科大蓝色科技有限公司 A kind of high-precision point positioning method based on electronic chart
CN107797466A (en) * 2017-02-18 2018-03-13 陈昌杰 The solution of satellite fix ranging control apparatus
CN110045403A (en) * 2019-04-17 2019-07-23 北京航天发射技术研究所 A kind of distance measuring method and range unit based on earth coordinates

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106249263A (en) * 2016-07-06 2016-12-21 北京南科大蓝色科技有限公司 A kind of high-precision point positioning method based on electronic chart
CN107797466A (en) * 2017-02-18 2018-03-13 陈昌杰 The solution of satellite fix ranging control apparatus
CN110045403A (en) * 2019-04-17 2019-07-23 北京航天发射技术研究所 A kind of distance measuring method and range unit based on earth coordinates

Similar Documents

Publication Publication Date Title
US8825377B2 (en) Mobile navigation to a moving destination
CN104539782B (en) A kind of event-prompting method and its device
US20150256978A1 (en) Indoor localization of mobile devices
US10989559B2 (en) Methods, systems, and devices for displaying maps
CN110837607B (en) Interest point matching method and device, computer equipment and storage medium
CN108337368B (en) Method for updating positioning data and mobile terminal
US20200265725A1 (en) Method and Apparatus for Planning Navigation Region of Unmanned Aerial Vehicle, and Remote Control
CN107534841B (en) Method and device for outputting notification
CN105516289A (en) Method and system for assisting voice interaction based on position and action
CN110730419A (en) Article positioning method, device and system and electronic equipment
KR20120059239A (en) Mobile terminal and method for sharing real-time road view
EP3962119A1 (en) Positioning method and apparatus
CN104359483A (en) Reverse-direction track navigation system in non-signal cover environment and implementation method of reverse-direction track navigation system
CN105163279A (en) Information processing method and terminal
CN109191373A (en) Navigation coordinate converts gauss projection and sits calibration method, system, equipment and medium
CN104391271A (en) Distance measurement method and device
CN102149041A (en) Equipment and method for positioning spatial orientation and marking additional information
CN109813300B (en) Positioning method and terminal equipment
CN107532913B (en) Navigation method and equipment for navigation
CN102917307A (en) Information transmission method and device, UE and communication system
CN114466308A (en) Positioning method and electronic equipment
US20160328947A1 (en) Method for alarming gas and electronic device thereof
CN114198491B (en) Monitoring method and system based on lubricating oil and electronic equipment
CN107979792A (en) Method for retrieving, device, wireless microphone and the storage medium of wireless microphone
CN114079855B (en) Low-power-consumption positioning method and related device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20150304

WD01 Invention patent application deemed withdrawn after publication