1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-07-17 02:44:04 +02:00
Commit Graph

482 Commits

Author SHA1 Message Date
FYG_license_bot_ignore_me
4c7476845b Update license headers and CONTRIBUTORS file 2024-01-10 19:01:48 +01:00
José Rebelo
564cb1bfcc Introduce WeatherSpec v4
New fields for current weather:

- dewPoint
- pressure
- cloudCover
- visibility
- sunRise
- sunSet
- moonRise
- moonSet
- moonPhase
- airQuality
- latitude
- longitude
- feelsLikeTemp
- isCurrentLocation

New fields for daily forecast:

Deprecate the old "Forecast" class, which was not versioned, but keep it for backwards compatibility with old apps. Old WeatherSpec forecasts are de-serialized into the new Daily class. New fields:

- windSpeed
- windDirection
- uvIndex
- precipProbability
- sunRise
- sunSet
- moonRise
- moonSet
- moonPhase
- airQuality

Add hourly values:
- timestamp
- temp
- conditionCode
- humidity
- windSpeed
- windDirection
- uvIndex
- precipProbability

Air Quality:
- aqi (plume)
- co
- no2
- o3
- pm10
- pm25
- so2
- coAqi
- no2Aqi
- o3Aqi
- pm10Aqi
- pm25Aqi
- so2Aqi
2023-08-27 15:13:57 +00:00
José Rebelo
531aef61fd Move screenshot encoding to PebbleProtocol 2023-06-14 21:02:27 +01:00
Arjan Schrijver
b1d03e9f7a Clean up duplicated unimplemented methods from device support classes
Moved to AbstractDeviceSupport so each device support class can override them if required. This change helps to keep the code base clean by not requiring every (Device)Support class to implement these methods even when they don't need them.
2023-01-05 22:11:32 +01:00
Andreas Shimokawa
969164ba5d Remove KitKat support 2022-09-10 12:04:16 +02:00
dakhnod
4a8523f790 multi-device-support (#2526)
this PR aims to add device for multiple connected devices at once.

A lot of stuff already works, some things need to be done:

- [x] change DeviceCommunicationService to hold multiple devices and supports
- [x] implement connect / disconnect logic
- [x] widgets, not really suited for multiple devices, so far
- [x] change the notification to show multiple devices
- [ ] change GBDeviceService#onFindDevice and similar API functions to target individual devices, not all connected.
- [x] move auto-reconnect setting to device settings
- [x] fix music event crash
- [x] work out behaviour when pressing "connect" from notification
- [ ] handle service crashes
- [ ] suit coordinator methods for multiple devices of same kind
- [x] change ACL_CONNECTED receiver to connect to devices that are not currently registered in DeviceCommunicationService
- [ ] adjust after-boot auto-connection logic
- [ ] fix hanging device support. Device says disconnected, GB says connected
- [x] firmware updater doesn't work

My attempt to make onFindDevice work was to change the arguments to ```EventHandler#onFindDevice(GBDevice device, boolean start)```.
The Problem is that this forces the device-specific implementations to also accept GBDevice as an argument.

Co-authored-by: Daniel Dakhno <dakhnod@gmail.com>
Co-authored-by: Andreas Shimokawa <shimokawa@fsfe.org>
Co-authored-by: dakhnod <dakhnod@gmail.com>
Reviewed-on: https://codeberg.org/Freeyourgadget/Gadgetbridge/pulls/2526
Co-authored-by: dakhnod <dakhnod@noreply.codeberg.org>
Co-committed-by: dakhnod <dakhnod@noreply.codeberg.org>
2022-06-14 18:05:41 +02:00
License Bot
1b5402dcb4 update license headers 2021-01-10 23:38:13 +01:00
Andreas Shimokawa
0d49eaaf9e Pebble: move canned message to per-device settings (including migration)
This also cleans up some useless preferencehandlers that only change summary by
using app:useSimpleSummaryProvider="true" for EditText
2020-10-13 00:27:22 +02:00
TaaviE
6cd59fbd24 Refactored all pairing and bonding activities (#1989)
Fixed a few warnings

Refactored all bonding and bonding activities

Co-authored-by: TaaviE <taavi.eomae+github@gmail.com>
Reviewed-on: https://codeberg.org/Freeyourgadget/Gadgetbridge/pulls/1989
2020-08-28 15:38:18 +02:00
TaaviE
7db3b68047 Fixed a bunch of warnings 2020-08-26 09:38:31 +02:00
TaaviE
26e4f1eb3e Fixed a small misspell 2020-02-05 02:03:51 +02:00
License Bot
d6fa5d0dd5 Update license headers 2020-01-09 10:44:32 +01:00
FYG_license_bot_ignore_me
8e5c4b4602 Update license headers 2019-11-23 21:53:22 +01:00
Andreas Shimokawa
c2db30274f Make reconnect logic more device agnostic and remove pebble reconnect logic 2019-11-20 10:53:25 +01:00
cpfeiffer
17f24c06f8 Fix some LGTM issues 2019-09-19 23:18:17 +02:00
Andreas Shimokawa
8374a2b8f8 Widget: also try to signal sleep/steps updates for pebble 2019-09-16 23:18:12 +02:00
Andreas Shimokawa
fcc9ad8f95 Widget: Also update for Pebble Misfit and Morpheuz
This commit also removes GBDeviceEventSleepMonitorResult since it was unused and highly Morpheuz specific
2019-09-16 22:48:21 +02:00
Matej Drobnič
580d70e910 add pebblekit extension for reopening last app 2019-04-23 20:12:53 +02:00
License Bot
9aadb2f2fd Update license headers 2019-04-21 18:53:10 +02:00
Sebastian Kranz
6a04c78b0e Merge branch 'master' of https://github.com/Freeyourgadget/Gadgetbridge into zetime 2019-02-20 14:24:59 +01:00
Sebastian Kranz
a7553188f9 Reading the device preferences from the watch and set them in the ZeTime menu. 2019-02-20 14:09:21 +01:00
License Bot
beedb653e6 Update license headers 2019-02-13 20:43:31 +01:00
Daniele Gobbetti
75d3dffb14 Migrate to androidx support libraries and bump compile SDK version
"Optimize imports" has been run on all source files, there might be
unrelated changes, but these should be harmless.
2019-01-26 16:00:56 +01:00
Johann C. Rode
00dfcd1564 fix typo 2019-01-07 23:53:00 +01:00
Johann C. Rode
f613926ce0 rectify (c) 2019-01-07 23:53:00 +01:00
Johann C. Rode
9d7b1fd6b7 Added support for popular Pebble watchfaces RealWeather and YWeather, fixed some typos 2019-01-07 23:53:00 +01:00
jcrode
c69be1f94b Pebble: add support for weather information for watchface M7S
Watchface name: Multifunctional Seven Segment 
Repo: https://github.com/cfg1/pebble-mss
2018-12-27 16:20:29 +01:00
Andreas Shimokawa
b020d59f54 Implement factory reset feature in debug activity
Implemented for Mi Band 1/2/3, Cor, Bip

Could be implemented for Pebble by deleting all blobdbs etc

Related to #109
2018-12-16 16:06:12 +01:00
Andreas Shimokawa
59f8e72410 Notification actions refatoring and fixes
- Fixes "Mute, Open, Dismiss" to work again on pebble
- Greatly reduces complexity in PebbleProtocol, since all logic for adding specific reply actions to notification have been moved to generic code

Fixes the rest of #1336 (the part that says "Additionally, dismissing a notification on the watch no longer dismisses it on the Android device")
2018-11-15 15:53:04 +01:00
Andreas Shimokawa
10b982f0ea Pebble: Proper fix for crash when no replies are set
Also:
- Support for multiple reply actions with canned replies (there must have been a crash before)
- When no replies are set use the firmware internal defaults

Fixes #1323
2018-11-08 08:36:37 +01:00
Andreas Shimokawa
78addcb75c Pebble: try to prevent crash when no canned replies have been set 2018-11-07 22:02:58 +01:00
Andreas Shimokawa
fcfcc5cb0b Pebble: unify code for 2.x and >= 3.x notification encoding
Not very clean but deduplicated a lot of code which was no longer maintainable twice
2018-11-02 21:10:31 +01:00
cpfeiffer
effffddd8d fixed lgtm warnings 2018-11-02 00:09:30 +01:00
Daniele Gobbetti
549dfce2e7 Pebble: generalize handling of incoming actions (from watch)
Also add missing casts back to int in NotificationListener
2018-11-01 19:40:26 +01:00
Andreas Shimokawa
f05cc83848 Pebble: set MIN_ACTION_LENGTH = 6, which is correct 2018-11-01 16:02:29 +01:00
Andreas Shimokawa
f3e16c5b1d Pebble: Fix regression causing "Open on Phone" and "Dismiss" to appear on Pebble notification with no corresponding Android notification (i.e. PebbleKit notifications) 2018-11-01 14:55:14 +01:00
Daniele Gobbetti
eede85a9c9 Various improvements and bugfixes to notification handling
Prevent duplicate notifications with a dedicated data structure (not reusing
the anti-burst one) #1062, #657
Pebble: Forward the actions attached to notifications (not only reply)
inspired by the work of dnastase #705
2018-10-31 21:47:12 +01:00
cpfeiffer
c1de677448 Remove redundant null checks 2018-09-16 13:58:01 +02:00
cpfeiffer
08dfa2a47d Log the stacktrace as well 2018-09-16 00:12:52 +02:00
cpfeiffer
f142003f09 Avoid boxing 2018-09-16 00:12:40 +02:00
License Bot
696653eabf Update contributors list and license headers. 2018-08-29 21:30:23 +02:00
Pavel Elagin
723b5af50f Redundant String.toString() 2018-08-08 12:55:25 +03:00
License Bot
225a600aed Update license headers 2018-06-25 18:35:46 +02:00
Andreas Shimokawa
c6b23041f7 Pebble: Always connect to SDP UUID on NON-LE Pebble
Fixes #726
2018-06-20 22:06:45 +02:00
Daniele Gobbetti
3c3e38741a Pebble: remove the legacy countdownlatch on Pebble GATT server code
The GATTServer code is now in line with the new GATTClient code.
2018-05-19 22:42:05 +02:00
Andreas Shimokawa
511fef7f62 Pebble 2: when using client only mode, no not wait for PPoGATT ACKs after each package
This speeds up things up a lot. We should still somehow limit it, but not by waiting
after one PPoGATT ACK after each complete PP package.

This leaves the old mode untouched, so we have something to compare
2018-05-12 17:18:19 +02:00
Andreas Shimokawa
9e2558beac Pebble 2: make gatt client only mode available to users 2018-05-11 14:23:41 +02:00
Andreas Shimokawa
cdf6039d4c Pebble 2: fixes for experimental client only gatt code
This basically makes sure that
- only one gatt write operation is in progress
- data is not sent from within callbacks to prevent a deadlock when waiting for a nre callback that cant happen yet beause the current has not been retuned
2018-05-11 13:21:40 +02:00
Andreas Shimokawa
f6131772d6 Pebble2: WIP broken and disabled GATT client only support
This will eliminate the need for the Phone being a GATT Server and might lead
to better connection stability once it is ready.

NOTE: Enabling this in the code (change clientOnly=true in PebbleLESupport)
will only work for a few packets before in totally breaks, so only enable
if you want to fix it :P
2018-05-10 22:03:03 +02:00
Daniele Gobbetti
cc83021ae3 Weather (and Pebble Webview): fix name and add wind information to weather data
Wind information are stored and put in the reconstructed OWM response.
A long standing bug (having the "name" field inside "main" instead of at
the root level of the json) has been fixed
Lineage OS receiver and if possible weather notification app receiver will
be added in further commits.

See #482
2018-04-14 19:42:05 +02:00