I am looking for an easy way to prompt a user to download app from android (or iOS) when using external accessory/device.
I have a bluetooth device, and would like to prompt user when that device is connected for the first time to a phone. Has someone found a trick to do such a thing?
I believe this is possible with USB connection to phone using http://developer.android.com/reference/android/content/Intent.html#ACTION_UMS_CONNECTED
Any idea when connecting bluetooth classic or smart?
Related
I am aware that i could just use the playstation app, but I'm specifically looking to be able to enter an account password remotely without showing the password on the android device ,the app should connect to PS4 (as a bluetooth keyboard i guess), then retrieve the password (from a server for example) and then pass it to PS4, there are a few open source projects that allow android to emulate a keyboard but they require root.
If this can't work please specify why you think it can't, that would be very helpful.
It is possible for an android device to emulate a bluetooth keyboard without root after the pie-release, but it is not possible to connect to a PS4 without root, because during the bluetooth discovery phase the PS4 is looking for a Mouse or Keyboard. Phones and tablets will be filtered out, and since you can't change the bluetooth class of device (COD) for your android HID bluetooth app it will not be able to connect over bluetooth.
I need to know if this is even possible and if it is how I would go about doing this.
I have a laptop, android phone, and Google ChromeCast HDMI adapter. When I am at home and on the same network as the ChromeCast I am able to broadcast by browser window to the Chromecast and thus watch what I am doing on my TV.
I need a way that when I am away from home and on a network that blocks devices from talking to one another to be able to do the same thing.
In order to do this I believe what I need to be able to do is have my Samsung sIII connect to a WiFi point where it has internet access, then for my computer and ChomeCast to connect to my phone on a completely different class c where they are able to access the internet but also talk to one another regardless of if the external network permits it or not.
I can do this by using the phones built in hotspot, but I don't want to use my phones data plan if there is a network I can connect to in order to use their internet.
In addition to using this while I am with clients to broadcast my browser screen, when I am travelling with my family I would like to be able to stream from my Netflix account however most hotels I have stayed in won't let the chrome device connect to my computer because of the AP isolation. Again, it would be nice to connect to the hotel wifi to stream netflix but to let the chrome device connect to the phone as it's access point so the phone can talk to the ChromeCast.
Any help would be appreciated!
USB reverse tethering = Cellphone gets network connection from PC via USB.
I know how to do USB reverse tethering except for one problem: Many Android apps will check network connection using the code below before doing any useful work:
ConnectivityManager connectivityManager = (ConnectivityManager)context.getSystemService(Context.CONNECTIVITY_SERVICE);
NetworkInfo info = connectivityManager.getActiveNetworkInfo();
The problem is that, when using USB reverse tethering, the above code will report no network connection. However, there IS a network connection (which is the USB reverse tethering itself), and ping, wget and all programs not doing this stupid check work well.
So the question is: How can I hack the system to let this network connection check return success (so that I can fool these apps)?
BTW. I use Cyanogenmod 7. And any solution specific to this MOD is also welcome.
If you are doing this much hacking I am assuming that you will probably have your device rooted. If so program a shell interface to send commands to the device shell with JNI and receive STDOUT. Use this interface to run a netcfg command that can be parsed into an array - this will give you all the details the API hides. It also allows you to override Androids device settings using the ipconfig command.
As far as using this to send and receive from your device - in my experience - you will have to probably compile a device specif module that can be loaded into the kernel at run time. Or just download the kernel from the manufacturer and compile the module into the kernel and then flash the phone with the new custom kernel.
Hope this helps.
To do this , you have to download ReverseTethering_3.19.zip file (Google it to find the link.)
Extract to your desired location.
Prerequisite: -
only rooted phones work.
USB debugging should be enabled.
Now connect your rooted android mobile to PC through USB cable.Wait for PC to recognize your mobile. Now open the extracted zip file and open AndroidTool.exe with admin rights.
Now click connect in the android tool.
Now it tries to connect and installs USB tunneling apk on your device.It also asks for super user rights . Grant it.
Finally after successfully establishing the connection, you will see.
https://drive.google.com/file/d/0B11p07T8VxhNNUdIM3gtTFR4N3M/view?usp=sharing
(Sorry, I cant upload image.)
Now you get the internet on your mobile and usb tunneling app is installed.But you can access only HTTP connections(i.e;) works only in chrome. Play store apps may not work.
So you have to fool apps and make it believe that either is mobile is connected to WiFi or mobile data . Only then apps work.
So you have to go to Tools menu in Android tool.
https://drive.google.com/file/d/0B11p07T8VxhNRXR3aTVUZUl1dVk/view?usp=sharing
Now install hack(optional).It installs Xposed framework and installs hack connectivity apk. Just follow the instructions , it is easy.
Hack connectivity makes the apps believe that mobile is connected to WiFi or mobile data depending on which type of hack u did after installing Hack connectivity. Finally after hacking ,it asks for reboot. After reboot , you can enjoy internet using USB reverse tethering on all apps.
I'm working on a project to automate some tasks (such as play a song, play a video, receive bluetooth data, etc) on an Android phone from a PC.
Basically the PC will send a notifier to the phone and an app or something on the phone would then process the notifier and do 'something'. The opposite of this really:
http://code.google.com/p/android-notifier/
I've seen some examples showing how to send commands to an Android listener app or service via a network connection, but in this case, I would much rather the transmission be over a physical connection.
USB
Ideally, I'd like the connection to be via the USB port. But I've seen some posts online that suggest that the SDK does not natively support this. (Android apps, communicating with a device plugged in the USB port).
Is there some other SDK/API out there that makes this easier?
I've seen some posts on the ADB, but don't really get it... Would that work?
(http://developer.android.com/guide/developing/tools/adb.html)
Serial over USB
I've also seen some sites that show how to use a breakoutbox to perform bi-directional serial communication, but only with the G1. Is this possible with newer phones?
The Phone
I'm open to really any newish phone. I'm currently looking at the Galaxy S, because it has the video out through the headphone jack. I'm open to rooting if need be.
Implement a HTTP server in your app, then put your phone in USB Tether mode. This will create a local network between your phone and your PC. You should then be able to send HTTP request or create websockets using the phone's ip.
EDIT : I tested it, and it works, see here
What you can do is the phone acting as a server and then use adb to forward ports [1].
In this scenario the pc app would connect to localhost which would be redirected to the app on the phone via the usb cable.
But if you go this way, you might just as well simply connect directly to the phone's ip (without the adb port forwarding)...
[1] http://developer.android.com/guide/developing/tools/adb.html#forwardports
I have an app developed and deployed on my HTC mobile phone. I am able to debug this in Eclipse with the USB driver SDK. The mobile phone appears now in the hardware manager ADB interface.
I would now be able to send data through this USB connection to the mobile phone which my app is able to handle. I know some tethering software which does this, therefore there must be a way to communicate with user data and with my app.