简体   繁体   English

两部Android手机之间的长距离通讯

[英]Long distance communication between two Android phones

I'm looking to develop an Android app which resides on both phones, sends location data and receives the same to know the distance and absolute direction of the other device, and shows whether the user is going in the right direction(ie distance decreasing) or not. 我正在寻找一个可同时在两部手机上使用的Android应用程序,发送位置数据并接收位置数据,以了解另一台设备的距离和绝对方向,并显示用户是否朝着正确的方向(即距离在减小)或不。

How can the devices communicate? 设备如何通信? Would 2G/3G internet or SMS be a good choice? 2G / 3G互联网或短信会是一个不错的选择吗? Is it hard to implement this idea? 实施这个想法难吗? Any suggestions would be helpful. 任何的意见都将会有帮助。

You have three choices to automatically acquire a devices position: GPS, Cell Signal Triangulation and WiFi directional location. 您有三种选择来自动获取设备位置:GPS,小区信号三角测量和WiFi定向位置。 You can read about their individual strengths and weaknesses in this guide: Location Strategies 您可以在本指南中了解其各自的优势和劣势: 位置策略

As for communicating over long distances you have 2-3 options to push and pull data from a device: Mobile Data, WiFi, and under the right circumstances Bluetooth. 至于长距离通讯,您有2-3个选项可从设备推送和提取数据:移动数据,WiFi和在适当情况下的蓝牙。 Here is an article on WiFi Direct . 这是有关WiFi Direct的文章。

These are all involved topics that are too complex for one question, under the FAQ: 这些都是涉及的主题,在FAQ下,对于一个问题来说太复杂了:

Your questions should be reasonably scoped. 您的问题应合理界定。 If you can imagine an entire book that answers your question, you're asking too much. 如果您能想象整本书都能回答您的问题,那么您提出的要求就太多了。

However you can accomplish your goal by taking it on subject at a time. 但是,您可以一次完成一个主题来实现自己的目标。

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

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