Commit Graph

248 Commits

Author SHA1 Message Date
Aleksander Nowakowski 05e9a90ed0 Comments improved 2018-10-17 17:41:50 +02:00
Aleksander Nowakowski cf86be8e11 Send App when SD+BL failed in Secure DFU 2018-10-17 17:41:18 +02:00
Aleksander Nowakowski 9031c32cf6
Passing current MTU value to service (#135)
* Passing MTU to service (#134)

* Comments formatting
2018-10-17 14:49:02 +02:00
Aleksander Nowakowski c9f6bfc113
Merge pull request #113 from andilee111/release
Typo in the errors
2018-10-16 15:46:29 +02:00
Aleksander Nowakowski 31bf36350a #129 fixed: improved characteristic validation 2018-10-16 15:44:39 +02:00
Aleksander Nowakowski 92fd8d647c Suppressing warnings 2018-10-01 14:06:06 +02:00
Aleksander Nowakowski ba73c443c3 Android Studio 3.2.0 + other dependencies 2018-10-01 13:41:56 +02:00
Aleksander Nowakowski b62e6d8ece 3 HCI errors added 2018-10-01 13:41:55 +02:00
Jakub Hrabec baea766d5e
fix upload not aborted on service destroy 2018-09-26 14:38:27 +08:00
Andrej Wallwitz 525dc546b7 Typo in the errors 2018-07-03 17:31:53 +02:00
Aleksander Nowakowski 0b907aaf06 Version 1.7.0 2018-07-03 15:25:27 +02:00
Aleksander Nowakowski 3cffd16087 Licenses reformatted 2018-07-03 15:03:02 +02:00
Aleksander Nowakowski ab9d77c14f Line wrapping and annotations 2018-07-03 15:01:01 +02:00
Aleksander Nowakowski 3a004647ca Fix for #111
The new API allows you to control the MTU from the initiator.
2018-07-03 14:45:08 +02:00
Aleksander Nowakowski 9bd1ecca62 Printing PHY updates 2018-07-03 14:13:40 +02:00
Aleksander Nowakowski 9092b3be9b #112 fixed
SC CCCD are always checked and enabled on bonded devices
2018-07-03 14:13:08 +02:00
Aleksander Nowakowski 74a71d6992 compile -> implementation 2018-04-06 10:55:56 +02:00
Aleksander Nowakowski b164e4321e Android Studion 3.0.1 2017-12-19 10:51:09 +01:00
Aleksander Nowakowski 0094b4b040 Locales in String.format(...) 2017-12-06 16:18:04 +01:00
Aleksander Nowakowski 7c68625ebf Version 1.6.1 2017-11-30 15:50:59 +01:00
Aleksander Nowakowski 538ff6c3ea Javadoc comment fix 2017-11-30 15:50:10 +01:00
Aleksander Nowakowski 8b3b09f536 #89 fixed 2017-11-30 15:38:17 +01:00
Aleksander Nowakowski 1f5b13e89c Version 1.6.0 2017-11-17 17:46:21 +01:00
Aleksander Nowakowski 350fdbbfc6 #86 fixed 2017-11-17 17:36:36 +01:00
Aleksander Nowakowski 8a5530bf33 Android API 27 2017-11-17 15:51:04 +01:00
Aleksander Nowakowski c8abe84a82 Logging improved 2017-11-17 15:50:46 +01:00
Aleksander Nowakowski 2a3eac37c5 #88 fixed
+ ArchiveInputStream can be reused with different content types
+ Reusing input stream between service runs
2017-11-17 15:50:25 +01:00
Aleksander Nowakowski 90c7694b94 #87 fixed
+ foreground mode is now optional (and enabled by default)
+ fixed crashing when getNotification() returns null and notifications
are disabled
+ improved logging
+ minor: formatting improved
2017-11-16 16:02:56 +01:00
Aleksander Nowakowski 5d08a0df93 Logging improved
+ some common errors are now logged in a better way
2017-11-16 15:59:22 +01:00
Aleksander Nowakowski 9de06d0c11 HCI_ERR_UNACCEPT_CONN_INTERVAL error added 2017-11-16 15:30:48 +01:00
Aleksander Nowakowski 8e97e92995 Version 1.5.2 2017-11-03 17:22:41 +01:00
Aleksander Nowakowski 8bdbe03879 Bugfix: setting scope was impossible due to invalid check 2017-11-03 17:22:30 +01:00
Aleksander Nowakowski 2c994b36cd Version 1.5.1 2017-10-23 10:40:01 +02:00
Aleksander Nowakowski 2476baf5ce Deprecations removed 2017-10-23 10:33:40 +02:00
Aleksander Nowakowski 825b23e8e2 Fixing #78 2017-10-20 17:16:58 +02:00
Aleksander Nowakowski 61c7c45335 Validating CRC in PRNs 2017-10-20 17:07:39 +02:00
Aleksander Nowakowski ff73f661eb Bug fixed: #77 2017-10-19 15:46:46 +02:00
Aleksander Nowakowski a3ae736357 Version 1.5.0 2017-10-06 18:00:02 +02:00
Aleksander Nowakowski abcb2baaf3 Target API changed to 26, notification channels added
DFU Library is now ready for Android Oreo. The Dfu Service starts as
foreground service. It also uses notification channel with low priority.
2017-10-06 17:45:26 +02:00
Aleksander Nowakowski 561e1f2372 Bug fix: Passing correct extended error number and message 2017-10-06 17:24:51 +02:00
Aleksander Nowakowski cf1da0ff6b Bug fix: Passing correct extended error number and message
Before, the Extended Error code (11|REMOTE_MASK) was sent instead, and
the message was UNKNOWN. Now the errorCode will contain the extended
error code and message will already contain the reason of an error.
2017-10-06 17:21:43 +02:00
Colin Madere 42a8e3ed27 Fix lingering "Disconnecting" notification
- Notifications weren't being updated if they came within 250ms of the previous update, regardless of end-state being reached
- Added check that if the progress was at an end-state, upate anyway
2017-09-28 16:05:03 -07:00
Aleksander Nowakowski bf3b7b60d2 Version 1.4.2 2017-09-14 15:23:53 +02:00
Aleksander Nowakowski 66411741a9 InitPacketData not required and removed 2017-09-14 14:05:36 +02:00
Michal Skrabacz fa00bd0916 Change InitPacketData.applicationVersion from Long to String
There is no need to limit this to long value. Most cases users will use sth more eye friendy like 0.7.4 instead of 4576
2017-09-14 10:40:34 +02:00
Aleksander Nowakowski 24c2bb4500 Version 1.4.1 2017-09-13 15:54:16 +02:00
Aleksander Nowakowski 3dace8136c Minor fixes 2017-09-13 15:50:33 +02:00
Aleksander Nowakowski 4a466b25bd Adding setScope() method to the initiator 2017-09-13 15:50:18 +02:00
Aleksander Nowakowski be08427fe1 Version 1.4.0 2017-08-31 16:41:37 +02:00
Aleksander Nowakowski b7d123b4a5 Bug hopefully fixed: #55 2017-08-31 16:17:00 +02:00
Aleksander Nowakowski a41ff7536d Adding support for higher MTU in Secure DFU 2017-08-31 15:59:55 +02:00
Aleksander Nowakowski a8c8eee34f Version 1.3.1 2017-07-28 16:10:03 +02:00
Aleksander Nowakowski e7db4da822 Build tools 25.0.3, Android Studio 2.3.3 2017-07-28 14:34:36 +02:00
Aleksander Nowakowski 265a62c13a Tiny code cleanup 2017-07-28 14:11:50 +02:00
Aleksander Nowakowski edb543c331 Fixing issue #61, part 3: Resuming sending incomplete object 2017-07-03 15:03:55 +02:00
Aleksander Nowakowski 06b5e6d42d Fixing issue #61, part 2: Improved debug logging 2017-07-03 11:38:23 +02:00
Aleksander Nowakowski a726cc55ee Fixing issue #61, part 1: Printing correct Init packet size 2017-06-30 13:35:21 +02:00
Aleksander Nowakowski c2e0e5fec9 Issue #56 fixed 2017-06-28 17:33:37 +02:00
Aleksander Nowakowski 7ee2dc1005 Version 1.3.0 released 2017-04-07 14:36:13 +02:00
Aleksander Nowakowski 99f636e715 Better support for DFU from SDK 6 or older 2017-04-06 16:22:31 +02:00
Aleksander Nowakowski 313c963794 Logging ACL_DISCONNECTED event 2017-04-06 16:22:06 +02:00
Aleksander Nowakowski b346d269f3 Support for buttonless DFU service from SDK 13 added.
Library prepared for buttonless DFU with bond sharing (coming next SDK or later).
Refactoring: legacy buttonless DFU extracted to own class.
2017-03-27 10:09:53 +02:00
Aleksander Nowakowski 4642ad4ae3 Enhancement: Option to set custom UUIDs (#48) 2017-03-21 16:49:47 +01:00
Aleksander Nowakowski d5f487ed56 Issue #51 fixed: restarting legacy bootloader on Invalid State 2017-03-21 14:43:02 +01:00
Aleksander Nowakowski 113c312985 Removing unnecessary disconnect after enabling Service Changed CCCD.
In Legacy DFU the bond information is passed to the bootloader in RAM, not in flash, so saving it is not required.
2017-03-21 11:21:30 +01:00
Aleksander Nowakowski 1c18dd8c2e Fixing issue #45 2017-03-15 16:56:29 +01:00
Aleksander Nowakowski 98bed1ab90 Issue #49 fixed: updating SD no longer forces the bond info on the phone to be removed 2017-03-15 15:35:01 +01:00
Aleksander Nowakowski 87fd7e903a Version 1.2.0: CRC bugs fixed, other combinations of fw in ZIP allowed in Secure DFU 2017-02-22 17:29:34 +01:00
Aleksander Nowakowski 40a8f0f634 Bug fix: Fixed calculating CRC for unaligned files 2017-02-21 12:27:39 +01:00
Aleksander Nowakowski b2c5af0b70 Added support for other combinations of fw components 2017-02-21 10:33:26 +01:00
Dan Walkes 671ef3f000 Clean up log messages, match code convention
Use single space after commas and between assignments.
2017-02-04 18:24:56 -07:00
Dan Walkes 18bdda9a37 Mark position after execute for CRC retry
I've noticed when using in a noisy environment if I ever see a CRC error
all of the subsequent retries fail and the download fails.

I noticed if I print the CRC values expected they change on each retry
attempt.  This seems wrong, since I believe the intent is just to re-send
the last chunk.

I suspect there's a mark() call missing in the success transfer case,
and the position of the last successful create->execute transfer should
be saved. The next retry transfer should only reset to this mark position
and not the beginning of the file.

If I add a call to mFirwmareStream.mark in the CRC success case after
writeExecute() completes I am able to successfully recover from CRC errors.
2017-02-02 22:34:00 -07:00
Aleksander Nowakowski 136c7bb2d4 Version 1.1.1: #31 fixed 2016-12-02 11:26:33 +01:00
Aleksander Nowakowski 9dc01000da Bug fixed: experimental buttonless support fixed 2016-12-02 11:18:56 +01:00
Aleksander Nowakowski 4b939854ff Styling: log message fixed 2016-12-02 11:18:08 +01:00
Aleksander Nowakowski 42ce628ac6 Version 1.1.0 released 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 4f320b6f89 Minor bug fix: logging init packet size 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 74debc5c16 Minor: Access modifiers for log methods changed 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 2ad3ea1941 Comment updated 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 770b5bb8c3 Support for experimental Buttonless Secure DFU 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 583a59eacd Code and docs clean up 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski d342af8089 Stopping service when task removed from recents (task killed) 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski dbf687d65b Support for extended errors added 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 7ee6b3258a Support for extended errors added 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 300dadf124 Build tools 25.0.1 2016-11-29 11:23:00 +01:00
Aleksander Nowakowski 08e2cb3896 Version 1.0.4 2016-09-26 16:14:46 +02:00
Aleksander Nowakowski c620ae46c8 Setting PRN and ForceDfu from DfuServiceInitiator 2016-09-26 16:13:27 +02:00
Aleksander Nowakowski 3ce9866787 Bug fixed: Reading the content file correctly if no sd_size and bl_size given (Secure DFU) 2016-09-26 12:50:19 +02:00
Aleksander Nowakowski 6498f72107 DFU Library version 1.0.3 2016-09-23 12:53:56 +02:00
Aleksander Nowakowski 6b8c18ace4 Comment fixed 2016-09-23 12:49:15 +02:00
Aleksander Nowakowski 750ea15bf4 Logging fixed: enable or disable LogCat logging from your DfuService class 2016-09-23 11:22:03 +02:00
Aleksander Nowakowski 3f00657408 Aborting DFU improved:
- waiting until a prev gatt operation completes before sending Reset cmd,
- checking if aborted before operation, not after,
- resetting legacy dfu target on abort to revert it to app mode
2016-09-23 11:03:30 +02:00
Aleksander Nowakowski d7fe722fbf Bug fixed: Skipping connecting if DFU aborted before 2016-09-23 10:55:13 +02:00
Aleksander Nowakowski e6ce2550b8 Logging user actions 2016-09-23 10:53:49 +02:00
Aleksander Nowakowski 3f93ce44d5 Version 1.0.2 2016-09-21 16:36:17 +02:00
Aleksander Nowakowski 624b5e29c8 DfuServiceController added 2016-09-21 16:26:15 +02:00
Aleksander Nowakowski 792c751f65 Bug fixed: Sending PROGRESS_ABORTED fixed 2016-09-21 16:25:48 +02:00
Aleksander Nowakowski 15c7152f94 Typo fixed. Access modifiers changed 2016-09-21 16:25:14 +02:00
Aleksander Nowakowski d7fb268290 Access modifier of DEBUG changed to package 2016-09-15 13:19:58 +02:00
Aleksander Nowakowski 120f3ee147 Version 1.0.1 2016-09-15 13:02:58 +02:00