Today, I found a strange phenomenon that my Android device scanned fewer devices when I turned on bluetooth compared to my mobile phone. Therefore, I want to improve the scanning time to obtain as many detected devices as possible. But I looked it up, and someone said it involved the Bluetooth protocol stack. I'm confused. Can someone help me?
There's a few things that may be going on here.
Firstly, your phone may not be showing devices it cannot support. For example, certain devices may not be meant for phones to connect to, so are not shown in the list of one device, but may be shown in another.
Secondly, some Bluetooth devices do not broadcast/advertise themselves to other devices, which may cause it to show up on one device and not another.
Most modern phones will continuously search for Bluetooth devices while you are on the Bluetooth menu, but I don't believe that time will be the cause of the difference in the list of devices.
There are some apps that will show all the Bluetooth devices around you, including some more hidden devices or unsupported devices, if you don't want to program your own.
If this is for some kind of app, let us know what language or device you are targeting and we can provide some language-specific support.
Related
I would like to know if there is a way to detect if my app is running on a PDA (with android OS) or a conventional smartphone?
There is no difference between a PDA and a traditional smartphone, except for possibly the presence of a cellular radio (and even that's not assured, there may be one). THere's also no difference between a tablet and a smartphone. They're marketing terms, not actual differences between devices. Take any smartphone and smack on an assistant looking UI and you have a PDA.
BTW, not all Android phones have the play store either- its common in Asia for low price brands to not pay Google for it and just load a version of AOSP on it.
So if you want actual help, you need to describe what's different about this device that matters to your program, and then we might be able to help you find workarounds. But there's no way to tell "PDA" because "PDA" has no meaning.
I am working with a firmware team that writes firmware on a QCC3056 Qualcomm chipset that supports earbuds and I develop an android application that supports the BLE earbud Bluetooth device. The earbuds also support google fast pair and this feature requires the BLE mac address to be rotated every 15 min.
So the issue I am seeing here is the android Bluetooth settings recognize two Bluetooth devices with the same name(one is classic and the other one is BLE). I can tell by the mac addresses that one belongs to classic and the other belongs to the BLE address. We are able to connect to the classic instance. However, we are unable to connect to the BLE instance. We would like just one name to show up and the user should be able to connect to it. The firmware team thinks this is expected behavior(two names showing up). As far as I know, from the android end, we don't have any control over the Bluetooth settings. So I wanted to understand if this behavior is expected. I have tested this scenario with SONY WF-1000XM3 which supports Google Fast Pair and I have noticed only one name showing up.
It would be great if anyone can suggest the best possible approach I can take here.
I'm working on an app using bluetooth LE technology. I am trying to build a bi-directional communication between two devices, and first thought Bluetooth LE was the perfect choice at first.
But then the more I learn about it the more disappointed I became, because it looks like not enough devices support the peripheral feature, even though this has been introduced a long time ago.
I know the central role is possible in most cases, but for my app to work, I need to make sure there are enough devices out there that support (and will support) the peripheral role as well.
But I'm really not sure what the situation is because I couldn't find any reputable source which has a list of devices that support the peripheral feature. And due to the fragmented nature of the ecosystem I have no idea if this is something hardware vendors are planning on dropping or if the coverage will increase.
Can anyone share some insights?
Edit: I have already read another answer suggested as a duplicate (Chipsets/Devices supporting Android 5 BLE peripheral mode) as well as almost everything I could find on Stackoverflow about this topic. But I have yet to come across a definitive list of what devices support this feature, and what the future of this feature is. It's extremely frustrating not knowing whether I should even rely on this API or not because while they say it depends on the hardware vendor, NO hardware vendors include this information in their device spec, which is why I asked this question.
A good rule of thumb seems to be that devices which have Bluetooth chips with version 4.1 or above have proper support for the peripheral role.
Otherwise all Bluetooth devices and their features are listed on https://www.bluetooth.org/tpg/listings.cfm. Note that you might have to search for the model number and not brand name, like LG-H790 instead of Nexus 5X. Then press >> DISPLAY ICS DETAILS >>.
But maybe you can use Bluetooth classic? Android - communicating between two devices
I'm contemplating the development of an Android app that detects all or most nearby mobile devices (iPhone, Android, etc) in the immediate neighborhood that are turned on. I don't need to interact with these devices, just detect them, and a requirement is that the detected devices can't need to have any special / unusual apps installed on them. The app only needs to work for typical U.S. devices and networks.
I've thought about a few ways to do this (somehow detecting bluetooth, wifi, or cellular transmissions / identifiers), but I'm looking for specific implementation methods for a way to detect a relatively large proportion of nearby devices. I'm not sure which of these methods is possible / feasible or how to put them into practice...
Perhaps using Bluetooth: Is there a way using the Android SDK to detect non-discoverable Bluetooth devices (not in discoverable mode)? The Nokia Developer site seems to suggest this is possible using Service Discovery Protocol (SDP), but I'm not sure if this is possible more generally in Android.
Perhaps using cell tower mast switching simulation? Ok, this is almost certainly beyond the reach of Android, but this article suggests that there may be a way to "mimic cell mast switching process to trigger quiescent phones into transmitting. Phones respond with their ID and authentication signals...".
I think you should see this, it is a paper, and you cannot view it for free, but in the summary, it clearly states:
Concerns about Bluetooth device security have led the specification of the “non-discoverable” mode, which prevents devices from being listed during a Bluetooth device search process. However, a nondiscoverable Bluetooth device is visible to devices that know its address or can discover its address. This paper discusses the detection of non-discoverable Bluetooth devices using an enhanced brute force search attack. Our results indicate that the average time to attack a non-discoverable Bluetooth device using multiple search devices and condensed packet timing can be reduced to well under 24 hours.
But for an android application, you need the detection time to be well under a few seconds instead of less than 24 hours, so a practical solution may not yet be available.
Instead of shelling out ~$600+ for an unlocked Android development phone device can you use a used phone that is not connected to any wireless carrier?
I see Android phones for sale on Craigslist all the time that people want to get rid of whenever they get an upgrade. They are usually a year old at least but as long as it is in working order that's okay with me.
Are there any downsides to this? Can you use these phones as legit development devices? Are they crippled or anything if they are disconnected from a carrier? They can't make calls or send/receive text messages obviously. But as long as you can use them with a WiFi connection it seems like you'd be able to test quite a bit.
Precisely what you said. You can't make calls/receive texts, but for development it's good enough. Don't know actually if Market will work, but you will find out soon enough.
The only thing that comes to mind is that locations are often provided by carrier networks. You will then need to be connected with WiFi or use GPS to find your locations.
The emulator works pretty well and then you wont need an actual phone. Unless of course you want access to the sensors. Even then you could use the monkey tool to simulate sensor input.
You can use any android phone for your development. So far all the phones I have ever seen has a development menu under preferences. As long you enable debugging and installing unknown apps it should be fine. For full system access you would need rooted phones, it does not matter if the phones is locked to a carrier or not.
Although you can develop on the emulator, you might fail because of the mobile network speed, device io and touch sensitivity. It is best to at least test on a device before publishing. Meanwhile most modern phones run faster than the emulator so if you are ok on emulator you should more than ok on the real device.
I work with several no-contract/no-sim phones with no problem. My first dev phone was a used T-Mobile myTouch 3g (that I bought on Craigslist). The great thing about T-mobile is that you can pop in a pre-paid SIM and get 3g data when you need it for $1.49 per day.