watchOS 2 reachability - reachability

How can I determine the reachability in watchOS2?
If I import reachability.h, Xcode doesn't find the SystemConfiguration.h framework.

Looks like Apple removed SystemConfiguration from the list of watchOS supported system frameworks: https://developer.apple.com/library/prerelease/watchos/documentation/General/Conceptual/AppleWatch2TransitionGuide/LeverageSystemTechnologies.html
It use to be there at the time of the WWDC Keynote announcement however I could not see the framework in early betas (there was also an empty API documentation page in the prerelease library) however they appear to have updated the site and removed it from the list.
I can only assume that this means you won't be able to detect the watches reachability status what is a pain because NSNetServiceBrowser doesn't appear to work while my watch is connected to my phone (as the WiFi chip is powered down and network requests are handled over BLE via the phone instead).

Related

React Native app is recognized as a game on Samsung Note8

I wrote react native application. The application is simple, more informational, it is used by Redux, Saga, several linked npm packages. The app runs in normal mode, not full-screen. The structure of the application was built on the basis of Ignite.
The problem is that on the phone (Samsung Note8) the application is recognized as a game. E.g. while app is running there is a message "The game is running" on the lock screen. Also there are additional buttons for the gamepad or something like that. In additional, app has a paddings on the top and on the bottom when it's working on real device (Samsung Note8). This effect real exists when some games running. When app is running on another device (e.g. ZTE Blade 610) it's running as usual and without any side effects.
The main version is the cause of all is Game Tools that's existed on Samsung Note8 but others apps have no similar effects and running as expected.
Is there a possibility to make a react native app as a real app but not a game? Why Game Tools recognizes my app as a game? Or what is the reason and how can it be affected?
Thanks.
I think there are few possibilities.
you (or one of your dependencies) have included the google play service API which inside of play service API has a module named games that samsung will automatically treat it as game.
You could find which of your dependency is loading google play service API and create a exclude like:
compile (project ('your.dependency')){
exclude group: 'com.google.android.gms', module:'play-services-game'
}
Your application id (can see on build.gradle) is registered on samsung game database. You could check by going into playstore and search for your application id
this is something that can happen on samsung phones due to the package name of your app.
we cant change this after the initial release, you must contact samsung developer support and they can fix it on the fly.
i wrote a gist on github about it:
https://gist.github.com/Adnan-Bacic/718eb3b4e70380696c91dc21c4804112

Are Google-Fit API available on Android TV?

My sample app using GoogleFit API of GooglePlayServices runs on Android mobile (using Android-M) but the same sample app gives error as API_UNAVAILABLE on Android TV (using Android-M) even though PlayServices version is latest version on TV.
My intention is to only to READ the Google-fit data.
Is it so that device like TV might not have health/fitness sensors and hence GooglePlayServices does not enable Google-Fit API (even though an application might be only interested in reading data)?
Any pointers available on this on how to enable GoogleFit APIs on Android TV?
EDIT1
Tried with 365 Body Workout apk https://play.google.com/store/apps/details?id=com.peirr.workout.play&hl=en on AndroidTV having latest GooglePlayServices [11.5.09 (836-164803921)] and found that it does not work as indicated in the below picture

Where to find the iHasApp framework?

my app got rejected 2 times due to this issue:
"Specifically, we found that this app checks for all apps installed on this device by scanning all known URL schemes using a service called iHasApp"
My code doesn't have the iHasApp framework, i tried to search for it but i can't find it.
Your code must be using iHasApp and now a days apple is rejecting this kind of app. iHasApp misuses "canOpenURL:".

Bluetooth LE on iOS cannot work with many services and characteristics

I develop a BLE application, using Core Bluetooth in my iPhone app.
My iPhone communicates with linux with bleno launched.
The problem is that it cannot work with more than one characteristic or service, though just one characteristic works nice.
Here is my code for iOS and .js code for Node.js:
http://pastebin.com/k5pUrbLt
http://pastebin.com/biCWLmJ3
Thank you!
P.S. That's what i get in console:
2014-07-24 13:18:02.819 lexy[142:60b] didDiscoverPeripheral
2014-07-24 13:18:04.503 lexy[142:60b] didDiscoverServices
2014-07-24 13:18:04.506 lexy[142:60b] D61191C0-FCE8-4F5A-912C-15EE39D927B4
I.e. I successfully discover and connect to the peripheral, but I do not find any characteristics. In that case I have one service with many characteristics.
iOS can work with multiple characteristics and multiple services on a remote device.
Your ObjC code seems okay (1 service with 2 characteristics).
Console output suggests that you send a discoverCharacteristics request but that it hangs and never returns. You could add logging to the didDisconnectPeripheral delegate method to see if there is a disconnect happening.
What you could also do is to look at the logs of the Bluetooth stack and to compare them to how the logs look like if you access a TI Sensor Tag (those tags are the hello world of BLE).
iOS 7.1 instructions for Bluetooth logs are located here, for iOS 8 you'll have to resort to Apple's official way to get the logs (installation of a configuration profile) but their logs contain less information than the ones by BluetoothCompanion.
Apparently, it works on Ubuntu 14.04, but doesn't work on OpenSuse 13.1.

UIRequiredDeviceCapabilities equivalent for Mac App Store?

I am developing a Mac app that is only useful for laptop owners (MacBooks) and plan on distributing this app on the Mac App Store. For the iOS App Store, you can specify in the plist UIRequiredDeviceCapabilities so that only users with the proper device can see the app in the store. Is there a way to do the same with the Mac App Store?
From page 39 of the iTunes Connect Developer Guide:
If your iOS app requires a specific device capability (i.e. telephony,
GPS, accelerometer, etc.) to function properly, you will need to be
sure to code this into the info.plist of your binary utilizing the
UIRequiredDeviceCapabilities key. Refer to the Build-Time
Configuration Details section of the iOS Application Programming
Guide to learn more. At runtime, iOS cannot launch your application
unless the declared capabilities are present on the device. Further,
the App Store requires this information so that it can generate a
list of requirements for user devices and prevent users from
downloading applications that they cannot run. It is not necessary to
specify required device capabilities for Mac OS X apps.
While there is no equivalent to UIRequiredDeviceCapabilities, some capabilities can be specified in a PreInstallRequirements.plist.
This approach let you specify minimum RAM, GPU capabilities, minimum minversions.
See here:
Mac app store productbuild
https://developer.apple.com/library/archive/qa/qa1748/_index.html#//apple_ref/doc/uid/DTS40011181
https://developer.apple.com/library/archive/documentation/DeveloperTools/Reference/DistributionDefinitionRef/Chapters/Distribution_XML_Ref.html