收藏
回答

郊区wx.getLocation误差几公里,提高精度方法?

在郊区wx.getLocation 获取的定位地址误差达到几公里,这是本身的通病吗?难道没有别的方法可以精准定位吗?现在公司业务要求误差不能超过100米。

wx.showLoading({
          title: "正在定位...",
          mask: true
        });
wx.getLocation({
 type: 'gcj02',
 altitude:'true',
 isHighAccuracy: true,
 highAccuracyExpireTime:3000,
 success: res => {
  console.debug("res", res);
  const latitude = res.latitude;
  const longitude = res.longitude;
  //console.debug("latitude", latitude);
  //console.debug("longitude", longitude);
  url += "&latitude=" + latitude + "&longitude=" + longitude+ "&brand=" + systemInfo.brand
              + "&model=" + systemInfo.model +"&nickname="+username;
  this.jump(url);
 },
 fail: err => {
  console.debug("err", err);
  Toast("获取定位信息失败!");
  this.jump(url);
 },
  complete: res => {
    wx.hideLoading();
  }
})


回答关注问题邀请回答
收藏

2 个回答

  • 良
    2020-08-29

    请问一下你这个误差的问题解决了吗

    2020-08-29
    有用
    回复 1
    • John Doe
      John Doe
      2020-09-09
      没有,不过有个高德小程序sdk,有纠偏算法,不过我用了还是不准..
      2020-09-09
      回复
  • 疯狂的小辣椒
    疯狂的小辣椒
    2020-03-13

    你好,小程序目前支持:

    1.getLocation接口高精度定位的能力https://developers.weixin.qq.com/miniprogram/dev/api/location/wx.getLocation.html;

    2.持续定位的接口(精度会随着定位时间,越来越高)https://developers.weixin.qq.com/miniprogram/dev/api/location/wx.startLocationUpdateBackground.html


    2020-03-13
    有用
    回复 3
    • John Doe
      John Doe
      2020-03-13
      altitude:'true&',
       isHighAccuracy: true,
       highAccuracyExpireTime:3000,
      能提高精度都设置了,在田里相隔400米,两个点定位差了几公里图为微信分享定位和获取到点对比
      2020-03-13
      回复
    • John Doe
      John Doe
      2020-03-13
      这个在郊区是通病吗?有没有提高到起码像微信定位那样的精度,公司想谈合作有联系方式吗
      2020-03-13
      回复
    • 疯狂的小辣椒
      疯狂的小辣椒
      2020-03-13回复John Doe
      麻烦在手机微信那里上传下日志: 我->设置->帮助与反馈右上角有个上报日志的入口,麻烦提供一下微信号,时间点
      2020-03-13
      回复
登录 后发表内容
问题标签