Summary of the invention
In view of this, the technical problem to be solved in the present invention is to provide a kind of localization method and device, locates inconvenient problem to solve existing being provided with in the product being provided with positioning function.
It is as follows that the present invention solves the problems of the technologies described above adopted technical scheme:
One aspect of the present invention provides a kind of localization method, comprises:
GPRS unit obtains positioning command by word or voice messaging;
GPRS unit obtains the latitude and longitude information of GPS unit by serial ports;
The latitude and longitude information of acquisition is fed back to positioning command sender by GPRS unit.
Further, described word or voice messaging comprise locating information or warning message.
Further, described warning message comprises the appointment of alarm range, and described GPRS unit obtains latitude and longitude information from GPS unit, when the longitude and latitude of described GPS unit enters the alarm range of specifying, to order sender feedback alarm.
Further, described feedback alarm comprises to background server transmission warning message, or sends warning word or voice messaging to the equipment sending word or voice messaging, or the telephone prompts of the equipment dialed foreground or send word or voice messaging is reported to the police.
Further, described GPRS unit obtains latitude and longitude information by inquiry GPRS base station.
The present invention provides a kind of locating device on the other hand, comprises
GPRS unit, is placed through word or voice messaging obtains positioning command;
GPS unit, is placed through serial ports and provides latitude and longitude information to GPRS unit;
Feedback unit, is set to GPRS unit and the latitude and longitude information of acquisition is fed back to positioning command sender.
Further, described word or voice messaging comprise locating information or warning message.
Further, described warning message comprises the appointment of alarm range, described GPRS unit obtain GPS unit latitude and longitude information and when the longitude and latitude of described GPS unit enters the alarm range of specifying, to order sender feedback alarm.
Further, described feedback alarm comprises to background server transmission warning message, or sends warning word or voice messaging to the equipment sending word or voice messaging, or the telephone prompts dialing the equipment sending word or voice messaging is reported to the police.
Further, described GPRS unit can also be placed through GPRS unit inquiry GPRS base station further and obtain latitude and longitude information.
Localization method provided by the invention and device, various equipment can be applied to, such as bus location instrument, mobile phone, wrist-watch, owing to GPRS unit to be combined formation interactive module with GPS unit, independently GPRS module and GPS module so compare, volume reduces, and easily adapts to some little small electronic equipments; In addition, GPRS unit and GPS unit, by the mutual transmission information of serial ports, make people be sent by the mode such as note, voice or to receive locating information.
Embodiment
In order to make technical matters to be solved by this invention, technical scheme and beneficial effect clearly, understand, below in conjunction with drawings and Examples, the present invention is further elaborated.Should be appreciated that specific embodiment described herein only in order to explain the present invention, be not intended to limit the present invention.
Embodiment one
As shown in Figure 1, the embodiment of the present invention one provides a kind of localization method, comprises:
S101, GPRS unit obtains positioning command by word or voice messaging;
Concrete, the equipment being provided with described GPRS unit has signal with other equipment and is connected, and other equipment operated from a distance can send positioning command to the described equipment being provided with GPRS unit.After the equipment being provided with GPRS unit obtains by word or voice messaging the positioning command that other equipment send, described order can be a note arranged containing location or warning, such as: location, the then current latitude and longitude information of GPS unit record also feed back to positioning command sender by GPRS module.If warning message, centered by current position, such as exceed 500 meters of radius alarms; Then the latitude and longitude information of GPRS unit record current device, when the longitude and latitude that GPS unit obtains exceedes the longitude and latitude 500 meters of record, this positioning equipment to background server feedback alarm, or sends word or voice messaging to order sender, dials counterpart telephone prompting and reports to the police.
S102, GPRS unit obtains the latitude and longitude information of GPS unit by serial ports;
Concrete, described GPRS unit obtains by serial ports the latitude and longitude information that on positioning equipment, GPS unit obtains.
The latitude and longitude information of acquisition is fed back to positioning command sender by S103, GPRS unit.
Specifically as shown in Figure 4, described positioning command sender comprises background server or generally sends other equipment of voice or character message; Positioning equipment contains GPRS unit and GPS unit; The latitude and longitude information from GPS unit obtained by serial ports is fed back to positioning command sender by short message mode by the GPRS unit of described positioning equipment, and such positioning command sender just can obtain the positional information of positioning equipment easily by the mode of GPRS.Certainly, some traditional equipment can send the feedback information of positioning command or reception GPRS unit to GPRS unit by background server, then use the instrument of browser or customization to visit time, the positional information that background server checks the equipment being provided with described GPRS unit.
Embodiment two
As shown in Figure 2, the embodiment of the present invention two provides a kind of localization method, comprises:
S201, GPRS unit obtains positioning command by word or voice messaging;
S202, GPRS unit obtains latitude and longitude information by inquiry GPRS base station;
Concrete, when device processes GPS unit in parking lot or the woods cannot search star, inquire about latitude and longitude of base station mode obtain locating information by GPRS unit searches GPRS base station, but the error of this method is compared, the Method compare of direct GPS unit location is large.
The latitude and longitude information of acquisition is fed back to positioning command sender by S203, GPRS unit.
Embodiment three
As shown in Figure 3, the embodiment of the present invention three provides a kind of locating device, comprises: GPRS unit 10, GPS unit 20, feedback unit 30.
GPRS unit 10, is placed through word or voice messaging obtains positioning command;
Concrete, the equipment being provided with described GPRS unit has signal with other equipment and is connected, and other equipment operated from a distance can send positioning command to the described equipment being provided with GPRS unit.After the equipment being provided with GPRS unit obtains by word or voice messaging the positioning command that other equipment send, described order can be a note arranged containing location or warning, such as: location, the then current latitude and longitude information of GPS unit record also feed back to positioning command sender by GPRS module.If warning message, centered by current position, such as exceed 500 meters of radius alarms; Then the latitude and longitude information of GPRS unit record current device, when the longitude and latitude that GPS unit obtains exceedes the longitude and latitude 500 meters of record, this equipment is reported to the police to background server, or sends word or voice messaging to order sender, dials counterpart telephone prompting and reports to the police.
GPS unit 20, is placed through serial ports and provides latitude and longitude information to GPRS unit;
The latitude and longitude information that described GPRS unit is obtained by GPS unit on serial ports acquisition equipment; In addition, when device processes GPS unit in parking lot or the woods cannot search star, inquire about latitude and longitude of base station mode by GPRS unit searches GPRS architecture and obtain locating information, but the error of this method is compared, the Method compare of direct GPS unit location is large.
Feedback unit 30, is set to GPRS unit and the latitude and longitude information of acquisition is fed back to positioning command sender.
Specifically as shown in Figure 4, described positioning command sender comprises background server or generally sends other equipment of voice or character message; Positioning equipment contains GPRS unit and GPS unit; The latitude and longitude information from GPS unit obtained by serial ports is fed back to positioning command sender by short message mode by the GPRS unit of described positioning equipment, and such positioning command sender just can obtain the positional information of positioning equipment easily by the mode of GPRS.Certainly, some traditional equipment can send the feedback information of positioning command or reception GPRS unit to GPRS unit by background server, then use the instrument of browser or customization to visit time, the positional information that background server checks the equipment being provided with described GPRS unit.
The embodiment of the present invention provide localization method and device, various equipment can be applied to, such as bus location instrument, mobile phone, wrist-watch, owing to GPRS unit to be combined the interactive integral module of formation one with GPS unit, independently GPRS module and GPS module so compare, volume reduces, and easily adapts to some little small electronic equipments; In addition, GPRS unit and GPS unit, by the mutual transmission information of serial ports, make people be sent by the mode such as note, voice or to receive locating information.
It should be noted that, the technical characteristic in said method embodiment is all corresponding applicable at this device, no longer repeats here.
One of ordinary skill in the art will appreciate that all or part of step realized in above-described embodiment method is that the hardware that can control to be correlated with by program completes, described program can be stored in a computer read/write memory medium, described storage medium, as ROM/RAM, disk, CD etc.
Above with reference to the accompanying drawings of the preferred embodiments of the present invention, not thereby limit to interest field of the present invention.Those skilled in the art do not depart from the scope and spirit of the present invention, and multiple flexible program can be had to realize the present invention, and the feature such as an embodiment can be used for another embodiment and obtains another embodiment.All use do within technical conceive of the present invention any amendment, equivalently replace and improve, all should within interest field of the present invention.