SpO2 TPK

Search This thread

EQMOD

Member
Nov 1, 2017
26
1
Is there a way to extract the SpO2 tpk file from the Galaxy Watch 3 ? I have both watches GW3 and Active 2. I am planning to sideload the SpO2 on the Active 2. Thanks.
 
  • Like
Reactions: Shammy7861

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
A

Blood Oxygen is NO Standalone TPK nor WGT...

It is inside the "magic" Samsung Health package:
Code:
com.samsung.shealth_gear


B
This crap is started as Widget... no idea how exactly it is enablde/disabled for France etc...

Maybe by Plugin APK crap...

C
Code:
tizen-manifest.xml

From Version 4.12.1200

Code:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<manifest xmlns="http://tizen.org/ns/packages" api-version="5.5.0.1" package="com.samsung.shealth_gear" version="[B]4.12.1200[/B]">
    <profile name="wearable"/>
    <ui-application

At end of manifest....
Code:
</widget-class>
        <[COLOR="Red"][B]widget-class classid[/B][/COLOR]="[COLOR="Red"]oxygensaturation[/COLOR]" max-instance="1" update-period="0">
            <!-- DREAM_HEALTH_HEADER_BLOOD_OXYGEN -->
            <label xml:lang="ar-ae">الأكسجين في الدم</label>
            <label xml:lang="ar-il">الأكسجين في الدم</label>
            <label xml:lang="as-in">তেজৰ অক্সিজেন</label>
            <label xml:lang="az-az">Qanda oksigen həcmi</label>
            <label xml:lang="be-by">Кісларод у крыві</label>
            <label xml:lang="bg-bg">Кислород в кръвта</label>
            <label xml:lang="bn-bd">রক্তে অক্সিজেন</label>
            <label xml:lang="bn-in">রক্তে অক্সিজেন</label>
            <label xml:lang="bo-cn">血氧</label>
            <label xml:lang="bs-ba">Kisik u krvi</label>
            <label xml:lang="ca-es">Oxigen en sang</label>
            <label xml:lang="cs-cz">Hladina kyslÃ*ku v krvi</label>
            <label xml:lang="da-dk">Iltmætning i blodet</label>
            <label xml:lang="de-at">Blutsauerstoff</label>
            <label xml:lang="de-ch">Blutsauerstoff</label>
            <label xml:lang="de-de">Blutsauerstoff</label>
            <label xml:lang="el-gr">Οξυγόνο αίματος</label>
            <label xml:lang="en-au">Blood oxygen</label>
            <label xml:lang="en-ca">Blood oxygen</label>
            <label xml:lang="en-gb">Blood oxygen</label>
            <label xml:lang="en-ie">Blood oxygen</label>
            <label xml:lang="en-nz">Blood oxygen</label>

This leads to
D

Search in BTG6 GW3 Firmwares... leads to this inside rootfs.img instead csc.img...
Code:
usr/apps/com.samsung.w-home/bin/[B]w-home[/B]

Code:
oxygensaturation[B]@[/B]com.samsung.shealth.widget

E

I am at the moment only smart enough to call apps via Commands...
https://forum.xda-developers.com/showpost.php?p=83481485&postcount=2007

But no idea how this Widget crap...

Code:
F
No Firmwarefiles for Tizen 5.5 leaked to do stupid tests inside Firmware... :(

I mean no CTH8 nor CTI4 for SM-R820...

Maybe somebody have faster solution for testing... :angel:

Best Regards

Edit 1.

Nice Video:
https://www.youtube.com/watch?v=qyul_jA8kWI

Here we can see 2 ways of start...

A
By open Shealth TPK on Watch...

B
Widget crap....

Edit 2.

Sitting on WC... ehm I mean during hard work..
Got an idea...

Watch Face maybe could call such kind of Widget...
But first I have checked BTG6 Firmware from GW3 for text string:
Code:
com.samsung.shealth.widget

Found this script... so we are agin in SQLite database world... :D :rolleyes:
Code:
#!/bin/bash
#
# RW Update Script for 3.0 -> 4.0
PATH=/bin:/usr/bin:/sbin:/usr/sbin
source /usr/share/upgrade/rw-update-macro.inc
get_version_info

#db
HOMEDB=/opt/usr/home/owner/apps_rw/com.samsung.w-home/data/.home.db
if [ ! -e $HOMEDB ]; then
HOMEDB=/opt/usr/apps/com.samsung.w-home/data/.home.db
fi

if [ "$OLD_VER" = "unknown" ]; then

echo "upgrade home DB HOME DB:$HOMEDB"

/usr/bin/sqlite3 $HOMEDB "update home set id = 'com.samsung.app-shortcut-widget' where id='com.samsung.app-widget.widget';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.pedometer';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.hrlog';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.exercise';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.heartrate';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.intake';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.together';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.together.leaderboard';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.together.challenge';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.shealth.widget.floor';"
/usr/bin/sqlite3 $HOMEDB "update home set id = '[email protected]' where id = 'com.samsung.w-calendar2.widget.next-event';"
/usr/bin/sqlite3 $HOMEDB "update home set id = 'com.samsung.w-contacts2.widget.multiple' where id = 'com.samsung.w-contacts2.widget.single';"
/usr/bin/sqlite3 $HOMEDB "update home set id = 'com.samsung.w-magazine-widget-app' where id = 'org.tizen.magazine-widget';"

/usr/bin/com.samsung.app-widget-upgrade
fi

if [[ "$OLD_VER" = "3.0"* ]]; then

echo "upgrade home DB 3.0* to 4.0 HOME DB:$HOMEDB"

/usr/bin/sqlite3 $HOMEDB "delete from home where id = '[email protected]';"
fi

Will check if i can find Watch Face as template...
Maybe easier here to "spoof"...

Best Regards
 
Last edited:
  • Like
Reactions: Vuska

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
Watch Face seems dead end too...

But paths from Shell script leads to this:
Code:
D:\SDB\SDB260>sdb pull /opt/usr/apps/com.samsung.w-home/data/.home.db
pulled                       .home.db   100%         16KB
1 file(s) pulled. 0 file(s) skipped.
/opt/usr/apps/com.samsung.w-home/data/.home.db   106 KB/s (16384 bytes in 0.150s)


Code:
D:\SDB\SDB260>sdb pull /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/.home.db
pulled                       .home.db   100%         16KB
1 file(s) pulled. 0 file(s) skipped.
/opt/usr/home/owner/apps_rw/com.samsung.w-home/data/.home.db   123 KB/s (16384 bytes in 0.130s)

1:1 same file from both locations as it seems...
 
Last edited:

EQMOD

Member
Nov 1, 2017
26
1
Watch Face seems dead end too...

But paths from Shell script leads to this:
Code:
D:\SDB\SDB260>sdb pull /opt/usr/apps/com.samsung.w-home/data/.home.db
pulled                       .home.db   100%         16KB
1 file(s) pulled. 0 file(s) skipped.
/opt/usr/apps/com.samsung.w-home/data/.home.db   106 KB/s (16384 bytes in 0.150s)


Code:
D:\SDB\SDB260>sdb pull /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/.home.db
pulled                       .home.db   100%         16KB
1 file(s) pulled. 0 file(s) skipped.
/opt/usr/home/owner/apps_rw/com.samsung.w-home/data/.home.db   123 KB/s (16384 bytes in 0.130s)

1:1 same file from both locations as it seems...


Looks like we are getting somewhere here. Any files you need for me to check from my Active 2 watch. ?
My setup is are as follows

Phone: Huawei Mate 20 Pro
Watch: Samsung Active 2

Active 2 Watch CSC is now KOO changed using Combination FW and Netodin
Originally it was on 4 0 0 .7 , changed to 4 0 0 .6 after Netodin CSC update
Installed bp.tpk and ecg.tpk via sdb.
then via Samsung OTA it became 4 0 0 .8 then another Samsung OTA came
and it is now 5.5.0. 1. Both Ecg and BP are working using Samsung Health Monitor 167
 

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
For better investigation... my SM-R760...

Code:
sh-3.2# cd /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  1 05:03 .
drwxr-xr-x 5 owner users         4096 Apr 28 10:04 ..
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  1 05:03 .apps.db-journal
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  2 15:51 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  1 05:04 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  2 15:51 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  1 05:03 .widget_suggestion.db-journal
sh-3.2# cd /opt/usr/apps/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  1 05:03 .
drwxr-xr-x 5 owner users         4096 Apr 28 10:04 ..
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  1 05:03 .apps.db-journal
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  2 15:51 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  1 05:04 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  2 15:51 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  1 05:03 .widget_suggestion.db-journal
sh-3.2# mkdir testme
sh-3.2# ls -a1l
total 128
drwxrwsr-x 4 owner system_share  4096 Oct  2 15:56 .
drwxr-xr-x 5 owner users         4096 Apr 28 10:04 ..
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  1 05:03 .apps.db-journal
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  2 15:51 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  1 05:04 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  2 15:51 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  1 05:03 .widget_suggestion.db-journal
drwxrwsrwx 2 root  system_share  4096 Oct  2 15:56 testme
sh-3.2# cd /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 128
drwxrwsr-x 4 owner system_share  4096 Oct  2 15:56 .
drwxr-xr-x 5 owner users         4096 Apr 28 10:04 ..
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  1 05:03 .apps.db-journal
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  2 15:51 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  1 05:04 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  2 15:51 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  1 05:03 .widget_suggestion.db-journal
drwxrwsrwx 2 root  system_share  4096 Oct  2 15:56 testme

A
Aha, seems only 1 folder...
So I need only 1 time play with file
Code:
.home.db

B
Code:
D:\SDB\SDB260>sdb pull /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/ .\ftd4\widget
pulled  .widget_suggestion.db-journal   100%         16KB
pulled                       .home.db   100%         16KB
pulled                       .apps.db   100%         16KB
pulled               .apps.db-journal   100%         12KB
pulled               .home.db-journal   100%         12KB
pulled          .widget_suggestion.db   100%         20KB
pulled 55157627a4c4b5a9bdfc405a197f194d84543b01 100%         44 B
pulled f657e4e15e35a0c1fa53c462020df9ebec5c19ce 100%         36 B
pulled 3cbacb5376e2dee294232c956838fc1954985ea5 100%         49 B
pulled ec6b88021747c602dffdafe2e809beb84d820488 100%         43 B
pulled 1e3463dc2080de6e30d6f7ee28b65fcdfa33d0d5 100%         49 B
pulled d6ea693302f3e6a1b8bb827892323e8ed76a4274 100%         42 B
12 file(s) pulled. 0 file(s) skipped.
/opt/usr/home/owner/apps_rw/com.samsung.w-home/data/   126 KB/s (96087 bytes in 0.740s)

Maybe more clear what is inside db...

C

If I push with SDB then... hmmm... maybe this is why it fails... maybe...

Code:
sh-3.2# cd /opt/usr/home/owner/apps_rw/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 128
drwxrwsr-x 4 owner system_share  4096 Oct  2 16:13 .
drwxr-xr-x 5 owner users         4096 Apr 28 10:04 ..
-rw-r--r-- 1 owner system_share 16384 Oct  2 15:51 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  1 05:03 .apps.db-journal
[COLOR="Red"]-rwxr-xrwx[/COLOR] 1 root  system_share 16384 Oct  2 02:14 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  2 15:51 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  1 05:04 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  2 15:51 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  1 05:03 .widget_suggestion.db-journal
drwxrwsrwx 2 root  system_share  4096 Oct  2 15:56 testme
 
Last edited:

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
Pulled files via SDB from my SM-R820...

Not all possible but few... :good: :good:


Compared with BTG6 Firmware rootfs.img from GW3...

Code:
spo2 app is not enabled. [COLOR="Red"][B]skip[/B][/COLOR]


This is inside...

Code:
/usr/apps/com.samsung.w-manager-service/bin/[COLOR="Red"][B]w-manager-service[/B][/COLOR]

Best Regards
 

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
I have now rooted Tizen 5.5 for my SM-R820... CTH8...

Need to prepare few things and backup,,,

Then I will "simple" edit:

Code:
home_default_items.xml
in Default Folder of CSC Preconfig crap...


Code:
<?xml version="1.0" encoding="UTF-8"?>
<data>
	<favorite>
		<packagename>[email protected]</packagename>
		<classname>[email protected]</classname>
		<screen>0</screen>
		<cellX>0</cellX>
		<cellY>0</cellY>
	</favorite>
	<favorite>
		<packagename>com.samsung.app-shortcut-widget</packagename>
		<classname>com.samsung.app-shortcut-widget</classname>
		<screen>1</screen>
		<cellX>1</cellX>
		<cellY>0</cellY>
	</favorite>
	<favorite>
		<packagename>[email protected]</packagename>
		<classname>[email protected]</classname>
		<screen>0</screen>
		<cellX>1</cellX>
		<cellY>0</cellY>
	</favorite>
	<favorite>
		<packagename>[email protected]</packagename>
		<classname>[email protected]</classname>
		<screen>0</screen>
		<cellX>1</cellX>
		<cellY>1</cellY>
	</favorite>
	<favorite>
		<packagename>com.samsung.weather-widget</packagename>
		<classname>com.samsung.weather-widget</classname>
		<screen>1</screen>
		<cellX>0</cellX>
		<cellY>0</cellY>
	</favorite>
	<favorite>
		<packagename>[email protected]</packagename>
		<classname>[email protected]</classname>
		<screen>2</screen>
		<cellX>0</cellX>
		<cellY>0</cellY>
	</favorite>
</data>

Maybe I add or I replace...
Code:
[COLOR="Red"][B]oxygensaturation[/B][/COLOR]@com.samsung.shealth.widget

We will see if this is enough... :cowboy:

Best Regards
 
B

betterl8thannvr

Guest
How did you root 5.5? I haven't been able to find any info on rooting these other than some old rooted firnwares
 

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
Code:
sdb root on

sdb shell mount -vo remount,rw /opt/system/csc/



sdb push SW_Configuration.xml /opt/system/csc/mps/CSC/

sdb push home_default_items.xml /opt/system/csc/preconfig/DEF/usr/homescreen/

First attempt...

Changed 1 Byte to prevent CTI4 FOTA...

@betterl8thannvr

Your Model Name is what?

Because I've play with my SM-R820...

Best Regards
 
Oct 2, 2020
14
1
@adfree ah, mine fails when I try sdb root on

>sdb root on
* The version of SDB client (2.3.0) is not same with that of SDB server (4.2.12).
It may cause version compatibility problems.
It is recommended to use SDB server with version 2.3.0. *
Permission denied

Any idea how to get around that?

Edit: I have SM-R825U
 
Last edited:

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
First attempt not bring Blood Oxygen to me...

Second attempt...

Code:
D:\SDB\SDB260>sdb root on
Switched to 'root' account mode

D:\SDB\SDB260>sdb shell mount -vo remount,rw /opt/system/csc/
mount: /dev/mmcblk0p16 mounted on /opt/system/csc.

D:\SDB\SDB260>sdb shell mkdir /opt/system/csc/preconfig/DBT/usr/homescreen/
mkdir: cannot create directory `/opt/system/csc/preconfig/DBT/usr/homescreen/': No such file or directory

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/system/csc/preconfig/DBT/
sh-3.2# ls -a1l
total 8
drwxr-xr-x  4 root root 1024 Jun 16 16:10 .
drwxr-xr-x 71 root root 1024 Jun 16 16:10 ..
drwxr-xr-x  2 root root 1024 Jun 16 16:10 feature
drwxr-xr-x  2 root root 1024 Jun 16 16:10 preset
sh-3.2# mkdir usr
sh-3.2# cd usr
sh-3.2# mkdir homescreen
sh-3.2# exit
exit

D:\SDB\SDB260>sdb push home_default_items.xml /opt/system/csc/preconfig/DBT/usr/homescreen/
pushed         home_default_items.xml   100%          1KB
1 file(s) pushed. 0 file(s) skipped.
home_default_items.xml           7 KB/s (1387 bytes in 0.180s)

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/system/csc/preconfig/DBT/usr/homescreen/
sh-3.2# ls -a1l
total 7
drwxrwxrwx 2 root root 1024 Oct  3 14:03 .
drwxrwxrwx 3 root root 1024 Oct  3 14:03 ..
-rwxr-xrwx 1 root root 1387 Oct  3 07:49 home_default_items.xml
sh-3.2# reboot
Rebooting.

@EQMOD

You need Root aka Super User aka su Binary inside Firmware... this is Linux stuff...
@betterl8thannvr

You are in similar situation like me...

No latest files leaked...
ATF2 is latest leaked Files for netOdin...

So much harder to get Root Access... :eek:

I have at the moment limited time to explain nor to make the files for you...

Maybe next days more time...

Best Regards
 

EQMOD

Member
Nov 1, 2017
26
1
First attempt not bring Blood Oxygen to me...

Second attempt...

Code:
D:\SDB\SDB260>sdb root on
Switched to 'root' account mode

D:\SDB\SDB260>sdb shell mount -vo remount,rw /opt/system/csc/
mount: /dev/mmcblk0p16 mounted on /opt/system/csc.

D:\SDB\SDB260>sdb shell mkdir /opt/system/csc/preconfig/DBT/usr/homescreen/
mkdir: cannot create directory `/opt/system/csc/preconfig/DBT/usr/homescreen/': No such file or directory

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/system/csc/preconfig/DBT/
sh-3.2# ls -a1l
total 8
drwxr-xr-x  4 root root 1024 Jun 16 16:10 .
drwxr-xr-x 71 root root 1024 Jun 16 16:10 ..
drwxr-xr-x  2 root root 1024 Jun 16 16:10 feature
drwxr-xr-x  2 root root 1024 Jun 16 16:10 preset
sh-3.2# mkdir usr
sh-3.2# cd usr
sh-3.2# mkdir homescreen
sh-3.2# exit
exit

D:\SDB\SDB260>sdb push home_default_items.xml /opt/system/csc/preconfig/DBT/usr/homescreen/
pushed         home_default_items.xml   100%          1KB
1 file(s) pushed. 0 file(s) skipped.
home_default_items.xml           7 KB/s (1387 bytes in 0.180s)

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/system/csc/preconfig/DBT/usr/homescreen/
sh-3.2# ls -a1l
total 7
drwxrwxrwx 2 root root 1024 Oct  3 14:03 .
drwxrwxrwx 3 root root 1024 Oct  3 14:03 ..
-rwxr-xrwx 1 root root 1387 Oct  3 07:49 home_default_items.xml
sh-3.2# reboot
Rebooting.

@EQMOD

You need Root aka Super User aka su Binary inside Firmware... this is Linux stuff...

@betterl8thannvr

You are in similar situation like me...

No latest files leaked...
ATF2 is latest leaked Files for netOdin...

So much harder to get Root Access... :eek:

I have at the moment limited time to explain nor to make the files for you...

Maybe next days more time...

Best Regards


What happened after reboot ? :)
 
B

betterl8thannvr

Guest
thanks @adfree, I think I can figure out how to root on ATF2, but you said you had root on 5.5, so I am quite curious about how to do that without the leaked files. :)

I will keep poking at it.
 
B

betterl8thannvr

Guest
Hmm, well, flashing back to ATF2 is being troublesome. It fails every time, so I now have a small, expensive brick.

<ID:0/001> 192.168.49.1
<ID:0/001> Odin engine v(ID:1.0000)..
<ID:0/001> File analysis..
<ID:0/001> SetupConnection..
<ID:0/001> Initialzation..
<ID:0/001> Set PIT file..
<ID:0/001> DO NOT TURN OFF TARGET!!
<ID:0/001> Get PIT for mapping..
<ID:0/001> Get PIT Transmission
<ID:0/001> Firmware update start..
<ID:0/001> SingleDownload.
<ID:0/001> cm.bin
<ID:0/001>
<ID:0/001> XmitData
<ID:0/001> Complete(Write) operation failed.
<ID:0/001> Removed!!
<OSM> All threads completed. (succeed 0 / failed 1)
 

adfree

Senior Member
Jun 14, 2008
10,379
6,051
Samsung Galaxy Watch 4
Samsung Galaxy S22
Tiny progress...

A
Seems I found my mistake...

SDB push change Permissions to file...

Code:
D:\SDB\SDB260>sdb push .home.db /opt/usr/apps/com.samsung.w-home/data/
pushed                       .home.db   100%         16KB
1 file(s) pushed. 0 file(s) skipped.
.home.db                         84 KB/s (16384 bytes in 0.190s)

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/usr/apps/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  5 00:33 .
drwxr-xr-x 5 owner users         4096 Oct  3 14:10 ..
-rw-r--r-- 1 owner system_share 16384 Oct  3 14:53 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  3 14:53 .apps.db-journal
-rwxr-xrwx 1 root  system_share 16384 Oct  3 21:27 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  5 00:04 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  3 14:15 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  3 14:15 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  3 14:15 .widget_suggestion.db-journal
sh-3.2# chmod 644 .home.db
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  5 00:33 .
drwxr-xr-x 5 owner users         4096 Oct  3 14:10 ..
-rw-r--r-- 1 owner system_share 16384 Oct  3 14:53 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  3 14:53 .apps.db-journal
-rw-r--r-- 1 root  system_share 16384 Oct  3 21:27 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  5 00:04 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  3 14:15 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  3 14:15 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  3 14:15 .widget_suggestion.db-journal

So I have to correct it...
But this require ROOT...

Tested .home.db from GW3...

Blood Oxygen still blocked...

Hmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm.
So this means IMHO... I have to replace

Code:
com.samsung.w-home.home-service
https://forum.xda-developers.com/showpost.php?p=83626487&postcount=6

Best Regards
 

EQMOD

Member
Nov 1, 2017
26
1
Tiny progress...

A
Seems I found my mistake...

SDB push change Permissions to file...

Code:
D:\SDB\SDB260>sdb push .home.db /opt/usr/apps/com.samsung.w-home/data/
pushed                       .home.db   100%         16KB
1 file(s) pushed. 0 file(s) skipped.
.home.db                         84 KB/s (16384 bytes in 0.190s)

D:\SDB\SDB260>sdb shell
sh-3.2# cd /opt/usr/apps/com.samsung.w-home/data/
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  5 00:33 .
drwxr-xr-x 5 owner users         4096 Oct  3 14:10 ..
-rw-r--r-- 1 owner system_share 16384 Oct  3 14:53 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  3 14:53 .apps.db-journal
-rwxr-xrwx 1 root  system_share 16384 Oct  3 21:27 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  5 00:04 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  3 14:15 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  3 14:15 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  3 14:15 .widget_suggestion.db-journal
sh-3.2# chmod 644 .home.db
sh-3.2# ls -a1l
total 124
drwxrwsr-x 3 owner system_share  4096 Oct  5 00:33 .
drwxr-xr-x 5 owner users         4096 Oct  3 14:10 ..
-rw-r--r-- 1 owner system_share 16384 Oct  3 14:53 .apps.db
-rw-r--r-- 1 owner system_share 12824 Oct  3 14:53 .apps.db-journal
-rw-r--r-- 1 root  system_share 16384 Oct  3 21:27 .home.db
-rw-r--r-- 1 owner system_share 12824 Oct  5 00:04 .home.db-journal
drwxr-sr-x 2 owner system_share  4096 Oct  3 14:15 .pref
-rw-r--r-- 1 owner system_share 20480 Oct  3 14:15 .widget_suggestion.db
-rw-r--r-- 1 owner system_share 16928 Oct  3 14:15 .widget_suggestion.db-journal

So I have to correct it...
But this require ROOT...

Tested .home.db from GW3...

Blood Oxygen still blocked...

Hmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm.
So this means IMHO... I have to replace

Code:
com.samsung.w-home.home-service
https://forum.xda-developers.com/showpost.php?p=83626487&postcount=6

Best Regards

Could you upload both binaries here. (GW3, GA2) and home.db Let me check both
 

Top Liked Posts

  • There are no posts matching your filters.
  • 7
    Samsung not add Blood Oxygen in Tizen 5.5.0.2 for GWA2...
    😭

    But I will check our older findings... with SM-R820 DUA3...

    Test checklist...

    A
    This still work... so red LED not deactivated fully...

    B
    My Rooting is still working. So I have Root access in DUA3...


    C
    Maybe mistake... w-home trick seems not work... to enable BloodOxy Widget...
    Will check later again with open eyes...

    D
    Hmmm...
    sdb push w-manager-service /usr/apps/com.samsung.w-manager-service/bin/

    No luck yet to make the Widget visible like before...

    E
    sh-3.2# launch_app com.samsung.shealth.measure
    ... successfully launched

    Shows same "not avaliable"...

    Will proceed with SH mods...

    F
    Code:
    usr\lib\libsensor-genuine.so.4.1.27
    usr\lib\sensor\libsensor-hal.so


    Still 2 hits for search text string:
    SPO2_MONITOR_SENSOR
    6
    Old method was to replace text string SM-R820 with SM-R840...

    In my tests with DUA3 SM-R820 I realized this is not "Driver switch"... but kind of blacklist...

    So my "new" method is:

    A
    Code:
    sdb root on
    
    sdb shell mount -vo remount,rw /
    
    sdb push shealth-measure /usr/apps/com.samsung.shealth_gear/bin

    Only changed text string SM-R820 into SM-R821...


    B
    To start Blood Oxy I send Command:
    Code:
    sdb shell launch_app com.samsung.shealth.measure


    This means only progress like before... but with less modified files...


    Now will try to do more text string changes... because SH TPK contain in every Binary Model Name text strings...
    Will check if blacklist stuff or something else...

    Best Regards
    6
    Simple edit of manifest.xml allow me now to start Blood Oxygen in 3 wayS...

    Code:
    D:\SDB\SDB260>sdb shell launch_app com.samsung.shealth.measure
    ... successfully launched
    
    D:\SDB\SDB260>sdb shell launch_app com.samsung.shealth
    ... successfully launched

    2 Commands because I have simple replaced shealth with shealth-measure...

    And this allows me also by clicking the Icon...

    Now next changes... rename... to run also where SH is installed...
    I have Root and ways to deinstall...

    I am trying to simplify also for others...

    Best Regards
    6
    I will be receiving a GW3 sometime next week. Not sure if I will keep it yet as it is probably to big for my skinny wrists :D.
    But I would be up to do the necessary testing for you @adfree
    5
    Attempt 1.

    With changed text string inside 20 files from SH bin folder...

    Code:
    sdb root on
    
    sdb shell mount -vo remount,rw /
    
    sdb push notification-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push scp-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-alert-viewer /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-breathe /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-debug-menu /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-exercise /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-exercising-viewer /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-health-data-permission /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-heartrate-measure /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-measure /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-mindfulness /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-multiworkout-widgetsetting /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-sa-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-sdk-data-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-stress-measure /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-together-viewer /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-whitelist-sync-service /usr/apps/com.samsung.shealth_gear/bin
    
    sdb push shealth-widget /usr/apps/com.samsung.shealth_gear/bin

    Need then time to check if still working and to maybe find differences...

    Best Regards