1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-26 10:35:50 +01:00

Add support for Galaxy Buds Live

This commit is contained in:
vanous 2021-11-03 22:06:35 +01:00
parent a490e9f555
commit fcb91fd544
21 changed files with 1098 additions and 23 deletions

View File

@ -0,0 +1,166 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg2"
width="28.740126"
height="28.740126"
viewBox="0 0 28.740126 28.740126"
sodipodi:docname="ic_device_galaxy_buds_live.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<metadata
id="metadata8">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<defs
id="defs6">
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 14.370063 : 1"
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_z="28.740126 : 14.370063 : 1"
inkscape:persp3d-origin="14.370063 : 9.580042 : 1"
id="perspective903" />
</defs>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1035"
id="namedview4"
showgrid="false"
showguides="true"
inkscape:guide-bbox="true"
inkscape:zoom="16.000001"
inkscape:cx="7.5312497"
inkscape:cy="18.906249"
inkscape:window-x="0"
inkscape:window-y="45"
inkscape:window-maximized="1"
inkscape:current-layer="layer1"
inkscape:pagecheckerboard="0">
<inkscape:grid
type="xygrid"
id="grid972" />
</sodipodi:namedview>
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="Background"
style="display:inline">
<g
inkscape:groupmode="layer"
id="layer4"
inkscape:label="Bottom"
style="display:inline"
sodipodi:insensitive="true">
<rect
style="display:inline;fill:#1f7fdb;fill-opacity:1;stroke:none;stroke-width:3.57115;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect817-5"
width="22.819572"
height="21.904638"
x="2.9239759"
y="3.8768768"
ry="0.9472276" />
</g>
<g
inkscape:groupmode="layer"
id="layer3"
inkscape:label="Middle"
style="display:inline"
sodipodi:insensitive="true">
<rect
style="display:inline;fill:#4dabf5;fill-opacity:1;stroke:none;stroke-width:3.57115;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect817-7"
width="22.819572"
height="21.904638"
x="2.9317887"
y="3.0349438"
ry="0.9472276" />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="Top"
style="display:inline"
sodipodi:insensitive="true">
<rect
style="fill:#2196f3;fill-opacity:1;stroke:none;stroke-width:3.57115;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect817"
width="22.819572"
height="21.904638"
x="2.9238882"
y="3.4130721"
ry="0.9472276" />
</g>
<g
id="g3814-7"
transform="matrix(-0.87287371,0,0,0.8814596,23.235344,11.404728)"
style="fill:none;fill-opacity:1;stroke:#fffffd;stroke-width:0.861768;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1">
<g
id="g1577">
<g
id="g3814"
transform="matrix(-1,0,0,1,19.724468,-6.6444907)"
style="display:inline;fill:none;fill-opacity:1;stroke:#fffffd;stroke-width:0.861768;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1">
<path
style="fill:none;fill-opacity:1;stroke:#fffffd;stroke-width:0.861768;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 6.3534766,13.150028 C 5.2590543,14.102574 3.7589552,14.39697 2.6009409,13.886465 1.3699015,13.343766 0.52234461,12.049487 0.50706651,10.688971 0.49818111,9.8974897 0.68425351,9.3259096 1.2026925,8.5521587 1.6467421,7.8894314 1.7546703,7.5633672 1.7383195,6.9339544 1.7242951,6.3940166 1.5887612,6.0540278 1.1304302,5.409047 0.69461341,4.7957481 0.51189951,4.3487514 0.43456241,3.7066569 0.29489991,2.5470862 0.74072801,1.4253568 1.6710145,0.59567225 2.8470953,-0.45322535 4.5920415,-0.46138405 5.9962565,0.57544755 7.6247819,1.7779049 8.5957069,4.0874446 8.6379302,6.8591974 8.6637127,8.551633 8.3637849,10.047519 7.7501356,11.287081 7.5146695,11.762713 7.3453654,12.031594 7.0219979,12.443468 6.7260442,12.820427 6.6974699,12.850626 6.3534853,13.150033 Z"
id="path11168-8" />
<path
style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#fffffd;stroke-width:0.861768;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 6.5908811,5.6846666 c 0,0 0.5148355,0.502981 0.476276,1.6957252 -0.03255,1.0068473 -0.6176138,1.4771457 -0.6176138,1.4771457"
id="path2468"
sodipodi:nodetypes="csc" />
</g>
<path
style="fill:none;fill-opacity:1;stroke:#fffffd;stroke-width:0.861768;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 6.3534766,13.150028 C 5.2590543,14.102574 3.7589552,14.39697 2.6009409,13.886465 1.3699015,13.343766 0.52234461,12.049487 0.50706651,10.688971 0.49818111,9.8974897 0.68425351,9.3259096 1.2026925,8.5521587 1.6467421,7.8894314 1.7546703,7.5633672 1.7383195,6.9339544 1.7242951,6.3940166 1.5887612,6.0540278 1.1304302,5.409047 0.69461341,4.7957481 0.51189951,4.3487514 0.43456241,3.7066569 0.29489991,2.5470862 0.74072801,1.4253568 1.6710145,0.59567225 2.8470953,-0.45322535 4.5920415,-0.46138405 5.9962565,0.57544755 7.6247819,1.7779049 8.5957069,4.0874446 8.6379302,6.8591974 8.6637127,8.551633 8.3637849,10.047519 7.7501356,11.287081 7.5146695,11.762713 7.3453654,12.031594 7.0219979,12.443468 6.7260442,12.820427 6.6974699,12.850626 6.3534853,13.150033 Z"
id="path11168-8-1" />
</g>
<path
style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#fffffd;stroke-width:0.861768;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 6.5908811,5.6846666 c 0,0 0.5148355,0.502981 0.476276,1.6957252 -0.03255,1.0068473 -0.6176138,1.4771457 -0.6176138,1.4771457"
id="path2468-7"
sodipodi:nodetypes="csc" />
</g>
</g>
<g
inkscape:groupmode="layer"
id="layer5"
inkscape:label="Original"
style="display:none"
sodipodi:insensitive="true">
<image
y="0.0079936879"
x="0.010951031"
id="image4124"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAABgCAMAAADVRocKAAAAA3NCSVQICAjb4U/gAAAACXBIWXMA ADFOAAAxTgGacD5yAAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAABF0RVh0 VGl0bGUAUGViYmxlIEljb26KvwD9AAAADHRFWHRBdXRob3IAeHBobnh/4OzMAAAAY3RFWHRDb3B5 cmlnaHQAQ0MgQXR0cmlidXRpb24tTm9uQ29tbWVyY2lhbC1TaGFyZUFsaWtlIGh0dHA6Ly9jcmVh dGl2ZWNvbW1vbnMub3JnL2xpY2Vuc2VzL2J5LW5jLXNhLzMuMC/eBBrlAAABy1BMVEUAAAAAAAAA AP8AAIAAAFUAAKoAVaoAAIAAQIAAM2YAM5kzM2YzM5krK4AkJG0kJJIgIIAcHHEcHI4aGoAXF3QX F4sXLnQXLosVK4AUJ3YUJ4kSJIAkJIARInciInciIogQIIAgIIAeHngeHoccHIAcK4AbKHkbKIYa GoAaJoAYJHkXI4AXI4sWIXoWIYUVIIAfH3ofH4UdJ4ATHIQcJnsbJIAaI4QaIoAZIXsZIYQYIHgY IIAXH4MXJ3wXHoAXJoBLpfAWJHwdJHwdJIMcI4Acas0VIoMbIoAaIXwaIIAZH3wZH4MZJXwYHoAY HoYYJIAehtsYHoIefdtHoO0jetZGovNEn+4gg+EfgN5Ep/VKqfREpvQgfdkgfttKqvQggd4hjesw nPMwnPRJqfUhgd4hjutJqfUgfttNq/VNq/QhlPEhlPIhlvMkmPMglvIff9sgjeoglPAhk/AhlPEh lPIhlvMkl/MkmPMlmPMmmPMnmfMpmvMzn/Q0n/Q1n/Q2oPRIqfVNq/VasfZbsvZhtPZitfdtuveQ yvmXzvmj0/qk1Pqu2fu83/vR6f3T6v3Z7f3i8f3j8v3l8/7m8/7p9f7q9f7x+P7y+f7////ougeB AAAAb3RSTlMAAQECAwMDBAQFBQUFBgcHCAkJCgsLCwsMDQ0ODg8PDxAQERESEhMTFBQVFhYXFxgZ GRobGxwdHh8fICAhISIiIiMjIyQkJSYnKCkpKSoqKiorKyssLC2xs7O0tba2tu7u7u7u7+/w8fHy +/v7+/ywJhX9AAAC0klEQVRo3u2a+VfTQBCAm00iW0nSTVNKbKQYbIMUC6jU4q2IB2rF+74vPEAR LSjIIXgAAiqef65py6MNJe17y1RF8/26L/N1N9O8ZGZcLof/DiYFoiV1cZHwiGVZjh7zalRAYYbn sFsQ6RFwGccyBeJjwSMrPn8lHX6fQqRy3tbAsFiU1So9FA4bNIRD63XNTwTO5pSYc9fuvwbgwaW9 SxqYs/eGBgcAGBy+fRrlpRPDsJdfJoEYuMgvzibz/vK3kmDcFMuxNZvM/BG74QTdFV6PJZsYlhe9 XXCCrlCVStwcyhG45QCkoCmiV0o4uwXEib4aQMHjbc0RTXYvCMx/mGdNHaSgraWxRhEXzsgUEC0C KWjfszlUYRWsrYcUHGttNlSRzxUEo5CCjrZYrSqVVlD3Nwj6vqcZsovzKrPeTy3o/5lmxE4wnFl/ 4QhKLvjy2YY5IEExHMH0B1umQQSj9o+EUUewIBh/m8c4qOBbfu58dQRLCmYnJmZLKphKJicdwR8X vJsymSmhIM37FSv4OJlhxnlUOAJHAC8Ye5PHmPNe9PsEJX/5dT5AigvmPtkw53wnr3xB34809uWc zDp9OWflV7xgBaBlzY79MWORALhuui+vbhoArfwe3rUp5MtWfl2Il1QDUtAaj+rKakv1XdEhBfGm Wo1kq+/pM1Ih+wdRI6iIq3IFvEAewgke6QHFg1mU26PjhbtwghsKEbG1X8ew3PmnUPGfXRAwv7hr yqAD13t6nwPQ23PnBMeivG4gg85c7XwCQOeVU+avZ5bslcrrNm7dfehIInGSguOJo+0Hd27ZoOam j3ULvOjTI02x+PYddLTEY42GJpfnpo/L0g50k8pqI1IfbWikoSFaXxfSFKnMrqFsZpKbKKoWDFbT EdQCqlfCdhtIG7AoESLTQogk4EJd/VRTn8fLgecKTg3MjyUsA4SKDD7MT1bQ8++NmvwCRmydh2Fg UvEAAAAASUVORK5CYII= "
style="opacity:0.49074079;image-rendering:optimizeQuality"
preserveAspectRatio="none"
height="28.710279"
width="28.710279" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 9.3 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 18 KiB

View File

@ -0,0 +1,72 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="22.722673mm"
height="24.000002mm"
viewBox="0 0 22.722673 24.000002"
version="1.1"
id="svg1002"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
sodipodi:docname="ic_galaxy_buds_live.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview1004"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="false"
fit-margin-left="2"
fit-margin-top="2"
fit-margin-right="2"
fit-margin-bottom="2"
inkscape:zoom="5.0814254"
inkscape:cx="-11.709313"
inkscape:cy="29.617674"
inkscape:window-width="1920"
inkscape:window-height="1035"
inkscape:window-x="0"
inkscape:window-y="45"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" />
<defs
id="defs999" />
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(2.0000914,1.9999036)">
<g
id="g3814">
<path
style="fill:none;stroke:#000000;stroke-width:0.500001;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 6.3534766,13.150028 C 5.2590543,14.102574 3.7589552,14.39697 2.6009409,13.886465 1.3699015,13.343766 0.52234461,12.049487 0.50706651,10.688971 0.49818111,9.8974897 0.68425351,9.3259096 1.2026925,8.5521587 1.6467421,7.8894314 1.7546703,7.5633672 1.7383195,6.9339544 1.7242951,6.3940166 1.5887612,6.0540278 1.1304302,5.409047 0.69461341,4.7957481 0.51189951,4.3487514 0.43456241,3.7066569 0.29489991,2.5470862 0.74072801,1.4253568 1.6710145,0.59567225 2.8470953,-0.45322535 4.5920415,-0.46138405 5.9962565,0.57544755 7.6247819,1.7779049 8.5957069,4.0874446 8.6379302,6.8591974 8.6637127,8.551633 8.3637849,10.047519 7.7501356,11.287081 7.5146695,11.762713 7.3453654,12.031594 7.0219979,12.443468 6.7260442,12.820427 6.6974699,12.850626 6.3534853,13.150033 Z"
id="path11168-8" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.264583px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 6.5908811,5.6846666 c 0,0 0.5148355,0.502981 0.476276,1.6957252 -0.03255,1.0068473 -0.6176138,1.4771457 -0.6176138,1.4771457"
id="path2468"
sodipodi:nodetypes="csc" />
</g>
<g
id="g3814-7"
transform="matrix(-1,0,0,1,19.129886,6.2222493)">
<path
style="fill:none;stroke:#000000;stroke-width:0.500001;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 6.3534766,13.150028 C 5.2590543,14.102574 3.7589552,14.39697 2.6009409,13.886465 1.3699015,13.343766 0.52234461,12.049487 0.50706651,10.688971 0.49818111,9.8974897 0.68425351,9.3259096 1.2026925,8.5521587 1.6467421,7.8894314 1.7546703,7.5633672 1.7383195,6.9339544 1.7242951,6.3940166 1.5887612,6.0540278 1.1304302,5.409047 0.69461341,4.7957481 0.51189951,4.3487514 0.43456241,3.7066569 0.29489991,2.5470862 0.74072801,1.4253568 1.6710145,0.59567225 2.8470953,-0.45322535 4.5920415,-0.46138405 5.9962565,0.57544755 7.6247819,1.7779049 8.5957069,4.0874446 8.6379302,6.8591974 8.6637127,8.551633 8.3637849,10.047519 7.7501356,11.287081 7.5146695,11.762713 7.3453654,12.031594 7.0219979,12.443468 6.7260442,12.820427 6.6974699,12.850626 6.3534853,13.150033 Z"
id="path11168-8-1" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.264583px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 6.5908811,5.6846666 c 0,0 0.5148355,0.502981 0.476276,1.6957252 -0.03255,1.0068473 -0.6176138,1.4771457 -0.6176138,1.4771457"
id="path2468-7"
sodipodi:nodetypes="csc" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.0 KiB

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="24mm"
height="24mm"
viewBox="0 0 24 23.999999"
version="1.1"
id="svg7609"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
sodipodi:docname="ic_galaxy_buds_live_l.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview7611"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="false"
fit-margin-left="3"
fit-margin-right="3"
fit-margin-bottom="2"
fit-margin-top="2"
inkscape:zoom="3.5931104"
inkscape:cx="61.645754"
inkscape:cy="88.363553"
inkscape:window-width="1920"
inkscape:window-height="1035"
inkscape:window-x="0"
inkscape:window-y="45"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" />
<defs
id="defs7606" />
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(1.1500002,4.0943479)">
<g
aria-label="L"
id="text23582"
style="font-size:7.05556px;line-height:124%;font-family:Sans;-inkscape-font-specification:Sans;letter-spacing:0px;word-spacing:0px;stroke:#000000;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none"
transform="translate(3.1750001)">
<path
d="M 6.9078682,5.6385593 H 7.6037779 V 10.196424 H 10.108364 V 10.78209 H 6.9078682 Z"
id="path24331"
style="stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none" />
</g>
<path
style="fill:none;stroke:#000000;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 13.759733,16.879157 C 12.243462,18.198095 10.165144,18.605728 8.5607702,17.898861 6.8552237,17.147416 5.6809733,15.355298 5.6598064,13.471467 5.6474977,12.375547 5.90529,11.584112 6.6235628,10.512742 7.238773,9.5951004 7.3883019,9.1436171 7.3656495,8.2721049 7.3462147,7.5244825 7.1584435,7.053719 6.5234473,6.1606497 5.9196433,5.3114487 5.6665018,4.6925171 5.5593556,3.8034444 5.3658597,2.1978512 5.9835328,0.64465448 7.272401,-0.50416378 c 1.629404,-1.45235032 4.046946,-1.46364722 5.99242,-0.028004 2.256246,1.66497608 3.601416,4.86286788 3.659915,8.70076008 0.03572,2.3434217 -0.379816,4.4146917 -1.229998,6.1310447 -0.326227,0.658582 -0.56079,1.030886 -1.0088,1.601185 -0.41003,0.521954 -0.449618,0.563769 -0.926193,0.978342 z"
id="path11168" />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="trace"
transform="translate(-2.8501842,0.0945423)" />
</svg>

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

@ -0,0 +1,61 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="24mm"
height="24mm"
viewBox="0 0 23.999999 24"
version="1.1"
id="svg1002"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
sodipodi:docname="ic_galaxy_buds_live_r.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview1004"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="false"
fit-margin-left="3"
fit-margin-top="2"
fit-margin-right="3"
fit-margin-bottom="2"
inkscape:zoom="5.0814254"
inkscape:cx="60.514516"
inkscape:cy="38.276662"
inkscape:window-width="1920"
inkscape:window-height="1035"
inkscape:window-x="0"
inkscape:window-y="45"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" />
<defs
id="defs999" />
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0.55009208,2.2464716)">
<g
aria-label="R"
id="text20823"
style="font-size:7.05556px;line-height:124%;font-family:Sans;-inkscape-font-specification:Sans;letter-spacing:0px;word-spacing:0px;stroke:#000000;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none"
transform="translate(2.6458334)">
<path
d="m 9.0560585,10.458658 q 0.2239314,0.07579 0.4340823,0.32384 0.2135961,0.248047 0.4271921,0.682129 l 0.7062451,1.4056 H 9.8759918 L 9.2179781,11.550754 Q 8.9630409,11.03399 8.721884,10.86518 8.4841723,10.69637 8.0707606,10.69637 H 7.3128391 v 2.173857 H 6.6169293 V 7.726696 h 1.5709646 q 0.881945,0 1.3160273,0.3686254 0.4340823,0.3686255 0.4340823,1.1127666 0,0.4857588 -0.2273764,0.806153 -0.2239314,0.320394 -0.6545686,0.444417 z M 7.3128391,8.2985822 v 1.8259018 h 0.8750548 q 0.5029843,0 0.7579215,-0.2308216 0.2583823,-0.2342666 0.2583823,-0.6855744 0,-0.4513078 -0.2583823,-0.6786843 Q 8.6908782,8.2985822 8.1878939,8.2985822 Z"
id="path21707"
style="stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none" />
</g>
<path
style="fill:none;stroke:#000000;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 8.7628379,18.727033 c 1.5162551,1.318938 3.5945541,1.726571 5.1989131,1.019704 1.705531,-0.751445 2.87977,-2.543563 2.900937,-4.427394 0.01231,-1.09592 -0.245482,-1.887355 -0.963748,-2.958725 -0.615204,-0.917642 -0.764732,-1.369125 -0.742079,-2.240638 0.01943,-0.747622 0.207204,-1.2183855 0.842194,-2.1114548 0.603798,-0.849201 0.856937,-1.4681326 0.964083,-2.3572053 C 17.156632,4.0457267 16.538964,2.49253 15.250108,1.3437118 13.620719,-0.10863865 11.2032,-0.11993555 9.2577446,1.3157078 7.0015198,2.9806838 5.6563628,6.1785756 5.5978644,10.016468 c -0.03572,2.343422 0.3798124,4.414692 1.2299864,6.131045 0.326224,0.658582 0.5607847,1.030886 1.0087907,1.601185 0.4100257,0.521954 0.4496137,0.563769 0.9261844,0.978342 z"
id="path11168" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.3 KiB

View File

@ -108,6 +108,8 @@ public class DeviceSettingsPreferenceConst {
public static final String PREF_GALAXY_BUDS_EQUALIZER_MODE = "pref_galaxy_buds_equalizer_mode";
public static final String PREF_GALAXY_BUDS_TOUCH_LEFT = "pref_galaxy_buds_touch_left";
public static final String PREF_GALAXY_BUDS_TOUCH_RIGHT = "pref_galaxy_buds_touch_right";
public static final String PREF_GALAXY_BUDS_LIVE_ANC = "pref_galaxy_buds_live_anc";
public static final String PREF_GALAXY_BUDS_PRESSURE_RELIEF = "pref_galaxy_buds_live_pressure_relief";
public static final String PREF_SONY_WH1000XM3_AMBIENT_SOUND_CONTROL = "pref_sony_wh1000xm3_ambient_sound_control";
public static final String PREF_SONY_WH1000XM3_FOCUS_VOICE = "pref_sony_wh1000xm3_focus_voice";

View File

@ -82,6 +82,8 @@ import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.Dev
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_LOCK_TOUCH;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_TOUCH_LEFT;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_TOUCH_RIGHT;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_LIVE_ANC;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_PRESSURE_RELIEF;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_HYBRID_HR_DANGEROUS_EXTERNAL_INTENTS;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_HYBRID_HR_DRAW_WIDGET_CIRCLES;
import static nodomain.freeyourgadget.gadgetbridge.activities.devicesettings.DeviceSettingsPreferenceConst.PREF_HYBRID_HR_FORCE_WHITE_COLOR;
@ -512,6 +514,9 @@ public class DeviceSpecificSettingsFragment extends PreferenceFragmentCompat {
addPreferenceHandlerFor(PREF_GALAXY_BUDS_EQUALIZER_MODE);
addPreferenceHandlerFor(PREF_GALAXY_BUDS_TOUCH_LEFT);
addPreferenceHandlerFor(PREF_GALAXY_BUDS_TOUCH_RIGHT);
addPreferenceHandlerFor(PREF_GALAXY_BUDS_LIVE_ANC);
addPreferenceHandlerFor(PREF_GALAXY_BUDS_PRESSURE_RELIEF);
addPreferenceHandlerFor(PREF_SONY_WH1000XM3_AMBIENT_SOUND_CONTROL);
addPreferenceHandlerFor(PREF_SONY_WH1000XM3_FOCUS_VOICE);

View File

@ -0,0 +1,157 @@
package nodomain.freeyourgadget.gadgetbridge.devices.galaxy_buds;
import android.app.Activity;
import android.content.Context;
import android.net.Uri;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import nodomain.freeyourgadget.gadgetbridge.GBException;
import nodomain.freeyourgadget.gadgetbridge.R;
import nodomain.freeyourgadget.gadgetbridge.devices.AbstractDeviceCoordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
import nodomain.freeyourgadget.gadgetbridge.entities.DaoSession;
import nodomain.freeyourgadget.gadgetbridge.entities.Device;
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
import nodomain.freeyourgadget.gadgetbridge.model.BatteryConfig;
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
public class GalaxyBudsLiveDeviceCoordinator extends AbstractDeviceCoordinator {
@NonNull
@Override
public DeviceType getSupportedType(GBDeviceCandidate candidate) {
String name = candidate.getName();
if (name != null && (
name.startsWith("Galaxy Buds Live (")
)) {
return DeviceType.GALAXY_BUDS_LIVE;
}
return DeviceType.UNKNOWN;
}
@Override
public DeviceType getDeviceType() {
return DeviceType.GALAXY_BUDS_LIVE;
}
@Override
public int getBatteryCount() {
return 3;
}
@Override
public BatteryConfig[] getBatteryConfig() {
BatteryConfig battery1 = new BatteryConfig(0, R.drawable.ic_tws_case, R.string.battery_case);
BatteryConfig battery2 = new BatteryConfig(1, R.drawable.ic_galaxy_buds_live_l, R.string.left_earbud);
BatteryConfig battery3 = new BatteryConfig(2, R.drawable.ic_galaxy_buds_live_r, R.string.right_earbud);
return new BatteryConfig[]{battery1, battery2, battery3};
}
@Override
public int getBondingStyle() {
return BONDING_STYLE_BOND;
}
@Nullable
@Override
public Class<? extends Activity> getPairingActivity() {
return null;
}
@Override
public boolean supportsActivityDataFetching() {
return false;
}
@Override
public boolean supportsActivityTracking() {
return false;
}
@Override
public SampleProvider<? extends ActivitySample> getSampleProvider(GBDevice
device, DaoSession session) {
return null;
}
@Override
public InstallHandler findInstallHandler(Uri uri, Context context) {
return null;
}
@Override
public boolean supportsScreenshots() {
return false;
}
@Override
public int getAlarmSlotCount() {
return 0;
}
@Override
public boolean supportsSmartWakeup(GBDevice device) {
return false;
}
@Override
public boolean supportsHeartRateMeasurement(GBDevice device) {
return false;
}
@Override
public String getManufacturer() {
return "Samsung";
}
@Override
public boolean supportsAppsManagement() {
return false;
}
@Override
public Class<? extends Activity> getAppsManagementActivity() {
return null;
}
@Override
public boolean supportsCalendarEvents() {
return false;
}
@Override
public boolean supportsRealtimeData() {
return false;
}
@Override
public boolean supportsWeather() {
return false;
}
@Override
public boolean supportsFindDevice() {
return true;
}
@Override
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device
device, @NonNull DaoSession session) throws GBException {
}
@Override
public int[] getSupportedDeviceSpecificSettings(GBDevice device) {
return new int[]{
R.xml.devicesettings_galaxy_buds_live,
};
}
}

View File

@ -101,6 +101,7 @@ public enum DeviceType {
UM25(350, R.drawable.ic_device_default, R.drawable.ic_device_default_disabled, R.string.devicetype_um25),
DOMYOS_T540(400, R.drawable.ic_device_lovetoy, R.drawable.ic_device_lovetoy_disabled, R.string.devicetype_domyos_t540),
NOTHING_EAR1(410, R.drawable.ic_device_nothingear, R.drawable.ic_device_nothingear_disabled, R.string.devicetype_nothingear1),
GALAXY_BUDS_LIVE(419, R.drawable.ic_device_galaxy_buds_live, R.drawable.ic_device_galaxy_buds_live_disabled, R.string.devicetype_galaxybuds_live),
GALAXY_BUDS(420, R.drawable.ic_device_galaxy_buds, R.drawable.ic_device_galaxy_buds_disabled, R.string.devicetype_galaxybuds),
SONY_WH_1000XM3(430, R.drawable.ic_device_headphones, R.drawable.ic_device_headphones_disabled, R.string.devicetype_sony_wh_1000xm3),
TEST(1000, R.drawable.ic_device_default, R.drawable.ic_device_default_disabled, R.string.devicetype_test);

View File

@ -367,6 +367,9 @@ public class DeviceSupportFactory {
case GALAXY_BUDS:
deviceSupport = new ServiceDeviceSupport(new GalaxyBudsDeviceSupport(), EnumSet.of(ServiceDeviceSupport.Flags.BUSY_CHECKING));
break;
case GALAXY_BUDS_LIVE:
deviceSupport = new ServiceDeviceSupport(new GalaxyBudsDeviceSupport(), EnumSet.of(ServiceDeviceSupport.Flags.BUSY_CHECKING));
break;
case SONY_WH_1000XM3:
deviceSupport = new ServiceDeviceSupport(new SonyWh1000Xm3Support(), EnumSet.of(ServiceDeviceSupport.Flags.BUSY_CHECKING));
break;

View File

@ -17,22 +17,32 @@ import java.util.Arrays;
import java.util.UUID;
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
import nodomain.freeyourgadget.gadgetbridge.service.btclassic.BtClassicIoThread;
public class GalaxyBudsIOThread extends BtClassicIoThread {
private static final Logger LOG = LoggerFactory.getLogger(GalaxyBudsIOThread.class);
private final GalaxyBudsProtocol galaxyBudsProtocol;
private final GBDevice gbDevice;
@NonNull
protected UUID getUuidToConnect(@NonNull ParcelUuid[] uuids) {
return galaxyBudsProtocol.UUID_DEVICE_CTRL;
if (gbDevice.getType().equals(DeviceType.GALAXY_BUDS)) {
return galaxyBudsProtocol.UUID_GALAXY_BUDS_DEVICE_CTRL;
}
if (gbDevice.getType().equals(DeviceType.GALAXY_BUDS_LIVE)) {
return galaxyBudsProtocol.UUID_GALAXY_BUDS_LIVE_DEVICE_CTRL;
}
return galaxyBudsProtocol.UUID_GALAXY_BUDS_DEVICE_CTRL;
}
public GalaxyBudsIOThread(GBDevice device, Context context, GalaxyBudsProtocol deviceProtocol,
GalaxyBudsDeviceSupport galaxyBudsDeviceSupport, BluetoothAdapter bluetoothAdapter) {
super(device, context, deviceProtocol, galaxyBudsDeviceSupport, bluetoothAdapter);
galaxyBudsProtocol = deviceProtocol;
gbDevice = device;
}
@Override

View File

@ -23,14 +23,23 @@ import nodomain.freeyourgadget.gadgetbridge.deviceevents.GBDeviceEventBatteryInf
import nodomain.freeyourgadget.gadgetbridge.deviceevents.GBDeviceEventVersionInfo;
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
import nodomain.freeyourgadget.gadgetbridge.model.BatteryState;
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
import nodomain.freeyourgadget.gadgetbridge.service.serial.GBDeviceProtocol;
public class GalaxyBudsProtocol extends GBDeviceProtocol {
private static final Logger LOG = LoggerFactory.getLogger(GalaxyBudsProtocol.class);
final UUID UUID_DEVICE_CTRL = UUID.fromString("00001102-0000-1000-8000-00805f9b34fd");
private static final byte SOM = (byte) 0xFE;
private static final byte EOM = (byte) 0xEE;
final UUID UUID_GALAXY_BUDS_DEVICE_CTRL = UUID.fromString("00001102-0000-1000-8000-00805f9b34fd");
final UUID UUID_GALAXY_BUDS_LIVE_DEVICE_CTRL = UUID.fromString("00001101-0000-1000-8000-00805F9B34FB");
private static final byte SOMBuds = (byte) 0xFE;
private static final byte EOMBuds = (byte) 0xEE;
private static final byte SOMPlus = (byte) 0xFD;
private static final byte EOMPlus = (byte) 0xDD;
private static byte SOM = SOMBuds;
private static byte EOM = EOMBuds;
private boolean isFirstExchange = true;
//incoming
@ -58,6 +67,11 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
private static final byte get_debug_get_all_data = (byte) 0x26;
private static final byte get_debug_get_version = (byte) 0x24;
//Live
private static final byte set_automatic_noise_cancelling = (byte) 0x98; //0x0/0x1
private static final byte set_live_game_mode = (byte) 0x85; // 0x0/0x1 no idea if this is doing anything
private static final byte set_pressure_relief = (byte) 0x9f; //0x0/0x1
@Override
public GBDeviceEvent[] decodeResponse(byte[] responseData) {
List<GBDeviceEvent> devEvts = new ArrayList<>();
@ -72,13 +86,23 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
ByteBuffer incoming = ByteBuffer.wrap(responseData);
incoming.order(ByteOrder.LITTLE_ENDIAN);
int length = 9;
byte type = 0;
byte sof = incoming.get();
if (sof != SOM) {
LOG.error("Error in message, wrong start of frame: " + hexdump(responseData));
return null;
}
byte type = incoming.get();
int length = (int) (incoming.get() & 0xff);
if (SOM == SOMPlus) {
length = (int) (incoming.get() & 0xff);
type = incoming.get();
} else {
type = incoming.get();
length = (int) (incoming.get() & 0xff);
}
byte message_id = incoming.get();
byte[] payload;
try {
@ -90,10 +114,10 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
switch (message_id) {
case battery_status:
devEvts.addAll(handleBatteryInfo(Arrays.copyOfRange(payload, 1, 3)));
devEvts.addAll(handleBatteryInfo(Arrays.copyOfRange(payload, 1, 11))); //11
break;
case battery_status2:
devEvts.addAll(handleBatteryInfo(Arrays.copyOfRange(payload, 2, 4)));
devEvts.addAll(handleBatteryInfo(Arrays.copyOfRange(payload, 2, 12))); //12
break;
default:
LOG.debug("Unhandled: " + hexdump(responseData));
@ -107,8 +131,14 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
ByteBuffer msgBuf = ByteBuffer.allocate(7);
msgBuf.order(ByteOrder.LITTLE_ENDIAN);
msgBuf.put(SOM);
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) 0x3); //size
byte size = 0x3;
if (SOM == SOMPlus) {
msgBuf.put((byte) size);
msgBuf.put((byte) 0x0); //0x0 for sending
} else {
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) size); //size
}
msgBuf.put((byte) command); //command id
msgBuf.putShort((short) crc16_ccitt(new byte[]{command}));
msgBuf.put(EOM);
@ -120,8 +150,14 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
ByteBuffer msgBuf = ByteBuffer.allocate(8);
msgBuf.order(ByteOrder.LITTLE_ENDIAN);
msgBuf.put(SOM);
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) 0x4); //size
byte size = 0x4;
if (SOM == SOMPlus) {
msgBuf.put((byte) size);
msgBuf.put((byte) 0x0); //0x0 for sending
} else {
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) size); //size
}
msgBuf.put((byte) command); //command id
msgBuf.put((byte) parameter);
msgBuf.putShort((short) crc16_ccitt(new byte[]{command, parameter}));
@ -134,8 +170,14 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
ByteBuffer msgBuf = ByteBuffer.allocate(9);
msgBuf.order(ByteOrder.LITTLE_ENDIAN);
msgBuf.put(SOM);
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) 0x5); //size
byte size = 0x5;
if (SOM == SOMPlus) {
msgBuf.put((byte) size);
msgBuf.put((byte) 0x0); //0x0 for sending
} else {
msgBuf.put((byte) 0x0); //0x0 for sending
msgBuf.put((byte) size); //size
}
msgBuf.put((byte) command);
msgBuf.put((byte) parameter);
msgBuf.put((byte) value);
@ -185,20 +227,31 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
byte set_lock = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_LOCK_TOUCH, false) ? 0x01 : 0x00);
return encodeMessage(set_lock_touch, set_lock);
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_GAME_MODE:
byte game_mode = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_GAME_MODE, false) ? 0x2 : 0x00);
return encodeMessage(set_game_mode, game_mode);
if (SOM == SOMPlus) {
byte game_mode = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_GAME_MODE, false) ? 0x1 : 0x00);
return encodeMessage(set_live_game_mode, game_mode);
} else {
byte game_mode = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_GAME_MODE, false) ? 0x2 : 0x00);
return encodeMessage(set_game_mode, game_mode);
}
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER:
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER_DOLBY:
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER_MODE:
byte equalizer = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER, false) ? 0x1 : 0x00);
boolean equalizer_dolby = prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER_DOLBY, false);
int dolby = 0;
if (equalizer_dolby) {
if (!equalizer_dolby) {
dolby = 5;
}
String equalizer_mode = prefs.getString(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_EQUALIZER_MODE, "0");
byte mode = (byte) (Integer.parseInt(equalizer_mode) + dolby);
return encodeMessage(set_equalizer, equalizer, mode);
if (SOM == SOMPlus) {
return encodeMessage(set_equalizer, (byte) (Integer.parseInt(equalizer_mode)));
} else {
byte mode = (byte) (Integer.parseInt(equalizer_mode) + dolby);
return encodeMessage(set_equalizer, equalizer, mode);
}
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_TOUCH_LEFT:
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_TOUCH_RIGHT:
@ -208,6 +261,14 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
byte touchmode_right = (byte) Integer.parseInt(touch_right);
return encodeMessage(set_touchpad_options, touchmode_left, touchmode_right);
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_LIVE_ANC:
byte enable_anc = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_LIVE_ANC, false) ? 0x1 : 0x00);
return encodeMessage(set_automatic_noise_cancelling, enable_anc);
case DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_PRESSURE_RELIEF:
byte enable_pressure_relief = (byte) (prefs.getBoolean(DeviceSettingsPreferenceConst.PREF_GALAXY_BUDS_PRESSURE_RELIEF, false) ? 0x1 : 0x00);
return encodeMessage(set_pressure_relief, enable_pressure_relief);
default:
LOG.debug("CONFIG: " + config);
}
@ -221,9 +282,11 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
LOG.debug("pl: " + payload.length);
LOG.debug("p0: " + payload[0]);
LOG.debug("p1: " + payload[1]);
LOG.debug("p2: " + payload[5]);
int batteryLevel1 = payload[0];
int batteryLevel2 = payload[1];
int batteryLevel3 = payload[5];
GBDeviceEventBatteryInfo evBattery1 = new GBDeviceEventBatteryInfo();
evBattery1.batteryIndex = 0;
@ -232,6 +295,7 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
evBattery1.state = (batteryLevel1 > 0) ? BatteryState.BATTERY_NORMAL : BatteryState.UNKNOWN;
deviceEvents.add(evBattery1);
GBDeviceEventBatteryInfo evBattery2 = new GBDeviceEventBatteryInfo();
evBattery2.batteryIndex = 1;
evBattery2.level = GBDevice.BATTERY_UNKNOWN;
@ -239,11 +303,30 @@ public class GalaxyBudsProtocol extends GBDeviceProtocol {
evBattery2.state = (batteryLevel2 > 0) ? BatteryState.BATTERY_NORMAL : BatteryState.UNKNOWN;
deviceEvents.add(evBattery2);
if (SOM == SOMPlus) {
GBDeviceEventBatteryInfo evBattery3 = new GBDeviceEventBatteryInfo();
// reorder for the non OG version
evBattery1.batteryIndex = 1; //left
evBattery2.batteryIndex = 2; //right
evBattery3.batteryIndex = 0; //case
evBattery3.level = GBDevice.BATTERY_UNKNOWN;
evBattery3.level = (batteryLevel3 > 0) ? batteryLevel3 : GBDevice.BATTERY_UNKNOWN;
evBattery3.state = (batteryLevel3 > 0) ? BatteryState.BATTERY_NORMAL : BatteryState.UNKNOWN;
deviceEvents.add(evBattery3);
}
return deviceEvents;
}
protected GalaxyBudsProtocol(GBDevice device) {
super(device);
LOG.debug("PETR, " + device.getType());
if (device.getType().equals(DeviceType.GALAXY_BUDS_LIVE)) {
LOG.debug("set som");
SOM = SOMPlus;
EOM = EOMPlus;
}
}
}

View File

@ -50,6 +50,7 @@ import nodomain.freeyourgadget.gadgetbridge.devices.casio.gb6900.CasioGB6900Devi
import nodomain.freeyourgadget.gadgetbridge.devices.casio.gbx100.CasioGBX100DeviceCoordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.domyos.DomyosT540Cooridnator;
import nodomain.freeyourgadget.gadgetbridge.devices.galaxy_buds.GalaxyBudsDeviceCoordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.galaxy_buds.GalaxyBudsLiveDeviceCoordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.hplus.EXRIZUK8Coordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.hplus.HPlusCoordinator;
import nodomain.freeyourgadget.gadgetbridge.devices.hplus.MakibesF68Coordinator;
@ -312,6 +313,7 @@ public class DeviceHelper {
result.add(new FitProDeviceCoordinator());
result.add(new Ear1Coordinator());
result.add(new GalaxyBudsDeviceCoordinator());
result.add(new GalaxyBudsLiveDeviceCoordinator());
result.add(new SonyWh1000Xm3Coordinator());
return result;

View File

@ -0,0 +1,36 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="45sp"
android:height="45sp"
android:viewportWidth="30"
android:viewportHeight="30">
<path
android:fillColor="#1f7fdb"
android:pathData="M3.871 3.877h20.925a0.947 0.947 0 0 1 0.948 0.947v20.01a0.947 0.947 0 0 1-0.948 0.948H3.871a0.947 0.947 0 0 1-0.947-0.948V4.824a0.947 0.947 0 0 1 0.947-0.947z"
android:strokeWidth="3.57115" />
<path
android:fillColor="#4dabf5"
android:pathData="M3.879 3.035h20.925a0.947 0.947 0 0 1 0.947 0.947v20.01a0.947 0.947 0 0 1-0.947 0.948H3.88a0.947 0.947 0 0 1-0.947-0.948V3.982A0.947 0.947 0 0 1 3.88 3.035z"
android:strokeWidth="3.57115" />
<path
android:fillColor="#2196f3"
android:pathData="M3.871 3.413h20.925a0.947 0.947 0 0 1 0.948 0.947v20.01a0.947 0.947 0 0 1-0.948 0.948H3.871a0.947 0.947 0 0 1-0.947-0.948V4.36A0.947 0.947 0 0 1 3.87 3.413z"
android:strokeWidth="3.57115" />
<path
android:pathData="M11.564 17.14C10.61 17.978 9.3 18.237 8.29 17.787 7.214 17.31 6.474 16.17 6.46 14.97c-0.008-0.698 0.155-1.202 0.607-1.884 0.388-0.584 0.482-0.871 0.468-1.426-0.012-0.476-0.13-0.776-0.53-1.344-0.381-0.54-0.54-0.935-0.608-1.5-0.122-1.023 0.267-2.012 1.079-2.743 1.027-0.925 2.55-0.932 3.775-0.018 1.422 1.06 2.27 3.096 2.306 5.539 0.023 1.492-0.24 2.81-0.775 3.903-0.205 0.42-0.353 0.656-0.635 1.02-0.259 0.332-0.284 0.358-0.584 0.622z"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:fillType="evenOdd"
android:pathData="M11.771 10.559s0.45 0.443 0.416 1.494c-0.028 0.888-0.539 1.302-0.539 1.302"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:pathData="M17.69 22.996c0.955 0.84 2.264 1.1 3.275 0.65 1.075-0.48 1.814-1.62 1.828-2.82 0.008-0.697-0.155-1.2-0.607-1.883-0.388-0.584-0.482-0.872-0.468-1.426 0.012-0.476 0.13-0.776 0.53-1.344 0.381-0.541 0.54-0.935 0.608-1.501 0.122-1.022-0.267-2.01-1.08-2.742-1.026-0.925-2.549-0.932-3.775-0.018-1.421 1.06-2.269 3.096-2.306 5.539-0.022 1.492 0.24 2.81 0.776 3.903 0.205 0.42 0.353 0.656 0.635 1.02 0.258 0.331 0.283 0.358 0.584 0.622z"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:fillType="evenOdd"
android:pathData="M17.482 16.416s-0.45 0.443-0.415 1.494c0.028 0.888 0.539 1.302 0.539 1.302"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
</vector>

View File

@ -0,0 +1,41 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="45sp"
android:height="45sp"
android:viewportWidth="30"
android:viewportHeight="30">
<path
android:fillColor="#7a7a7a"
android:pathData="M3.871 3.877h20.925a0.947 0.947 0 0 1 0.948 0.947v20.01a0.947 0.947 0 0 1-0.948 0.948H3.871a0.947 0.947 0 0 1-0.947-0.948V4.824a0.947 0.947 0 0 1 0.947-0.947z"
android:strokeWidth="3.57115173" />
<path
android:fillAlpha="0.9411765"
android:fillColor="#9f9f9f"
android:pathData="M3.879 3.035h20.925a0.947 0.947 0 0 1 0.947 0.947v20.01a0.947 0.947 0 0 1-0.947 0.948H3.88a0.947 0.947 0 0 1-0.947-0.948V3.982A0.947 0.947 0 0 1 3.88 3.035z"
android:strokeWidth="3.57115173" />
<path
android:fillColor="#8a8a8a"
android:pathData="M3.871 3.413h20.925a0.947 0.947 0 0 1 0.948 0.947v20.01a0.947 0.947 0 0 1-0.948 0.948H3.871a0.947 0.947 0 0 1-0.947-0.948V4.36A0.947 0.947 0 0 1 3.87 3.413z"
android:strokeWidth="3.57115173" />
<path
android:fillAlpha="0.9411765"
android:fillColor="#8a8a8a"
android:pathData="M12.483 10.865h3.907v6.978h-3.907z" />
<path
android:pathData="M11.564 17.14C10.61 17.978 9.3 18.237 8.29 17.787 7.214 17.31 6.474 16.17 6.46 14.97c-0.008-0.698 0.155-1.202 0.607-1.884 0.388-0.584 0.482-0.871 0.468-1.426-0.012-0.476-0.13-0.776-0.53-1.344-0.381-0.54-0.54-0.935-0.608-1.5-0.122-1.023 0.267-2.012 1.079-2.743 1.027-0.925 2.55-0.932 3.775-0.018 1.422 1.06 2.27 3.096 2.306 5.539 0.023 1.492-0.24 2.81-0.775 3.903-0.205 0.42-0.353 0.656-0.635 1.02-0.259 0.332-0.284 0.358-0.584 0.622z"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:fillType="evenOdd"
android:pathData="M11.771 10.559s0.45 0.443 0.416 1.494c-0.028 0.888-0.539 1.302-0.539 1.302"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:pathData="M17.69 22.996c0.955 0.84 2.264 1.1 3.275 0.65 1.075-0.48 1.814-1.62 1.828-2.82 0.008-0.697-0.155-1.2-0.607-1.883-0.388-0.584-0.482-0.872-0.468-1.426 0.012-0.476 0.13-0.776 0.53-1.344 0.381-0.541 0.54-0.935 0.608-1.501 0.122-1.022-0.267-2.01-1.08-2.742-1.026-0.925-2.549-0.932-3.775-0.018-1.421 1.06-2.269 3.096-2.306 5.539-0.022 1.492 0.24 2.81 0.776 3.903 0.205 0.42 0.353 0.656 0.635 1.02 0.258 0.331 0.283 0.358 0.584 0.622z"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
<path
android:fillType="evenOdd"
android:pathData="M17.482 16.416s-0.45 0.443-0.415 1.494c0.028 0.888 0.539 1.302 0.539 1.302"
android:strokeWidth="0.7559051"
android:strokeColor="#fffffd" />
</vector>

View File

@ -0,0 +1,19 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="#7E7E7E"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M9,15c-2.67,0 -8,1.34 -8,4v2h16v-2C17,16.34 11.67,15 9,15zM3,19c0.22,-0.72 3.31,-2 6,-2c2.7,0 5.8,1.29 6,2H3z" />
<path
android:fillColor="@android:color/white"
android:pathData="M4.74,9H5c0,2.21 1.79,4 4,4s4,-1.79 4,-4h0.26c0.27,0 0.49,-0.22 0.49,-0.49V8.49c0,-0.27 -0.22,-0.49 -0.49,-0.49H13c0,-1.48 -0.81,-2.75 -2,-3.45V5.5C11,5.78 10.78,6 10.5,6S10,5.78 10,5.5V4.14C9.68,4.06 9.35,4 9,4S8.32,4.06 8,4.14V5.5C8,5.78 7.78,6 7.5,6S7,5.78 7,5.5V4.55C5.81,5.25 5,6.52 5,8H4.74C4.47,8 4.25,8.22 4.25,8.49v0.03C4.25,8.78 4.47,9 4.74,9zM11,9c0,1.1 -0.9,2 -2,2s-2,-0.9 -2,-2H11z" />
<path
android:fillColor="@android:color/white"
android:pathData="M21.98,6.23l0.93,-0.83l-0.75,-1.3l-1.19,0.39c-0.14,-0.11 -0.3,-0.2 -0.47,-0.27L20.25,3h-1.5L18.5,4.22c-0.17,0.07 -0.33,0.16 -0.48,0.27L16.84,4.1l-0.75,1.3l0.93,0.83C17,6.4 17,6.58 17.02,6.75L16.09,7.6l0.75,1.3l1.2,-0.38c0.13,0.1 0.28,0.18 0.43,0.25L18.75,10h1.5l0.27,-1.22c0.16,-0.07 0.3,-0.15 0.44,-0.25l1.19,0.38l0.75,-1.3l-0.93,-0.85C22,6.57 21.99,6.4 21.98,6.23zM19.5,7.75c-0.69,0 -1.25,-0.56 -1.25,-1.25s0.56,-1.25 1.25,-1.25s1.25,0.56 1.25,1.25S20.19,7.75 19.5,7.75z" />
<path
android:fillColor="@android:color/white"
android:pathData="M19.4,10.79l-0.85,0.28c-0.1,-0.08 -0.21,-0.14 -0.33,-0.19L18.04,10h-1.07l-0.18,0.87c-0.12,0.05 -0.24,0.12 -0.34,0.19l-0.84,-0.28l-0.54,0.93l0.66,0.59c-0.01,0.13 -0.01,0.25 0,0.37l-0.66,0.61l0.54,0.93l0.86,-0.27c0.1,0.07 0.2,0.13 0.31,0.18L16.96,15h1.07l0.19,-0.87c0.11,-0.05 0.22,-0.11 0.32,-0.18l0.85,0.27l0.54,-0.93l-0.66,-0.61c0.01,-0.13 0.01,-0.25 0,-0.37l0.66,-0.59L19.4,10.79zM17.5,13.39c-0.49,0 -0.89,-0.4 -0.89,-0.89c0,-0.49 0.4,-0.89 0.89,-0.89s0.89,0.4 0.89,0.89C18.39,12.99 17.99,13.39 17.5,13.39z" />
</vector>

View File

@ -0,0 +1,16 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:tint="#7E7E7E"
android:viewportHeight="23.999998">
<path
android:fillColor="#FF000000"
android:pathData="M11.233 9.733h0.696v4.558h2.504v0.585h-3.2z"
android:strokeWidth="0.5"
android:strokeColor="#000000" />
<path
android:pathData="M14.91 20.974c-1.517 1.318-3.595 1.726-5.2 1.02-1.705-0.752-2.879-2.544-2.9-4.428-0.012-1.096 0.245-1.887 0.964-2.959 0.615-0.918 0.764-1.369 0.742-2.24-0.02-0.748-0.208-1.219-0.843-2.112C7.07 9.405 6.816 8.787 6.71 7.898 6.516 6.292 7.134 4.739 8.422 3.59c1.63-1.452 4.047-1.463 5.993-0.028 2.256 1.665 3.601 4.863 3.66 8.701 0.035 2.343-0.38 4.415-1.23 6.131-0.326 0.659-0.561 1.03-1.01 1.601-0.41 0.522-0.449 0.564-0.925 0.978z"
android:strokeWidth="2"
android:strokeColor="#000000" />
</vector>

View File

@ -0,0 +1,16 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="#7E7E7E"
android:viewportWidth="23.999998"
android:viewportHeight="24">
<path
android:fillColor="#FF000000"
android:pathData="M12.252 12.705q0.224 0.076 0.434 0.324 0.214 0.248 0.427 0.682l0.707 1.406h-0.748l-0.658-1.32q-0.255-0.517-0.496-0.685-0.238-0.17-0.651-0.17h-0.758v2.175H9.813V9.973h1.57q0.883 0 1.317 0.369 0.434 0.368 0.434 1.113 0 0.485-0.227 0.806-0.224 0.32-0.655 0.444zm-1.743-2.16v1.826h0.875q0.503 0 0.758-0.23 0.258-0.235 0.258-0.686 0-0.452-0.258-0.68-0.255-0.23-0.758-0.23z"
android:strokeWidth="0.5"
android:strokeColor="#000000" />
<path
android:pathData="M9.313 20.974c1.516 1.318 3.595 1.726 5.199 1.02 1.705-0.752 2.88-2.544 2.9-4.428 0.013-1.096-0.245-1.888-0.963-2.959-0.615-0.917-0.765-1.369-0.742-2.24 0.02-0.748 0.207-1.219 0.842-2.112 0.604-0.85 0.857-1.468 0.964-2.357 0.194-1.606-0.424-3.159-1.713-4.308-1.63-1.452-4.047-1.463-5.992-0.028-2.256 1.665-3.601 4.863-3.66 8.7-0.036 2.344 0.38 4.416 1.23 6.132 0.326 0.659 0.56 1.03 1.009 1.601 0.41 0.522 0.45 0.564 0.926 0.978z"
android:strokeWidth="2"
android:strokeColor="#000000" />
</vector>

View File

@ -1602,12 +1602,10 @@
<string name="pref_media_rewind_value" translatable="false">REWIND</string>
<string name="pref_device_action_broadcast_value" translatable="false">BROADCAST</string>
<string name="pref_title_touch_voice_assistant">Voice Assistant</string>
<string name="pref_title_touch_anc">Active Noise Cancelling</string>
<string name="pref_title_touch_quick_ambient">Quick Ambient Sound</string>
<string name="pref_title_touch_volume">Volume</string>
<string name="pref_title_touch_ambient">Ambient Sound</string>
<string name="pref_title_touch_spotify">Spotify</string>
<string name="pref_title_touch_other_l">Other Left</string>
<string name="pref_title_touch_other_r">Other Right</string>
<string-array name="device_action_options">
<item>@string/pref_button_action_disabled</item>
@ -1811,6 +1809,24 @@
<item>4</item>
</string-array>
<string-array name="galaxy_buds_live_equalizer_modes">
<item>@string/pref_title_equalizer_normal</item>
<item>@string/pref_title_equalizer_bass_boost</item>
<item>@string/pref_title_equalizer_soft</item>
<item>@string/pref_title_equalizer_dynamic</item>
<item>@string/pref_title_equalizer_clear</item>
<item>@string/pref_title_equalizer_trebble</item>
</string-array>
<string-array name="galaxy_buds_live_equalizer_values">
<item>0</item>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
</string-array>
<string-array name="galaxy_touch_options">
<item>@string/pref_title_touch_voice_assistant</item>
<item>@string/pref_title_touch_quick_ambient</item>
@ -1825,6 +1841,18 @@
<item>3</item>
</string-array>
<string-array name="galaxy_buds_live_touch_options">
<item>@string/pref_title_touch_voice_assistant</item>
<item>@string/pref_title_touch_anc</item>
<item>@string/pref_title_touch_volume</item>
</string-array>
<string-array name="galaxy_buds_live_touch_options_values">
<item>1</item>
<item>2</item>
<item>3</item>
</string-array>
<string-array name="sony_wh1000xm3_ambient_sound_control_names">
<item>@string/sony_ambient_sound_off</item>
<item>@string/sony_ambient_sound_noise_cancelling</item>

View File

@ -1287,10 +1287,12 @@
<string name="prefs_autoheartrate_interval">Frequency of measurements</string>
<string name="devicetype_nothingear1">Nothing Ear (1)</string>
<string name="devicetype_galaxybuds">Galaxy Buds</string>
<string name="devicetype_galaxybuds_live">Galaxy Buds Live</string>
<string name="nothing_prefs_inear_summary">Play/pause the music depending if you wear the earbuds</string>
<string name="nothing_prefs_inear_title">In-Ear detection</string>
<string name="nothing_prefs_audiomode_title">Audio mode</string>
<string name="prefs_equalizer_preset">Equalizer Preset</string>
<string name="pref_title_equalizer_normal">Normal</string>
<string name="pref_title_equalizer_bass_boost">Bass boost</string>
<string name="pref_title_equalizer_soft">Soft</string>
<string name="pref_title_equalizer_dynamic">Dynamic</string>
@ -1310,6 +1312,10 @@
<string name="prefs_ambient_voice_summary">Make voice stand out</string>
<string name="prefs_ambient_sound">Ambient Sound</string>
<string name="prefs_ambient_mode">Ambient Mode</string>
<string name="prefs_active_noise_cancelling">Active Noise Cancelling</string>
<string name="prefs_active_noise_cancelling_summary">Block noises of the surroundings</string>
<string name="prefs_pressure_relief">Pressure relief with ambient sound</string>
<string name="pressure_relief_summary">Prevent feeling of pressure in ears when not using Active Noise Cancelling</string>
<string name="prefs_left">Left</string>
<string name="prefs_right">Right</string>
<string name="prefs_galaxy_touch_options">Touch Options</string>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.preference.PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<SwitchPreference
android:defaultValue="false"
android:icon="@drawable/ic_hearing"
android:key="pref_galaxy_buds_live_anc"
android:summary="@string/prefs_active_noise_cancelling_summary"
android:title="@string/prefs_active_noise_cancelling" />
<ListPreference
android:entries="@array/galaxy_buds_live_equalizer_modes"
android:entryValues="@array/galaxy_buds_live_equalizer_values"
android:icon="@drawable/ic_equalizer"
android:key="pref_galaxy_buds_equalizer_mode"
android:summary="%s"
android:title="@string/prefs_equalizer_preset" />
<PreferenceScreen
android:icon="@drawable/ic_touch"
android:key="prefs_galaxy_touch_options"
android:persistent="false"
android:title="@string/prefs_galaxy_touch_options">
<PreferenceCategory android:title="@string/prefs_galaxy_touch_options">
<SwitchPreference
android:defaultValue="false"
android:disableDependentsState="true"
android:icon="@drawable/ic_lock_open"
android:key="pref_galaxy_buds_lock_touch"
android:summary="@string/prefs_touch_lock_summary"
android:title="@string/prefs_touch_lock" />
<ListPreference
android:dependency="pref_galaxy_buds_lock_touch"
android:entries="@array/galaxy_buds_live_touch_options"
android:entryValues="@array/galaxy_buds_live_touch_options_values"
android:icon="@drawable/ic_touch"
android:key="pref_galaxy_buds_touch_left"
android:summary="%s"
android:title="@string/prefs_left" />
<ListPreference
android:dependency="pref_galaxy_buds_lock_touch"
android:entries="@array/galaxy_buds_live_touch_options"
android:entryValues="@array/galaxy_buds_live_touch_options_values"
android:icon="@drawable/ic_touch"
android:key="pref_galaxy_buds_touch_right"
android:summary="%s"
android:title="@string/prefs_right" />
</PreferenceCategory>
</PreferenceScreen>
<PreferenceCategory android:title="@string/prefs_galaxy_buds_experimental">
<SwitchPreference
android:defaultValue="false"
android:icon="@drawable/ic_videogame"
android:key="pref_galaxy_buds_game_mode"
android:summary="@string/prefs_game_mode_summary"
android:title="@string/prefs_game_mode" />
<SwitchPreference
android:defaultValue="false"
android:icon="@drawable/ic_engineering"
android:key="pref_galaxy_buds_live_pressure_relief"
android:summary="@string/pressure_relief_summary"
android:title="@string/prefs_pressure_relief" />
</PreferenceCategory>
</androidx.preference.PreferenceScreen>