# SimulatorLocation-master **Repository Path**: www.yangtao.com/SimulatorLocation-master ## Basic Information - **Project Name**: SimulatorLocation-master - **Description**: No description available - **Primary Language**: Objective-C - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-07-20 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # SimulatorLocation
1、提供各种国际坐标与国内坐标的转换 ,国际使用的坐标是WGS-84,高德使用的火星坐标(GCJ-02),百度使用的是自己的坐标(BD-09)。
3、iPhone所需要的坐标是WGS-84,我们获取的是GCJ-02或者BD-09,这里我们利用最新上述函数算法来转换出你所需要的真实坐标。
4、创建gpx文件,包含坐标用于模拟定位。
<?xml version="1.0"?>
<gpx version="1.1" creator="Xcode">
<wpt lat="40.0376005351439" lon="117.305775621126">
<name>Cupertino</name>
<time>2014-09-24T14:55:37Z</time>
</wpt>
</gpx>
5、在上述的gpx文件中输入转换后的坐标。
6、在工程运行前需要加载gpx文件
方式一 
方式二 
7、连接真机的时候自己的当前位置就是gpx文件中的经纬度显示的位置, 取消模拟定位 stop 工程 或者拔掉数据线。