Commit Graph

6213 Commits

Author SHA1 Message Date
José Rebelo
ef3509446e Zepp OS: Remove notification picture paths on notification delete 2024-11-25 18:16:09 +00:00
Daniele Gobbetti
b70c2af117 Garmin: initial plumbing for notifications' images (blind implementation)
This commit adds the signaling of notifications with images to the watch.
According to https://codeberg.org/Freeyourgadget/Gadgetbridge/issues/3469 the watch should followup with a protobuf request "MediaRequest".
The protobuf is documented in https://gadgetbridge.org/internals/specifics/garmin-protocol/#mediarequest

As examples and only intended to help further developments, two new methods getNotificationAttachmentPath and getNotificationAttachmentBitmap are added to GarminSupport
2024-11-25 18:16:07 +00:00
José Rebelo
4cf076b3fa Fix edge case where chart tabs were reset to single value on debug build 2024-11-24 21:33:36 +00:00
Arjan Schrijver
6f8fbd9b3c Add buttons to DebugActivity for Welcome and Permissions 2024-11-24 21:14:23 +01:00
Arjan Schrijver
765e6950dc Add preference migration for existing users 2024-11-24 21:14:23 +01:00
Arjan Schrijver
fc4fea35cd Scroll Notification and Overlay permissions screens to GB automatically 2024-11-24 21:14:22 +01:00
Arjan Schrijver
77d0d545c8 Make strings translatable 2024-11-24 21:14:22 +01:00
Arjan Schrijver
11f38aff15 Remove option to start first run screens from preferences 2024-11-24 21:14:22 +01:00
Arjan Schrijver
79a846a907 Add theme selector to first screen 2024-11-24 21:14:22 +01:00
Arjan Schrijver
20d6c87dd8 Improve background location permission request flow 2024-11-24 21:14:22 +01:00
Arjan Schrijver
5a3bc94f86 Hide Permissions title when action bar is visible 2024-11-24 21:14:22 +01:00
Arjan Schrijver
b3b665ab6c Actually improve requesting all permissions 2024-11-24 21:14:22 +01:00
Arjan Schrijver
2422e02e5d Improve requesting all permissions 2024-11-24 21:14:22 +01:00
Arjan Schrijver
a889f671d7 Improve permissions descriptions 2024-11-24 21:14:22 +01:00
Arjan Schrijver
4c86c275f8 Fix missing permission request buttons 2024-11-24 21:14:22 +01:00
Arjan Schrijver
13c8061507 Add back permission explanation dialogs 2024-11-24 21:14:22 +01:00
Arjan Schrijver
32c92c3533 Add First Start screens with permissions screen 2024-11-24 21:14:22 +01:00
José Rebelo
c52fd53ebd Garmin: Persist sleep score 2024-11-24 19:44:18 +00:00
José Rebelo
5531ddc49a Restore sleep balance on weekly and monthly charts 2024-11-24 18:36:20 +00:00
AndrewP
b2b79c99cd Workouts Freestyle and OutdoorWalkingV2 for Xiaomi Smart Band 8 Active 2024-11-24 17:15:05 +00:00
José Rebelo
e54b7959a4 Calories: Cleanup and fix some inconsistencies 2024-11-24 16:55:25 +00:00
a0z
27c4cc95c9 Calories: remove total goal 2024-11-24 16:50:51 +00:00
José Rebelo
3ad2e827c2 Calories: Fix some crashes 2024-11-24 16:50:51 +00:00
José Rebelo
df138e9c79 Add DefaultRestingMetabolicRateProvider 2024-11-24 16:50:51 +00:00
a0z
37ea9bc571 Calories: fix loading lag, gap 2024-11-24 16:50:51 +00:00
a0z
622d37ed38 Calories: add fragment 2024-11-24 16:50:51 +00:00
José Rebelo
60ab38db57 Garmin: Resting metabolic rate 2024-11-24 16:50:51 +00:00
Martin.JM
78d6ad3a1f Huawei: Fix some linter warnings 2024-11-24 13:41:58 +01:00
Martin.JM
c5a5cd1649 Huawei: Send weather error if there is no data
This will hopefully reduce the number of requests from the watches if
there is no weather data available.
2024-11-24 13:41:53 +01:00
José Rebelo
4d5141c765 Zepp OS: Fix TGA id 2024-11-23 23:40:24 +00:00
José Rebelo
9174d95894 Zepp OS: Send notification pictures 2024-11-23 22:04:42 +00:00
Daniele Gobbetti
4aa145560a Add support for picture attachments in notifications
Also adds a local cache for pictures which is handled by the NotificationListener itself.

If the picture is hosted in a third party content provider it gets queried.
If the Bitmap is embedded in the notification, the local cache is used.

In any case the NotificationSpec just holds a String to the absolute file path
2024-11-23 21:15:47 +00:00
José Rebelo
7aa7de6463 Colmi R0x: Remove all background tasks on dispose
Somehow, the tasks were not being fully removed on dispose, which would
result in a crash. I am not able to reproduce the issue reliably, but
removing all the background tasks on dispose should fix the issue.
2024-11-21 22:52:04 +00:00
cdvrs
16aed1364b GBX-100: Fix notification title 2024-11-20 08:17:56 +00:00
Renato Aguiar
212289645f Add Garmin Instinct 2 2024-11-19 20:59:05 +00:00
José Rebelo
6b5c5ae0ac Garmin: Fix weather temperature conversion to celsius 2024-11-19 20:57:04 +00:00
José Rebelo
9d1a57b6c2 Fix crash in some chart pages (#4319) 2024-11-19 20:53:34 +00:00
MrYoranimo
b5bd4da9b1 Xiaomi SPPv2: Catch exception thrown in onPacketReceived
When a received packet causes an exception to be thrown while
getting handled in the service's onPacketReceived method, the
message will get stuck in the queue because it is never released.
Subsequently received messages get lined up after the first message
that causes an exception, and since that message is never removed,
those newer messages are never processed.

Catching the exception thrown from within the onPacketReceived method
allows the code flow to continue and therefore remove the troubling
message from the queue.
2024-11-18 23:25:28 +01:00
José Rebelo
1d2404a4e6 Garmin: Display AGPS age 2024-11-17 19:00:00 +00:00
Martin.JM
39e7bd8c62 Huawei: Add non-P2P HR zones configuration 2024-11-17 17:57:30 +00:00
José Rebelo
5f91715c89 Realme Buds T110: Initial support 2024-11-17 17:23:23 +00:00
José Rebelo
1618fda418 Log exceptions during DBAccess async tasks 2024-11-17 00:01:40 +00:00
José Rebelo
e453855e88 Do not suppress repeated notifications if timestamp is in the future (#4327) 2024-11-16 21:46:22 +00:00
Me7c7
dc1533b4ed Huawei: Initial music managment support 2024-11-16 20:41:23 +00:00
José Rebelo
1a3a7dec05 Prevent heart rate average from using invalid samples 2024-11-16 14:08:06 +00:00
José Rebelo
87bc2e6ed7 Fix imperial unit on steps charts 2024-11-15 23:16:40 +00:00
CaptKentish
9bd828814e Add water sports icons (#4322) 2024-11-15 22:09:44 +00:00
huyz
6aa7280967 Add some workout icons 2024-11-14 23:25:28 +00:00
José Rebelo
f16e2eeabb Test device: Add dummy activities 2024-11-14 23:22:18 +00:00
José Rebelo
9b6fce566d Mi Band 9: Fix outdoor cycling parsing 2024-11-12 23:32:11 +00:00
mvn23
31b8fd683d Add wear sensor toggle to Bowers and Wilkins P Series 2024-11-11 02:15:41 +01:00
José Rebelo
82f221752e Compute activity average speed 2024-11-10 22:50:58 +00:00
José Rebelo
810df3055c Garmin Forerunner 55/620: Initial support 2024-11-10 22:33:48 +00:00
José Rebelo
a72de07d2a Oppo Enco Air: Initial support 2024-11-10 22:18:41 +00:00
José Rebelo
7a0e43a4de GBDevice: Do not unset firmware from dynamic state
It is not clear why this was being done, but it is the source of issues
for multiple devices, since the ensureDeviceUpToDate function will
attempt to persist the null values, in non-nullable columns.
2024-11-10 22:16:14 +00:00
Me7c7
ce32ac7272 Huawei: Do not print exception if the ephemeris file does not exist 2024-11-09 20:04:55 +02:00
Martin.JM
2a865fe498 Huawei: Fix SmartAlarm for Huawei Watch GT
Linked to #4308.
2024-11-09 17:58:46 +00:00
Alik Aslanyan
f3185f1acb
Fix null elements for some mixed case words in Armenian (combinations with U and Vo) 2024-11-09 20:23:57 +04:00
mvn23
6bb93bef89 Add ANC and Passthrough options to Bowers and Wilkins P Series (#4297)
Co-authored-by: mvn23 <schopdiedwaas@gmail.com>
Co-committed-by: mvn23 <schopdiedwaas@gmail.com>
2024-11-09 15:29:44 +00:00
gjaekel
7c1d44fcd3 Add support for HUAWEI Band3Pro (#4296)
Co-authored-by: gjaekel <gjaekel@noreply.codeberg.org>
Co-committed-by: gjaekel <gjaekel@noreply.codeberg.org>
2024-11-09 15:20:48 +00:00
José Rebelo
a2323ce845 Withings: Fix crash on connection 2024-11-09 08:16:12 +00:00
Arjan Schrijver
5a0f1e46db Garmin Fenix 6S Pro: Initial support 2024-11-08 09:11:47 +01:00
Martin.JM
126102aa05 Add tests and a couple of fixes 2024-11-05 23:43:41 +00:00
Martin.JM
f0ffc0e165 Add high res HR to activity sleep chart fragment 2024-11-05 23:43:41 +00:00
Martin.JM
82e3a86350 Implement high res HR data
Specifically for:
- The HR fragment
- The sports activity graph

Also adds support for Huawei high res HR, and high res SpO2.
2024-11-05 23:43:41 +00:00
Me7c7
ae84678de8 Huawei: Sync dict data over P2P. Sync skin temperature. 2024-11-05 23:42:19 +00:00
huyz
68caf6a60f Huawei: map activity type 14 to hiking activity 2024-11-04 21:26:31 +08:00
mvn23
d53971c881 Add initial Bowers and Wilkins P series support. (#4288)
Co-authored-by: mvn23 <schopdiedwaas@gmail.com>
Co-committed-by: mvn23 <schopdiedwaas@gmail.com>
2024-11-01 21:06:34 +00:00
José Rebelo
46dd45cb4e Garmin Forerunner 235: Initial support 2024-10-31 23:47:20 +00:00
Me7c7
a7c19c8190 Huawei: calculate HR Zones for walking and running workouts. 2024-10-31 23:14:04 +00:00
José Rebelo
292a5d11b5 Activity Charts: Update date info when refreshed 2024-10-30 20:51:02 +00:00
Zahnstocher
a6053eda77 Add support for Sony WI-C100 2024-10-30 20:47:37 +00:00
Zahnstocher
cbd9a7b8af Add voice notifications for Sony WF-C500 2024-10-30 14:31:16 +01:00
a0z
a79cd94de9 HRV Status: segment detection fix 2024-10-28 22:37:54 +01:00
Arjan Schrijver
d5c2207a48 Colmi R0x: Improve sleep handling around DST changes 2024-10-28 11:41:31 +01:00
Me7c7
d95b2afad3 Huawei: map activity type 4 to mountain hike activity 2024-10-27 10:50:40 +02:00
Me7c7
5f822149bc Huawei: Send default HR Zones config to the device using P2P service 2024-10-27 07:40:03 +02:00
Martin.JM
27f61138bc Huawei: Fix notifications for Huawei Band 4e
Fixes #3957
2024-10-27 00:48:33 +02:00
Martin.JM
cc16906d20 Huawei: Fix for sample provider 2024-10-26 20:29:33 +00:00
Arjan Schrijver
d4033dbccb Colmi R0x: Fix HR database timestamps 2024-10-26 22:08:36 +02:00
José Rebelo
ba82de99d3 Garmin: Upload workout fit files 2024-10-26 21:03:58 +01:00
Patrick Rudolph
42b7153162 huawei: Decode TruSleep data in test new functionality
Download TruSleep data and extract ACC and PPG packets.
For now the data is only extracted and provided to an analysis
function that does nothing as printing the data as the TruSleep
algorithm is unknown.

With this patch it's possible to do sleep analysis using open source
algorithms, however it's not clear which one to use and how similar
the results would be. A possible use case would be Sleep as Android.

The extracted data contains of Accelerometer data (ACC) and
photoplethysmogram (PPG) data.

ACC packets:
- about every 60 seconds
- contain a timestamp
- contain the activity on one accelerometer axis
  0x00: no activity
  0xff: high activity (like walking)

PPG packets:
- contain a timestamp
- contain raw PPG samples, each with a 10msec based timestamp

This commit allows more developers and researchers to look into sleep
analysis as they gain access to the raw sleep data optained from the watch.

For issue #3860.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2024-10-26 16:02:14 +00:00
Martin.JM
ce7b0db5b1 Huawei Sample Provider: Provide a sample every minute
Fixes #4068.
2024-10-26 15:58:12 +00:00
José Rebelo
bbadb2b1ef Garmin: Fix crash on timezones without DST 2024-10-26 16:53:30 +01:00
José Rebelo
c628ce2c97 Garmin: Fix all-day events
As per the CalendarContract, the begin timestamp corresponds to the UTC
midnight-boundary of the start of the day.

- Remove the redundant logic to truncate the date to the start of day
- Remove the workaround for negative timezones (confirmed not workin
  with some EDT users)
- Ensure birthdays also respect the UTC boundary
- Offset the garmin timestamps by the UTC offset, ensuring they match
  midnight on the user's timezome (fixes all-day events offset by 1 day)
2024-10-26 11:53:20 +01:00
Me7c7
a46e970f84 Huawei: more details for swim workout 2024-10-26 10:41:29 +00:00
Me7c7
3294e20242 Huawei: clear calendar on reconnect. 2024-10-26 11:50:05 +03:00
Me7c7
bc56213eba Huawei: improve texts for file uploads, music icon 2024-10-25 22:39:55 +00:00
Me7c7
3bb44d8050 Huawei: Use default value for channels. Parse sample rates. 2024-10-25 22:39:55 +00:00
Me7c7
d23c931f95 Huawei: device specific fixes. Watch 3 for example 2024-10-25 22:39:55 +00:00
Me7c7
48717aaf42 Huawei: Initial music upload support 2024-10-25 22:39:55 +00:00
Me7c7
b18fb901e6 Huawei: send more user info. Fix issue with weight 2024-10-25 22:16:38 +00:00
Me7c7
e124ac4974 Huawei: fix Send thresholds packet 2024-10-25 22:16:38 +00:00
José Rebelo
22eebf9592 Garmin Fenix 7: Initial support 2024-10-25 18:18:41 +01:00
Me7c7
f0c4f0f04a Huawei: fix calendar events update 2024-10-24 18:18:12 +00:00
Arjan Schrijver
b2df6e58f0 Colmi R0x: Improve HR fetching accuracy
Hopefully fixes #4209
2024-10-23 21:35:48 +02:00
José Rebelo
e25757846f Add link to background service troubleshoot page 2024-10-22 22:18:17 +01:00
José Rebelo
69530de0c6 Set changelog version code when restoring zip backup 2024-10-19 21:00:53 +01:00
Me7c7
0e00d74913 Huawei: Fixed workout data parser 2024-10-17 15:36:58 +03:00
Me7c7
d2cf281b00 Huawei: fetch more workout summary from the watch 2024-10-17 10:06:31 +03:00
José Rebelo
9267b4fcf3 Mi Band 9: Fix strength training 2024-10-16 23:43:11 +01:00
José Rebelo
e6dc262a4d Xiaomi-protobuf: Fix some workout type recognition 2024-10-16 23:40:13 +01:00
José Rebelo
2abe7e5b2f Fix weekly and monthly sleep times for devices without awake sleep
The last sleep stage on these is not "awake sleep" and should be
included.
2024-10-16 23:07:41 +01:00
José Rebelo
a0d7c8b77b Huawei: Fix battery notifications 2024-10-16 22:54:40 +01:00
José Rebelo
f0cce348c4 Xiaomi-protobuf: Fix naps 2024-10-16 22:46:19 +01:00
Arjan Schrijver
2618d54f94 Fix crash in LiveActivityFragment that was introduced by 2398dd0fb 2024-10-16 22:18:56 +02:00
José Rebelo
f9f3e8849b Mi Band 9: Fix walk workout parsing 2024-10-16 19:38:15 +01:00
Linos Giannopoulos
f3b4f0ed26 Add device support for the IKEA desk controller
All the required functionality is included:
- Move the desk up and down manually
- See the current height and speed
- Store three desk positions
- Move to any of those desk positions
2024-10-15 18:23:56 +00:00
Arjan Schrijver
25dc3f972b Colmi R0x: Add support for Colmi R10 2024-10-15 18:19:09 +02:00
Arjan Schrijver
2398dd0fbe Limit LiveActivityFragment to just the current device 2024-10-15 11:19:33 +02:00
René Vögeli
ace0aa3ea7 Colmi R0x: Fix big data packet handling 2024-10-14 21:20:26 +00:00
Vitaliy Tomin
175f4bf60c huawei: Add new gadget Huawei Watch D2 2024-10-14 18:00:49 +00:00
José Rebelo
b595a1ad96 Huawei Watch Fit 3: Enable emoji 2024-10-13 22:20:02 +01:00
José Rebelo
10a7550232 Garmin: Map some health snapshot fields 2024-10-13 21:28:37 +01:00
José Rebelo
1f4987ab98 Huawei: Enable emoji for HarmonyOS watches 2024-10-13 19:01:14 +00:00
Me7c7
80967ce42b Huawei: fix pace update when more than one packets received 2024-10-13 19:01:03 +00:00
Me7c7
0e6a3e13cc Huawei: specify pace order 2024-10-13 19:01:03 +00:00
Me7c7
15f550d5a8 Huawei: Show pace summery before table. More summary. 2024-10-13 19:01:03 +00:00
Me7c7
af64ff3a79 Huawei: fix workouts pace 2024-10-13 19:01:03 +00:00
José Rebelo
58a8c91c80 Activity Details: Fix table after odd number of cells 2024-10-13 19:55:09 +01:00
René Vögeli
c66467a915 Colmi R0x: Add support for HRV 2024-10-13 20:10:50 +02:00
Arjan Schrijver
4939de47c1 Colmi R0x: Add support for HRV 2024-10-13 17:29:43 +00:00
MrYoranimo
0a9da03618 Xiaomi: extract watch face preview image 2024-10-13 13:11:39 +00:00
MrYoranimo
b2cf83d002 Xiaomi: extract translatable watch face name 2024-10-13 13:11:39 +00:00
MrYoranimo
47acfd2775 Xiaomi: fix watchface ID check
The identifier for a watch face is stored as a decimal number in ASCII.
Since there are 64 bytes available to store the identifier, the highest
value to be expected is 10^(64*10), which exceeds the limit of a 32-bit
integer.
2024-10-13 13:11:39 +00:00
José Rebelo
92fd556c5f Garmin: Map some missing realtime settings icons 2024-10-13 13:52:48 +01:00
José Rebelo
d47a08479d Garmin Fenix 6S Sapphire / Venu Sq 2: Initial support 2024-10-13 13:39:43 +01:00
José Rebelo
92004ce4de Fix activity icon after filter reset 2024-10-13 08:59:46 +01:00
José Rebelo
427b7c7557 Activity details: Refactor header 2024-10-12 23:24:14 +01:00
Severin von Wnuck-Lipinski
98775b752b Add Mijia comfort level preferences 2024-10-12 21:36:18 +02:00
José Rebelo
c2668d2e6c Add average line to HR chart 2024-10-12 19:00:26 +01:00
José Rebelo
6474a6092e GPXExporter: Include speed and cadence 2024-10-12 16:57:02 +01:00
José Rebelo
bf7b6e2329 Fix wrong parameter type 2024-10-12 13:40:35 +01:00
José Rebelo
598e737f10 Garmin: Map some missing fields in FitRecord 2024-10-12 13:33:37 +01:00
José Rebelo
bd3b7467a4 Garmin/Zepp OS: Display resting HR 2024-10-12 13:21:20 +01:00
José Rebelo
fb1d0a92cc Garmin: Add resting heart rate sample provider 2024-10-11 23:51:44 +01:00
José Rebelo
b331c53763 Garmin: Parse skin temperature messages 2024-10-11 23:09:40 +01:00
José Rebelo
8c949ff6ab Garmin: Persist respiratory rate 2024-10-11 22:29:55 +01:00
José Rebelo
329eb2c62e Garmin Venu Sq: Initial support 2024-10-10 23:14:01 +01:00
José Rebelo
400d2aeaba Garmin Fenix 8: Initial support 2024-10-10 20:47:35 +01:00
Arjan Schrijver
f9150f4c2c Colmi R0x: Fix factory reset packet bytes 2024-10-10 10:16:09 +02:00
a0z
cac9b702a2 Activity list - move activity label below, revert background color set 2024-10-09 21:19:41 +01:00
a0z
c7bac30ef0 Activity list - redesign 2024-10-09 21:19:35 +01:00
José Rebelo
d782169a64 Garmin: Fix rxnetworks AGPS header recognition 2024-10-09 19:01:59 +01:00
José Rebelo
94572805e9 Colmi R0x: Check factory reset flags on onReset
This function is also called for a simple reboot.
2024-10-08 18:20:26 +01:00
Arjan Schrijver
9abcb87f1f Colmi R0x: Normalize timestamps of all received health data
This fixes the duplicate samples reported in #4209, and possibly even
the originally reported issue of multiple days showing the same HR data
in the charts.
2024-10-08 16:34:18 +02:00
Arjan Schrijver
873a044a69 Colmi R0x: Increase logging of V2 packets 2024-10-08 13:17:58 +02:00
Arjan Schrijver
ba3e60376d Colmi R0x: Add factory reset function 2024-10-08 13:17:19 +02:00
José Rebelo
95b6485965 Add button to share JSON details 2024-10-06 22:24:04 +01:00
José Rebelo
22a6d9b7d9 Refactor activity lists to use a RecyclerView 2024-10-06 22:24:04 +01:00