GPS sensor in Smart Phones
GPS sensor in Smart Phones
That your smartphone knows where you are is partly due to the fact that:
- On its built-in GPS receiver. Satellite navigation is one of the most useful and essential capabilities of a smartphone these days.
- GPS stands for Global Positioning System and was originally developed by the US Army in 1973. The official name is NAVSTAR GPS (Navigational Satellite Timing and Ranging – Global Positioning System). It is a global positioning system that was originally used in the military sector (box: “The GPS system”).
The GPS system
The graticule is used to find your way around the world. Geographical latitude and longitude are spherical coordinates with the help of which the position of a point on earth can be described exactly. The earth is divided into 180 degrees of latitude and 360 degrees of longitude. The circles of latitude run parallel to the equator. Count 90 parallels to the north and to the south.
The size of the circles decreases with increasing proximity to the poles. The equator runs at right angles to the earth’s axis. With an angle of 0 degrees, it is used as the starting point for calculating the parallels. The longitudinal circles run through the north and south poles.
There are 360 of them. How do you get that number?
The earth rotates around its axis once every 24 hours. The time difference from one degree of longitude to the next is 4 minutes. 360 degrees of longitude times 4 minutes’ equals 1,440 minutes, which is exactly 24 hours.
Unlike latitudes, longitudes have no natural zero point. The meridian that runs through the London borough of Greenwich is the starting point for calculating longitudes. It divides the earth’s surface into western and eastern hemisphere.
The coordinates are measured in degrees (°), arc minutes (‚) and arc seconds („). One degree corresponds to 60 arc minutes, an arc minute in turn has 60 arc seconds. Can that also be more specific? Sure, using an example: The geographical position is 37 ° 49’N and 122 ° 29’W. Decimal notation is much more practical for processing using software. The values are therefore converted.
The above information becomes the latitude 37.816667 and the longitude -122.483333. The digits before the decimal point show the degree, the digits after the decimal point represent the converted values for minutes and seconds. Positive signs indicate a north or east position and negative signs indicate a south or west position.
Two further aspects of localization, possibly also GPS-based, have to be addressed:
- Data protection: Location data are considered personal data and are therefore particularly in need of protection according to the General Data Protection Regulation. Therefore, the “uncontrolled flow” of this data to the servers of an app is repeatedly criticized. The misuse of the location data is often complained about. The advertising industry understandably has a special interest in such data.
As a developer, you have a special responsibility in this regard. The Android and iOS systems always require the explicit consent of the user before accessing the system’s location API. The user can withdraw this authorization at any time, i. In other words, each time the service is used, the user’s consent must be checked again.
- Background process: Location functions are often executed as a background process in an app. For example, with a tracking app, the position is determined at cyclical intervals and transmitted to a server (background) in the cloud via the network (cellular network).
Due to this fact, when programming location functions, one must usually also deal with the topic of using / programming background processes.
For better localization, the GPS sensor should be combined with a gyroscope sensor. Otherwise the GPS positioning is imprecise.
The gyroscope or gyroscope was developed 200 years ago. In a gyroscope, a symmetrical top rotates in a movable bearing. This means that the bearing can move while the gyroscopic motion remains the same. In contrast to the first drafts of a gyroscope, the corresponding sensor is only a few millimeters small today. It is used in the smartphone to recognize its orientation. With the help of the Coriolis force and the tuning fork principle, the smartphone knows where the four corners of the device are in relation to one another in the room. It is therefore a sensor with which the exact alignment (position) can be determined. Many cell phones already have a built-in rotation sensor. Software can be used to check whether the device has a gyro compass. The gyroscope sensor in the smartphone also has a useful function when using navigation apps, because it enables even more precise position determination. The gyroscope is thus an extension of the GPS system. Therefore, the sensors GPS and gyroscope are usually installed together.