I am trying to get accurate latitude and Longitude on my Android Kivy app. Modules like geocoder use IP address, but in my testing that has been super far off when using mobile data. I need some code that works in a kivy apk. It seems like plyer is the way to go, but the docs for it aren't clear how to use it and I couldn't figure it out. I looked around but couldn't find any indication on how to use plyer at all. Does anyone know how to use plyer to get GPS on android? Some python3 code to get lat and lng (not within a few feet. I really only need within a city block or two) would be amazing! Thanks in advance!
Also, if you know of another way to get accurate location data without relying only on wifi or IP geolocating, that would also be appreciated.
UPDATE and clarification:
The gps example ( https://github.com/kivy/plyer/tree/master/examples ) is working on my device, but I don't understand the code. What I understand (or I think I understand): It is looping and constantly updating the widget with the right information.I don't, however, understand what lines of code is actually setting it up and what is getting the coordinates. Is it even possible to use these commands to just get latitude and longitude to a variable? I don't need it to constantly update the coordinates, I just need them once and then assign that to a variable. Is there a method in plyer that I can call and have it return lat and lng? If so, how do I set it up?