Commit Graph
28 Commits
Author SHA1 Message Date
Daniele Gobbetti afc4c9efaa Added some javadocs 2015-08-03 18:35:58 +02:00
Daniele Gobbetti c798cd00fe Prevent tearing of the barchart values over other graph elements 2015-08-03 18:34:58 +02:00
Daniele Gobbetti 878afd79df Allow the user to set the target number of steps for each day (fitness goal), both in the sharedpreferences and in the MiBand.
The value is then used in the graphs.

#31 #44
2015-07-29 18:49:16 +02:00
Daniele Gobbetti 27669761bf Fix potential race condition when counted steps are above the daily target.
Also added a few comments wrt the labels and the values of the pie chart.
2015-07-29 18:07:35 +02:00
Daniele Gobbetti 1bef702485 Send the progress updates from the actual BT transfer, which is where most of the time is spent. 2015-07-28 22:38:52 +02:00
Daniele Gobbetti 23f752dc20 New firmware tested. 2015-07-28 22:03:53 +02:00
Daniele Gobbetti 14f754306d Use a single queue for the whole firmware transfer.
At the moment the progress bar code is not useful because the FW preparation is almost instantly done, and is the BT transfer that takes time.

The transfer happens when the getQueue method is called, and there is no progress info that I can find.
2015-07-28 19:15:25 +02:00
Daniele Gobbetti 47cbf68c37 Merge remote-tracking branch 'upstream/master' into firmware_update 2015-07-25 21:36:46 +02:00
Daniele Gobbetti c4590d3989 Update Changelog.
Typo
2015-07-25 21:31:22 +02:00
Daniele Gobbetti 0dd29807b2 Update Changelog.
Prepare for release
2015-07-25 21:29:31 +02:00
Daniele Gobbetti 8f840df5f6 Set GB notification visibility to public.
This way on android 5 the status of the connection is shown also on the lockscreen even if the user chose to hide sensible content of the notifications.
2015-07-25 21:14:18 +02:00
Daniele Gobbetti d967411d70 Add a toast to let the user know about the progress of the transfer. 2015-07-19 16:16:58 +02:00
Daniele Gobbetti 6953086c99 Allow setting alarms once for the next day.
(cherry picked from commit 417ea02)
2015-07-19 15:58:30 +02:00
Daniele Gobbetti 7f7cea75c1 Spare some complexity by letting the writer change the status to non-busy.
Before the code looked for the values written to the device with another method.
2015-07-19 15:52:27 +02:00
Daniele Gobbetti 3068d687bf Adressed some of the observations made re the last commits. 2015-06-30 06:40:46 +02:00
Daniele Gobbetti 371a7bb4af Get rid of the Checkedtextview because they weren't in line with the our style 2015-06-30 06:40:46 +02:00
Daniele Gobbetti 1caca1439a Initial implementation of setting alarms to the Mi Band.
The code basically works, but there a lot of things to fix / improve.
* The alarms are stored to and read from the Shared Preferences, but there is no persistence within the app (basically they are read and stored at every access)
* The alarm list is not updated when coming back from the alarm detail view (probably related to the point above), but the actual alarm is
* The alarms preference names is sometimes built by concatenating strings, which is not really safe
* There is no check in the alarm constructor whether the stored string is a valid alarm representation
* Even though only 3 alarms can be stored on the device, we could have more in the app and let the user choose which to sync
* In the alarm detail view XML some material* drawables are used, it's possible that these break on android version < 5
* ...
2015-06-30 06:40:14 +02:00
Daniele Gobbetti ac7e21be48 Remove the activity log debug file.
This partially reverts commit 8b268a676c
2015-06-12 22:30:14 +02:00
Daniele Gobbetti fc374881c5 Get rid of the unused ID in the DB, this could help in:
* reducing the used space
* reducing the time needed for inserts
2015-06-04 21:37:48 +02:00
Daniele Gobbetti a1ff9aab21 Do not iterate over the whole buffer, but only on the effectively used part.
This should fix the "data in the future" issue
2015-06-04 18:56:35 +02:00
Daniele Gobbetti 406f9ab90d Do not allocate the buffer if there's no data available.
Perhaps could fix the "data in the future" issue
2015-06-02 18:33:12 +02:00
Daniele Gobbettiandcpfeiffer 9e2d32c33f Fixed timestamp conversion for DB, added local variables to make the code clearer 2015-06-01 22:20:28 +02:00
Daniele Gobbettiandcpfeiffer ea97a902d1 *unchecked* Storing activity values in the DB. 2015-06-01 22:20:28 +02:00
Daniele Gobbettiandcpfeiffer 8b268a676c Refactoring of the data ingestion method.
* no more ByteBuffer, but a fixed size byte array that gets flushed everytime it's needed
* log of activity data to a separate file (no DB integration yet)
* the size of the buffer must be a multiple of 3 (1 minute of data = 3 bytes) and 20 (the normal size of the chunks we get from the device)
* better logging and more comments in code
2015-06-01 22:20:22 +02:00
Daniele Gobbettiandcpfeiffer 228e922ce7 forgotten refactor of a variable 2015-06-01 21:47:01 +02:00
Daniele Gobbettiandcpfeiffer e4076dc725 Ingesting the activity data the right way, but they are still being thrown away afterwards. 2015-06-01 21:47:01 +02:00
Daniele Gobbetti 7e2545f9b4 Use constants instead of hardcoded values 2015-05-21 18:19:07 +02:00
Daniele Gobbetti 98696ce9e2 Implement setting the time on the miband.
It works from the debug activity, since I am not sure about the value of
the ts argument, it always sets the current time.
2015-04-23 14:11:57 +02:00