安卓机真的获取不了定位的高度信息吗?
发布于 4 年前 作者 yong29 343 次浏览 来自 官方Issues
wx.getLocation({
      type'gcj02',//默认wgs84
      //type:'wgs84',
      altitude:true,
      highAccuracyExpireTime:7000,
           console.log(location);  
    获取到的altitude为0
1 回复

你好,具体是什么机型,微信版本是多少?请确认是否已开启gps定位,开启高精度定位,因为gps定位一般耗时较久,试着将timeout设置成3-5s。请提供能复现问题的代码片段看下(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

回到顶部