[MOD] Working Samsung Gear App for non (also rooted) Samsung devices.

Status
Not open for further replies.
Search This thread

j to the 4n

Recognized Developer
Oct 18, 2012
16,153
44,266
33
apktool d -b -f Freetime.apk xda
Update 12.10.2017

UPDATE
There is a new Gear S Plugin update available in PlayStore. They fixed the crashes, everything is working now.

Looks like even the modded gear app is not needed anymore. But I will check this later.

Sent from my HTC 10 using XDA Labs

Can confirm, updated to the latest Gear S Plugin and latest unmodded Gear App and everything is working properly on my HTC 10.

Gear App 2.2.17022862
Gear S Plugin 2.2.03.17101142N


In our Viper10 Thread we had multiple reports, that the Samsung Gear app force closes when trying to connect their device.

Seemed not just the HTC10 is affected though. From my google research I found also some logcats from other roms and devices posted with the same issue.
@Toni10 linked me to that thread today, opened by @kajos in the Samsung Gear S3 Forum..so it seems it's really a general issue.

Okay, so what is the issue:

Code:
-27 21:10:15.357 E/AndroidRuntime(6044): FATAL EXCEPTION: main
11-27 21:10:15.357 E/AndroidRuntime(6044): Process: com.samsung.android.app.watchmanager, PID: 6044
11-27 21:10:15.357 E/AndroidRuntime(6044): java.lang.NoClassDefFoundError: Failed resolution of: Lcom/samsung/android/feature/FloatingFeature;
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.sdllibrary.FloatingFeature.getEnableStatus(FloatingFeature.java:11)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.twatchmanager.log.LoggerUtil$Builder.<clinit>(LoggerUtil.java:95)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.twatchmanager.util.HostManagerUtils.startPluginActivity(HostManagerUtils.java:551)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.callPluginActivity(HMConnectFragment.java:377)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.callPluginActivityWithDelay(HMConnectFragment.java:365)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.access$200(HMConnectFragment.java:67)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment$1.handleMessage(HMConnectFragment.java:315)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.os.Handler.dispatchMessage(Handler.java)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.os.Looper.loop(Looper.java)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.app.ActivityThread.main(ActivityThread.java)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.reflect.Method.invoke(Native Method)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
11-27 21:10:15.357 E/AndroidRuntime(6044): Caused by: java.lang.ClassNotFoundException: Didn't find class "com.samsung.android.feature.FloatingFeature" on path: DexPathList[[zip file "/data/app/com.samsung.android.app.watchmanager-1/base.apk"],nativeLibraryDirectories=[/data/app/com.samsung.android.app.watchmanager-1/lib/arm64, /system/fake-libs64, /data/app/com.samsung.android.app.watchmanager-1/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:380)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
11-27 21:10:15.357 E/AndroidRuntime(6044): 	... 13 more

Bad coding, or intended, no idea.

A framework class com.samsung.android.feature.FloatingFeature is not found on none samsung devices.
I took the effort to decompile the sams h i t app and digged in the code and backtraced the issue.

The source of the bug (or intended behavior) is the samsung device detection:

Code:
.method public static isSamsungDevice()Z
    .locals 1

    invoke-static {}, Lcom/samsung/android/app/twatchmanager/TWatchManagerApplication;->getAppContext()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/samsung/android/app/twatchmanager/util/InstallationUtils;->hasInstallPermission(Landroid/content/Context;)Z

    move-result v0

    return v0
.end method

It also returns true even on none samsung devices.
Not sure why that fails. it checks if it can get android.permission.INSTALL_PACKAGES...that perm can be just granted to apps in /system.
So moving the app to /system should work too, to fix the issue for rooted users...still it should return falls and not true on none samsung devices that dont't have it on /system

The result of it is that causes the app to crash in LoggerUtil$Builder:

Code:
.method static constructor <clinit>()V
    .locals 2

    invoke-static {}, Lcom/samsung/android/app/twatchmanager/util/HostManagerUtils;->isSamsungDevice()Z

    move-result v0

    if-eqz v0, :cond_0

    invoke-static {}, Lcom/samsung/android/app/twatchmanager/util/FloatingFeatureFactory;->get()Lcom/samsung/android/app/watchmanager/libinterface/FloatingFeatureInterface;

    move-result-object v0

    const-string v1, "SEC_FLOATING_FEATURE_CONTEXTSERVICE_ENABLE_SURVEY_MODE"

    [COLOR="red"]invoke-interface {v0, v1}, Lcom/samsung/android/app/watchmanager/libinterface/FloatingFeatureInterface;->getEnableStatus(Ljava/lang/String;)Z[/COLOR]

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    sput-boolean v0, Lcom/samsung/android/app/twatchmanager/log/LoggerUtil$Builder;->SUPPORT_LOGGING:Z

    return-void

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

that tries to access an method in a class just available on a samsung device and its framework:

Code:
.method public getEnableStatus(Ljava/lang/String;)Z
    .locals 1

    invoke-static {}, Lcom/samsung/android/feature/FloatingFeature;->getInstance()Lcom/samsung/android/feature/FloatingFeature;

    move-result-object v0

    [COLOR="red"]invoke-virtual {v0, p1}, Lcom/samsung/android/feature/FloatingFeature;->getEnableStatus(Ljava/lang/String;)Z[/COLOR]

    move-result v0

    return v0
.end method

It's the only location where a call requires the samsung framework.

So how to fix it:

We just modify the device detection method to return always false:

Code:
.method public static isSamsungDevice()Z
    .locals 1

    const/4 v0, 0x0

    return v0
.end method

...recompile, resign and it's done.

So far I got 4 reports that it indeed works...so it should also for others.
Since I had to resign the app, ensure you uninstall the original one before installing the fixed version.

When an update in playstore drops for the gear app, and it still force closes, uninstall it and install my fixed version again.
Since I won't monitor that thread...someone should shoot me a PM, so I can merge my fix to the new version from playstore.



Code:
[B]Update 06.09.17[/B] 
Samsung Gear to fix custom binary message on samsung devices
Gear S Plugin 2.2.03.17061361
Samsung Health 5.12.0.025

[B]Update 30.06.17[/B] 
Accessory Service 3.1.51.70612
Gear S Plugin 2.2.03.17041441N
Samsung Health 5.9.1.003

[B]Update 02.04.17[/B] 
Accessory Service 3.1.39_170322

[B]Update 01.04.17[/B] 
Samsung Gear 2.2.17022862
Gear S Plugin v2.2.03.17032442N

[B]Update 08.02.17[/B] 
Added modifications to new [URL="http://www.tizenexperts.com/2017/01/samsung-gear-manager-application-gear-smartwatches-updated-2-2-16121661/?utm_content=buffer51605&utm_medium=social&utm_source=twitter.com&utm_campaign=buffer"]Gear App 2.2.16121661[/URL]

[B]Update 03.02.17[/B]
The installation issue some people were having seems to got resolved by signing the Gear S Plugin and Samsung Accessory Service with the same signature as the resigned Gear App.
All three files are uploaded on Google Drive now (xda does not allow zips > 20mb, and no single apks > 8MB)


Downloads:
Samsung Gear Apps

 
Last edited:

sEsE123

Member
Oct 24, 2008
10
8
Thank you very much for your work on this, I was looking for this for almost a month. :)

I can confirm its working on Xiamoi MI 4S with xiaomi.eu ROM (8.1.3)
 

Kikill3r

Senior Member
Nov 1, 2013
112
71
Depends what the force close is, do you have a logcat?
I can make one :)
I'll flash the app and report back
If you manage to do this, the entire AOSP community will love you, I guarantee it. I have a Galaxy S7 on AOSP and the camera quality in the stock AOSP camera app is horrible. I've been looking everywhere for a S7 TouchWiz camera app port that works on AOSP, but none of them work

Oh yes I forgot to say, the app is a flashable zip that also contains frameworks and libraries and so on. Will this be a problem?
 
Last edited:

j to the 4n

Recognized Developer
Oct 18, 2012
16,153
44,266
33
apktool d -b -f Freetime.apk xda
Here you go, I got the logcat and the flashable zip for you. I hope you can do anything with it... :/

Link for zip: https://mega.nz/#!jE9TzTYQ!BzlWWYYIeNAYkpdlCAi853PWvlVGdIwEQhlMepNUqSo

...was a different issue. It expects some logging methods in the framework that does not exist in yours.
I removed all the calls...but it might crash elsewhere

push the file to /system/app/SamsungCamera5

...no idea how your manufacturer handles sigantures or if your rom got signature checks removed.
it if does not work, try to install the signed apk manually
 

Attachments

  • SamsungCamera5.apk
    9 MB · Views: 80
  • SamsungCamera5-signed.apk
    9.1 MB · Views: 120
  • Like
Reactions: hav0c

kajos

Senior Member
Dec 5, 2009
553
186
Niedersachsen
@j to the 4n

I have not bought the the Gear S3 again yet, but tried to install the modified apk on my phone to test
This works, but now I can't install the associated apps Gear S Plugin and Samsung Accessory Service
The apps are downloaded and will install, but then an error message appears (s. screenshot in the attachment)
When reinstalling the original app, the installation of the additional apps will work again
I do not think this can work like this with the watch

Are you able to fix that?

My phone is the Huawei MediaPad X2, stock rom 5.0
https://forum.xda-developers.com/gear-s3/themes/how-to-gear-s3-unsupporteted-android-t3521532

----------------------------------------------------------------------
In Deinen Daten sehe ich, dass Du aus Deutschland kommst.
Da mein English nicht (mehr) so gut ist, hier nochmal das selbe Thema auf Deutsch (etwas ausführlicher):

Erst einmal herzlich Dank für Deine Bemühungen, den Absturzproblemen der GearApp auf den Grund zu gehen.
Ich bin bereits einige Zeit dabei, für die Suche nach einer Lösung zu werben.
Wegen der drehbaren Lünette hatte ich die Gear S3 bei Amazon bereits vorbestellt gehabt, weil ich mit der Bedienung von Android-Wear nicht so zufrieden bin, trotzdem die HuaweiWatch grundsäztlich einwandfrei funktioniert.

Leider zeigte sich dann, dass die GearApp für mein Phone nicht einmal im Playstore angeboten wird, also habe ich die apk über meinen Bluestacks Player auf dem PC gezogen, denn dieser erlaubt verrückterweise den Download, vermutlich weil er sich als Samsung-Device ausgibt.
So hat die Installation dann auch problemlos funktioniert
In den beiden Zusatzapps ist interessanterweise keine derartige Restriktion eingebaut, sodass diese geradeaus über den PlayStore, auch für das X2 aufrufbar sind.

Leider stürzte die GearApp dann zum Start der Installation der S3 ab, (die Bluetooth-Erkennung funktioniert noch) genau dann, wenn auf den Playstore zur Install der 'Gear S Plugin App' verwiesen wird, sollte diese noch nicht auf dem Phone sein, wohl genauso, wie bei vielen Custom-Roms.
Deshalb hatte ich die Uhr erst einmal wieder zurückgegeben.

Mit der von dIr kreierten, modifzierten App habe ich nun eine neue, bis dahin unbekannte Erscheinung (s. Screenshot):
Mit der Installation lassen sich die beiden Zusatzapps nicht mehr aufspielen, weil deren Install. mit einer Fehlermeldung abgebrochen wird.
Nach dem Deinstall. und Install. der originalen, funktioniert das mit den Zusatzapps wieder störungsfrei

Ich habe übrigens auch mit einer Integration der GearApp in das System experimentiert, weil sich so u.A. das bisw. "etwas zickige" Huawei Berechtigungsystem umgehen läßt, aber selbst das bringt leider keine Änderung...
(mein X2 ist also rooted, die Software aber ansonsten komplett Serie (Andriod-Version 5.0))

Es wäre schön, wenn sich auch hier eine Lösung finden würde.
Denn sollte das Update auf AndroidWear2.0, welches für den 9.Februar angesagt ist, keine entscheidenden Verbesserungen in der Bedienung bringen, würde ich es mit der Gear S3 gern nochmals versuchen.
 

Attachments

  • Screenshot_2017-01-31-20-45-07.jpg
    Screenshot_2017-01-31-20-45-07.jpg
    129.7 KB · Views: 838
Last edited:

j to the 4n

Recognized Developer
Oct 18, 2012
16,153
44,266
33
apktool d -b -f Freetime.apk xda
@j to the 4n

I have not bought the the Gear S3 again yet, but tried to install the modified apk on my phone to test
This works, but now I can't install the associated apps Gear S Plugin and Samsung Accessory Service
The apps are downloaded and will install, but then an error message appears (s. screenshot in the attachment)
When reinstalling the original app, the installation of the additional apps will work again
I do not think this can work like this with the watch

Are you able to fix that?

My phone is the Huawei MediaPad X2, stock rom 5.0
https://forum.xda-developers.com/gear-s3/themes/how-to-gear-s3-unsupporteted-android-t3521532

----------------------------------------------------------------------
In Deinen Daten sehe ich, dass Du aus Deutschland kommst.
Da mein English nicht (mehr) so gut ist, hier nochmal das selbe Thema auf Deutsch (etwas ausführlicher):

Erst einmal herzlich Dank für Deine Bemühungen, den Absturzproblemen der GearApp auf den Grund zu gehen.
Ich bin bereits einige Zeit dabei, für die Suche nach einer Lösung zu werben.
Wegen der drehbaren Lünette hatte ich die Gear S3 bei Amazon bereits vorbestellt gehabt, weil ich mit der Bedienung von Android-Wear nicht so zufrieden bin, trotzdem die HuaweiWatch grundsäztlich einwandfrei funktioniert.

Leider zeigte sich dann, dass die GearApp für mein Phone nicht einmal im Playstore angeboten wird, also habe ich die apk über meinen Bluestacks Player auf dem PC gezogen, denn dieser erlaubt verrückterweise den Download, vermutlich weil er sich als Samsung-Device ausgibt.
So hat die Installation dann auch problemlos funktioniert
In den beiden Zusatzapps ist interessanterweise keine derartige Restriktion eingebaut, sodass diese geradeaus über den PlayStore, auch für das X2 aufrufbar sind.

Leider stürzte die GearApp dann zum Start der Installation der S3 ab, (die Bluetooth-Erkennung funktioniert noch) genau dann, wenn auch der Playstore zur Install der 'Gear S Plugin App' verweist, sollte diese noch nicht auf dem Phone sein, wohl genauso, wie bei vielen Custom-Roms.
Deshalb hatte ich die Uhr erst einmal wieder zurückgegeben.

Mit der von dIr kreierten, modifzierten App habe ich nun eine neue, bis dahin unbekannte Erscheinung (s. Screenshot):
Mit der Installation lassen sich die beiden Zusatzapps nicht mehr aufspielen, weil deren Install. mit einer Fehlermeldung abgebrochen wird.
Nach dem Deinstall. und Install. der originalen, funktioniert das mit den Zusatzapps wieder störungsfrei

Ich habe übrigens auch mit einer Integration der GearApp in das System experimentiert, weil sich so u.A. das bisw. "etwas zickige" Huawei Berechtigungsystem umgehen läßt, aber selbst das bringt leider keine Änderung...
(mein X2 ist also rooted, die Software aber ansonsten komplett Serie (Andriod-Version 5.0))

Es wäre schön, wenn sich auch hier ein Lösung finden würde.
Denn sollte das Update auf AndroidWear2.0, welches für den 9.Februar angesagt ist, keine entscheidenden Verbesserungen in der Bedienung bringen, würde ich es mit der Gear S3 gern nochmals versuchen.
Never saw such behavior, that playstore denies installations of dependent apps. If you have no gear app installed at all, you can't install the apps?

..well you could always install the original gear, then the other apps. Uninstall the gear app, then install mine?
..also the apps are available on apkmirror, you can download and install them from there.

Not sure sure why it seem to work for all others...

Want to make one thing clear here though: I don't own gear myself and never will..I'm just a good guy that wanted to help out some of gear users on our rom (HTC 10).
Means i can't do any deeper debugging, besides reading logs people provide me.

I'm also very confused why no other dev (that owns a gear, and is familar with it and Samsung) looked into it, because it was an really easy fix.
 
Last edited:
  • Like
Reactions: kajos and Black-FR

kajos

Senior Member
Dec 5, 2009
553
186
Niedersachsen
..well you could always install the original gear, then the other apps. Uninstall the gear app, then install mine?
.


- original + GearSPlugin + SamsungAcessoryService works
- delete original + install mod not working : error message
- delete all 3 apps + install mod working + GearSPlugin + SamsungAcessoryService not working : error message
 

tgtoys

Senior Member
Feb 10, 2008
645
140
Chicago
Wait a minute....so you're saying I can FINALLY use my Samsung Gear S with a non-samsung phone?!?! I've been waiting soo, soooo long for this. Can't wait to give it a shot.
Thank you very much for your work!
 
  • Like
Reactions: j to the 4n

j to the 4n

Recognized Developer
Oct 18, 2012
16,153
44,266
33
apktool d -b -f Freetime.apk xda
- original + GearSPlugin + SamsungAcessoryService works
- delete original + install mod not working : error message
- delete all 3 apps + install mod working + GearSPlugin + SamsungAcessoryService not working : error message
What error message you get when you have the other apps installed and then install my modded version?
 
  • Like
Reactions: hav0c

kajos

Senior Member
Dec 5, 2009
553
186
Niedersachsen
What error message you get when you have the other apps installed and then install my modded version?

I tried it again now!

- all Samsung Apps are deinstalled on my Phone
then
- Gear S Plugin + Samsung Accessoire Service install
then
- your mod

see attachment

(I'm able to install your mod without them, but no way along with)
 

Attachments

  • Screenshot_2017-02-01-11-43-53.png
    Screenshot_2017-02-01-11-43-53.png
    56.3 KB · Views: 724
Status
Not open for further replies.

Top Liked Posts

  • There are no posts matching your filters.
  • 68
    Update 12.10.2017

    UPDATE
    There is a new Gear S Plugin update available in PlayStore. They fixed the crashes, everything is working now.

    Looks like even the modded gear app is not needed anymore. But I will check this later.

    Sent from my HTC 10 using XDA Labs

    Can confirm, updated to the latest Gear S Plugin and latest unmodded Gear App and everything is working properly on my HTC 10.

    Gear App 2.2.17022862
    Gear S Plugin 2.2.03.17101142N


    In our Viper10 Thread we had multiple reports, that the Samsung Gear app force closes when trying to connect their device.

    Seemed not just the HTC10 is affected though. From my google research I found also some logcats from other roms and devices posted with the same issue.
    @Toni10 linked me to that thread today, opened by @kajos in the Samsung Gear S3 Forum..so it seems it's really a general issue.

    Okay, so what is the issue:

    Code:
    -27 21:10:15.357 E/AndroidRuntime(6044): FATAL EXCEPTION: main
    11-27 21:10:15.357 E/AndroidRuntime(6044): Process: com.samsung.android.app.watchmanager, PID: 6044
    11-27 21:10:15.357 E/AndroidRuntime(6044): java.lang.NoClassDefFoundError: Failed resolution of: Lcom/samsung/android/feature/FloatingFeature;
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.sdllibrary.FloatingFeature.getEnableStatus(FloatingFeature.java:11)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.twatchmanager.log.LoggerUtil$Builder.<clinit>(LoggerUtil.java:95)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.twatchmanager.util.HostManagerUtils.startPluginActivity(HostManagerUtils.java:551)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.callPluginActivity(HMConnectFragment.java:377)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.callPluginActivityWithDelay(HMConnectFragment.java:365)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment.access$200(HMConnectFragment.java:67)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.samsung.android.app.watchmanager.setupwizard.HMConnectFragment$1.handleMessage(HMConnectFragment.java:315)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.os.Handler.dispatchMessage(Handler.java)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.os.Looper.loop(Looper.java)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at android.app.ActivityThread.main(ActivityThread.java)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.reflect.Method.invoke(Native Method)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
    11-27 21:10:15.357 E/AndroidRuntime(6044): Caused by: java.lang.ClassNotFoundException: Didn't find class "com.samsung.android.feature.FloatingFeature" on path: DexPathList[[zip file "/data/app/com.samsung.android.app.watchmanager-1/base.apk"],nativeLibraryDirectories=[/data/app/com.samsung.android.app.watchmanager-1/lib/arm64, /system/fake-libs64, /data/app/com.samsung.android.app.watchmanager-1/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:380)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    11-27 21:10:15.357 E/AndroidRuntime(6044): 	... 13 more

    Bad coding, or intended, no idea.

    A framework class com.samsung.android.feature.FloatingFeature is not found on none samsung devices.
    I took the effort to decompile the sams h i t app and digged in the code and backtraced the issue.

    The source of the bug (or intended behavior) is the samsung device detection:

    Code:
    .method public static isSamsungDevice()Z
        .locals 1
    
        invoke-static {}, Lcom/samsung/android/app/twatchmanager/TWatchManagerApplication;->getAppContext()Landroid/content/Context;
    
        move-result-object v0
    
        invoke-static {v0}, Lcom/samsung/android/app/twatchmanager/util/InstallationUtils;->hasInstallPermission(Landroid/content/Context;)Z
    
        move-result v0
    
        return v0
    .end method

    It also returns true even on none samsung devices.
    Not sure why that fails. it checks if it can get android.permission.INSTALL_PACKAGES...that perm can be just granted to apps in /system.
    So moving the app to /system should work too, to fix the issue for rooted users...still it should return falls and not true on none samsung devices that dont't have it on /system

    The result of it is that causes the app to crash in LoggerUtil$Builder:

    Code:
    .method static constructor <clinit>()V
        .locals 2
    
        invoke-static {}, Lcom/samsung/android/app/twatchmanager/util/HostManagerUtils;->isSamsungDevice()Z
    
        move-result v0
    
        if-eqz v0, :cond_0
    
        invoke-static {}, Lcom/samsung/android/app/twatchmanager/util/FloatingFeatureFactory;->get()Lcom/samsung/android/app/watchmanager/libinterface/FloatingFeatureInterface;
    
        move-result-object v0
    
        const-string v1, "SEC_FLOATING_FEATURE_CONTEXTSERVICE_ENABLE_SURVEY_MODE"
    
        [COLOR="red"]invoke-interface {v0, v1}, Lcom/samsung/android/app/watchmanager/libinterface/FloatingFeatureInterface;->getEnableStatus(Ljava/lang/String;)Z[/COLOR]
    
        move-result v0
    
        if-eqz v0, :cond_0
    
        const/4 v0, 0x1
    
        :goto_0
        sput-boolean v0, Lcom/samsung/android/app/twatchmanager/log/LoggerUtil$Builder;->SUPPORT_LOGGING:Z
    
        return-void
    
        :cond_0
        const/4 v0, 0x0
    
        goto :goto_0
    .end method

    that tries to access an method in a class just available on a samsung device and its framework:

    Code:
    .method public getEnableStatus(Ljava/lang/String;)Z
        .locals 1
    
        invoke-static {}, Lcom/samsung/android/feature/FloatingFeature;->getInstance()Lcom/samsung/android/feature/FloatingFeature;
    
        move-result-object v0
    
        [COLOR="red"]invoke-virtual {v0, p1}, Lcom/samsung/android/feature/FloatingFeature;->getEnableStatus(Ljava/lang/String;)Z[/COLOR]
    
        move-result v0
    
        return v0
    .end method

    It's the only location where a call requires the samsung framework.

    So how to fix it:

    We just modify the device detection method to return always false:

    Code:
    .method public static isSamsungDevice()Z
        .locals 1
    
        const/4 v0, 0x0
    
        return v0
    .end method

    ...recompile, resign and it's done.

    So far I got 4 reports that it indeed works...so it should also for others.
    Since I had to resign the app, ensure you uninstall the original one before installing the fixed version.

    When an update in playstore drops for the gear app, and it still force closes, uninstall it and install my fixed version again.
    Since I won't monitor that thread...someone should shoot me a PM, so I can merge my fix to the new version from playstore.



    Code:
    [B]Update 06.09.17[/B] 
    Samsung Gear to fix custom binary message on samsung devices
    Gear S Plugin 2.2.03.17061361
    Samsung Health 5.12.0.025
    
    [B]Update 30.06.17[/B] 
    Accessory Service 3.1.51.70612
    Gear S Plugin 2.2.03.17041441N
    Samsung Health 5.9.1.003
    
    [B]Update 02.04.17[/B] 
    Accessory Service 3.1.39_170322
    
    [B]Update 01.04.17[/B] 
    Samsung Gear 2.2.17022862
    Gear S Plugin v2.2.03.17032442N
    
    [B]Update 08.02.17[/B] 
    Added modifications to new [URL="http://www.tizenexperts.com/2017/01/samsung-gear-manager-application-gear-smartwatches-updated-2-2-16121661/?utm_content=buffer51605&utm_medium=social&utm_source=twitter.com&utm_campaign=buffer"]Gear App 2.2.16121661[/URL]
    
    [B]Update 03.02.17[/B]
    The installation issue some people were having seems to got resolved by signing the Gear S Plugin and Samsung Accessory Service with the same signature as the resigned Gear App.
    All three files are uploaded on Google Drive now (xda does not allow zips > 20mb, and no single apks > 8MB)


    Downloads:
    Samsung Gear Apps

    10
    If the apps get updated, please upload them for me here or elsewhere and mention my name.

    Update 30.06.17
    Accessory Service 3.1.51.70612
    Gear S Plugin 2.2.03.17041441N
    Samsung Health 5.9.1.003
    8
    66 downloads, seems a a few waited for that fix :p
    5
    Can confirm, updated to the latest Gear S Plugin and latest unmodded Gear App and everything is working properly on my HTC 10.

    Gear App 2.2.17022862
    Gear S Plugin 2.2.03.17101142N
    Cool, the for the feedback.

    No need for that thread anymore then :)
    4
    hi @j to the 4n
    i was using ur samsung gear s3 fix app found @ hub in viper rom until yesterday. from yesterday i cant seem to connect it....what i mean is phone is connected to samsung gear s3 via bluetooth... but when i log into samsung gear app , i cant connect it. so basically i cant do anything. i mean changing watchface, upgrading apps , nothing.
    i got a logcat 4 u. i dont know if this wil help . let me know if u need more information.. ur help will be highly appriciated

    https://www.dropbox.com/s/khjg867retjfdjt/report_2017-02-17-12-39-48.zip?dl=0

    logcat is empty, you most like selected "FC Only" in VenomTweaks, when you took the log.

    Did you try to install the new versions linked in the OP? Install all three.
    ..probably one of them got updated by the playstore and the signatures don't match anymore.


    @ All - Without a clock myself, it's impossible for me to fix the different issues people are reporting here. It seems its even phone dependant, since it seems it works for most, but for some not?
    What's a bit depressing is, that we got almost 1000 downloads and just a handful positive feedback if it works. I assume it does work for the most, and for those where it's not they reported it here? (-:

    Also reporting that it does not work, does not help. Provide a logcat each time you have an issue.
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone