简体   繁体   English

使用Google API的Android室内指南

[英]Android indoor directions with Google api

I currently have an app which displays a map fragment and can display navigation to a given point. 我目前有一个显示地图片段并可以显示导航到给定点的应用。 The indoor maps is enabled and the building I'm trying to use does have indoor maps, but it only navigates to outside the building even when the transport mode is set to walking. 启用了室内地图,并且我要使用的建筑物确实具有室内地图,但是即使将运输模式设置为步行,它也只能导航到建筑物外部。

Is there currently any way to do this? 目前有什么方法可以做到这一点?

It seems that the Google Maps Android API does not support this feature for now. 看来Google Maps Android API目前不支持此功能。 Even if you select the correct travel mode , which should be walking, the route is traced on the nearest road and not on the indoor path. 即使您选择了正确的行驶模式 (应该是步行),该路线也会在最近的道路上而不是室内路径上追踪。

I'm also waiting for this option to be released, since it is currently possible to get this outcome using Google's own Maps web app. 我也正在等待这个选项的发布,因为目前可以使用Google自己的Maps网络应用来获得此结果。

My graduate project is about indoor positioning when GPS is not available in android. 我的研究生项目是关于Android无法使用GPS时的室内定位。 The answer is yes, but there is not easy way. 答案是肯定的,但是没有简单的方法。 Hard way to do this but accuracy not good as good the GPS. 很难做到这一点,但精度却不如GPS好。 There are two main approach to get location. 获取位置的主要方法有两种。

Approaches 途径

1. Sensor-Fusion: This method for the get relative location. 1. Sensor-Fusion:此方法用于获取相对位置。 Using built-in sensors (gyroscope, accelerometer, compass) calculate the distance & direction over time. 使用内置传感器(陀螺仪,加速度计,指南针)计算随时间变化的距离和方向 So you get the new location adding this value to old location. 因此,您将获得新位置,并将此值添加到旧位置。 It also called dead-reckoning . 这也称为死守

2. Wi-fi Signal Strength: If there are two or more ap which locations are known before, use the signal strengths to estimate your location. 2. Wi-Fi信号强度:如果以前有两个或多个已知位置,请使用信号强度来估计您的位置。 This idea a bit similar to how GPS works. 这个想法有点类似于GPS的工作原理。

Weak Sides 弱边

1. Sensor-Fusion: Calculating new location error(e0) occur. 1.传感器融合:计算新的位置误差(e0)。 When calculating next new location new error(e1) occurs again. 在计算下一个新位置时,会再次出现新错误(e1)。 So you get new location with e0+e1. 因此,您将获得e0 + e1的新位置。 I mean error groves exponentially over time. 我的意思是,随着时间的流逝,错误树丛呈指数增长。

2. Wi-fi Signal Strength: Some items can block the ap So you get weak signal strength and calculate wrong location. 2. Wi-Fi信号强度:某些项目可能会阻止ap,因此信号强度会变弱并且计算出错误的位置。

Finally I use first approach for short time(10sec). 最后,我使用短时间(10秒)的第一种方法。 Second approach to correct location(every 10sec). 纠正位置的第二种方法(每10秒)。 So you get the best results for long & short time. 因此,无论长短,您都能获得最佳效果。

Source 资源

  • Deeper explaination at this pdf . 在此pdf上有更深入的说明。
  • open source android app using first approach . 使用第一种方法开源android应用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM