Sub Class_Globals
Private Root As B4XView
Private xui As XUI
Private const MathPIdiv180 As Double = cPI / 180
Private Const WGS84_a As Double = 6378137
Private Const WGS84_b As Double = 6356752.3142
Type eGPSLocation(Latitude As Double, Longitude As Double)
Type eProjCoordinate(Easting As Double, Northing As Double)
End Sub
Public Sub Initialize
' B4XPages.GetManager.LogEvents = True
End Sub
'This event will be called once, before the page becomes...
If you mean GPS Selective Availability then not any more. Bill Clinton signed an order to turn it off in 2000 and current GPS satellites no longer have the capability. As I understand it Glonass, Beidou and Galileo are also not degraded for civilian use. Non-compensated ionospheric effects are the main inaccuracy of civilian GPS giving inaccuracies of several to tens of metres, hence the availability of various augmentation systems which can correct to centimetric accuracy - good enough for surveying purposes.gps coordinates used for non-military purposes are deliberately fudged.
I have some doubt that Google Maps is capable of accurate 1 metre resolution anyway but then we get into the discussion of Web Mercator spherical projections as used by almost all web mapping sources versus True Mercator elliptical projections as used by government and professional mapping agencies.
Within milimeters I would say is a really big stretch but, I use GMaps often to pinpoint manholes in our sites, and they are very accurate within 1 to 2 metersi'm encouraged by everyone's faith in various governments' word that we are free to locate what we want within millimeters with our phone.
I have a lot of manholes locations in nad83 from technicians (within milimeters) in a small town. I want to show it to Google maps app. But I need to convert to wgs84 for Google map.Within milimeters I would say is a really big stretch but, I use GMaps often to pinpoint manholes in our sites, and they are very accurate within 1 to 2 meters
I assumed you wanted to convert NAD83 (CSRS) to WGS84 for these types of locations.I have a lot of manholes locations in nad83 from technicians (within milimeters)
{ "type": "Feature", "properties": { "OBJECTID": 1, "CODE": "C-3924", "LENGTH": 129.942726271, "INSTALLATI": 1990, "SECTEUR": "Mistassini", "OWNER": "Ville", "Shape_Leng": 235.731013, "Matériau": "Fonte ductile", "Diamètre": "200", "Type_de_co": "D", "Hiérarchi": "III", "SECTION": "A-20061", "Troncon": 20061 }, "geometry": { "type": "LineString", "coordinates": [ [ 399871.321219788631424, 5418344.341168709099293 ], [ 399768.00000369240297, 5418367.000000730156898 ], [ 399745.999987671908457, 5418357.000000720843673 ], [ 399661.564147593220696, 5418293.268160661682487 ] ] } },
API:You're probably looking at the Modified Transverse Mercator (MTM) projection here to get from the coordinates in meters to WGS84. Your title is a little bit misleading because it indicates that you want to transform between NAD83 and WGS84.
EPSG:2950 NAD83(CSRS) / MTM zone 8 gives a lat/lon in Dolbeau-Mistassini.
You can read more about MTM here: https://cgrsc.ca/resources/coordinate-transformations/projections/
Info on the projection parameters is here: https://epsg.io/2950 (click on transform to calculate lat/lon.)
The necessary formulas should be in here: https://www.iogp.org/wp-content/uploads/2019/09/373-07-02.pdf