Android Wear - Connect to IP Address - wear-os

I already did some research on Android Wear. It seems not possible to connect to an concrete IP Adress from an Wear Device without using the Phone as a proxy.
I understand that this is because of battery life, but in my case i do not really care about battery life. Anyone got a connection without using the phone as a proxy ?

As long as your watch is not connected directly to a phone (via BT), and if your watch supports wifi and it is turned on, then you can make direct network calls from your watch.

Related

Does Android Wear work with geofencing without paired handheld?

According to the documentation, geofencing uses cellular network and wifi signal for detecting a location, but it seems like it doesn't work without a connected companion device.
Does Android Wear work with geofencing without paired handheld?
Update:
Just had a quick play with this, doesn't seem to work yet when BT disconnected and wifi connected.
Original reply:
Not all wear devices have the hardware to support this, though the LG urbane 2 has LTE and quite a few Wear devices support wifi.
I would think this works considering other services work that use location with wifi/gps.
Can you check these items?
Verify your Wear device supports wifi, i.e., it has a wifi chip
When disconnected, check wifi is enabled under settings (this should happen automatically)
Wait some time (even 5 mins) for a signal
More details:
If your wear device has wifi, it should actually turn on if the Wear device becomes disconnected from the phone via bluetooth. You can verify this by looking in the settings as noted above.
I have noticed with the FusedLocationProviderApi it can sometimes take quite a bit of time to switch to the on-board chip when the phone becomes disconnect, so it may be the case with the Geofencing as well. FYI, Google Play Services always uses the phone's hardware first to save battery. It only uses Wear hardware when the phone disconnects.

Windows 8.1 Bluetooth Low Energy Behavior

I'm looking into programming Bluetooh Low Energy on Windows 8.1 and have a few questions about its behavior on auto-reconnecting to BLE devices after the connection is termiated:
How long will this auto-reconnect feature timed out? Or is it as long as you subscribe to BLE notifications and attempt to read/write data to it?
Will it reconnect if I restart Windows and my application?
How many devices can Windows remember to reconnect? Is it as many as the number of devices my app can connect to?
Where did you read about auto-connecting algorithm for Bluetooth devices in Windows 8.1. As far as I know, it is not possible to perform any kind of auto-connection, so all connection establishment has to be done manually in Windows 8.1 Bluetooth settings.
If your device is in connected state and you restart your PC for some reason, it will still show your device in the list but as "Not Connected" state. So you manually have to remove the device, and then pair it again.
I made a test, where I connected to two devices and read notifications from them both at the same time. What do you mean by app ?. A Smartphone application or ?.
All in all there is a lack of efficiency using Windows 8.1 for BLE applications, since all scanning and connection establishment functionalities have to be done in Windows 8.1 settings rather than in your Windows application, which restricts some important algorithms like auto-connection based on RSSI values and so on.

How do I connect a Windows Phone device with an Arduino?

I want to capture distances from sensors, using an Arduino and a Windows Phone device. How can I do that?
The Windows Phone 7 SDK does not give access to the USB port or Bluetooth on the phone, so you can't use that. So I think the best way (and probably only way on Windows Phone 7) would be to communcate over Internet or local network with the Arduino acting as a server which the Windows Phone 7 app connects too.
Here are some examples of an Arduino web server and TCP server.
For the Windows Phone client I would check out either WebClient or sockets.
Windows Phone 8 SDK:
Consider establishing an App to Device communication through Bluetooth API which became available for developers in the release. Bluetooth App to Device application sample, available on MSDN, is the way to go.
There is another option in Windows Phone 8, using Proximity (a set of classes which works with NFC), which is more applicable for a short range communication.
As for Arduino, there is certainly a Bluetooth module.
Windows Phone 7 SDK:
No way to establish a peer-to-peer communication with a third party device. A workaround would be to connect them through a network, as was proposed by Johan.
I have actually made a Windows Phone 8 App that connects to an Arduino using the Sparkfun Bluetooth Silver Modem. Issues is, even after I get them connected, I can't get either the Arduino to receive the input OR I can't get the WP8 App to successfully send to the Arduino...
My GitHub for the project is: https://github.com/lanceseidman/Arduino-Bluetooth-WinPhone8
Hoping everyone can try and help on the project.
My Breadboard photos will be up soon and my Arduino Code.

Windows Phone - Application crashes when disconnected from PC

Whenever I disconnect my Windows Phone from PC (connected through USB) and if my application is running, my application hangs for sometime and then application crashes.
Does anyone experienced same behavior? I guess switching for PC connection to Wi-Fi/GPRS is causing the issue.
the windows Phone Requires that you Safely Remove hardware first, after a few times when i started Development on the windows phone i did the same and Ended up getting a new Phone. So plainly put, try to Safely Remove and Make sure it is installing the app to the Device.
Meaning if you Remove the phone, the App is still able to be ran just like a normal downloaded App form the Market place.
if you want more in depth information, i would suggest Reading the WP7 Everything Programming ebook lol
its filled with good information, and Definitely Helped me along my road to Love DEV for WP7.
As gamernb says, if you disconnect the USB from a properly tethered Windows Phone (i.e. connected to Zune, or using the WPConnect utility), the phone's network connection will be reset and your app's connections will be terminated. The phone will then start trying to connect using WiFi or cellular data (if they are on), but this can take quite a while.
You will have to handle this network disconnection in your app - I've found that pulling the USB cable in this way is a good ad-hoc test for WP7 apps: do an action which you know will use the network connection. Then watch if the app crashes, or handles this gracefully.
Actually you aren't guaranteed to always use the PC data connection: if you make sure that the computer has no data connection (i.e. pull the Ethernet cable, turn off WiFi etc ), the WP7 app can then use cellular data or WiFi on the phone instead.
Alas-
you could set perimeters in your application to Check what the connection type is, then Make changes accordingly.
You May have a slight freeze, but that's better then a crash....mainly when the phone switches from PC to WWAN, their would be a slight Pause.
use the Reachability Class and NSLog to Figure out whats going on exactly.
I really hope that helps!

Debugging Windows Phone 7 device traffic with Fiddler

I followed all the steps from the article but when I try to hit the server from my windows phone it says there is a dns error.
Article for reference.
http://blogs.msdn.com/b/fiddler/archive/2011/01/09/debugging-windows-phone-7-device-traffic-with-fiddler.aspx
How do I know my windows phone is using my local LAN WIFI as opposed to ATT cellular?
Personally, I use Netmon 2.3 for network traffic information from WP7. Fiddler didn't support WP7 up until recently and Netmon/Wireshark did, so I just stick with those.
Using Netmon 2.3, while your device is connected to Zune/WPConnect, you'd be able to see all WP7 device transport on the ZuneComm process. Netmon isn't as user-friendly as Fiddler, but it's fairly darn specific and easy.
You could turn on flight mode and then turn wifi back on.
Or you could take the sim out.
Either of those ways will ensure you're not using the cellular network.
I used the IP address instead of dns and it worked.

Resources