Skip to content

Commit 4618c1b

Browse files
authored
chore: Update note-c dependency (#140)
* chore: Improve version docs, bump version * Remove `note-c` before re-add * Squashed 'src/note-c/' content from commit c35ba60 - git-subtree-dir: src/note-c - git-subtree-split: c35ba60e1a31488ca227e051d617fdefe18e1351 * Remove unneeded directories from `note-c`
1 parent 9fc7e1a commit 4618c1b

11 files changed

+268
-135
lines changed

README.md

+21-20
Original file line numberDiff line numberDiff line change
@@ -85,21 +85,6 @@ if (rsp != NULL) {
8585
}
8686
```
8787

88-
## Keeping up to date with note-c repo
89-
90-
This library depends on the Blues [`note-c` library][note-c]. To update this
91-
repo with the latest from `note-c`, run the `update_note_c.sh` shell script
92-
from the `scripts/` folder:
93-
94-
```none
95-
scripts/update_note_c.sh
96-
```
97-
98-
_**NOTE:** It is important to use the script. It utilizes git subtrees to
99-
include the appropriate files in the `src/note-c` folder. It also eliminates
100-
folders that necessary for testing `note-c` individually, but interfere with
101-
the Arduino build environment._
102-
10388
## Documentation
10489

10590
The documentation for this library can be found
@@ -260,7 +245,22 @@ at the end of the array, and syntax should be as follows,
260245

261246
## Generating a Release
262247

263-
### Update Files
248+
### Update `note-c` dependency
249+
250+
This library depends on the Blues [`note-c` library][note-c]. To update this
251+
repo with the latest from `note-c`, run the `update_note_c.sh` shell script
252+
from the `scripts/` folder:
253+
254+
```none
255+
scripts/update_note_c.sh
256+
```
257+
258+
_**NOTE:** It is important to use the script. It utilizes git subtrees to
259+
include the appropriate files in the `src/note-c` folder. It also eliminates
260+
folders that necessary for testing `note-c` individually, but interfere with
261+
the Arduino build environment._
262+
263+
### Update Version Files
264264

265265
When generating a release of the `note-arduino` library, you will need to update
266266
the version in two places.
@@ -281,12 +281,13 @@ the version in two places.
281281
version string should follow the form "\<major\>.\<minor\>.\<patch\>" (e.g.
282282
`1.6.4`). This value will be used by the Arduino Library Manager.
283283

284-
### GitHub Release
284+
### Arduino Library Manager Release
285285

286286
Publishing a release on GitHub will trigger the Arduino Library Manager. The
287-
Arduino Library Manager will then look to the `library.properties` file, and
288-
generate a release based on the `version` value it finds there. It should be
289-
noted, the version on GitHub is not evaluated by the Arduino Library Manager.
287+
Arduino Library Manager will look to the `library.properties` file, and generate
288+
a release based solely on the `version` value it finds there.
289+
290+
_**NOTE:** The GitHub version is not evaluated by the Arduino Library Manager._
290291

291292
## More Information
292293

library.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=Blues Wireless Notecard
2-
version=1.6.5
2+
version=1.6.6
33
author=Blues
44
maintainer=Blues <[email protected]>
55
sentence=An easy to use Notecard Library for Arduino.

src/NoteDefines.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// Define the version of the `note-arduino` library
55
#define NOTE_ARDUINO_VERSION_MAJOR 1
66
#define NOTE_ARDUINO_VERSION_MINOR 6
7-
#define NOTE_ARDUINO_VERSION_PATCH 5
7+
#define NOTE_ARDUINO_VERSION_PATCH 6
88

99
#define NOTE_ARDUINO_VERSION NOTE_C_STRINGIZE(NOTE_ARDUINO_VERSION_MAJOR) "." NOTE_C_STRINGIZE(NOTE_ARDUINO_VERSION_MINOR) "." NOTE_C_STRINGIZE(NOTE_ARDUINO_VERSION_PATCH)
1010

src/note-c/n_helpers.c

+8-2
Original file line numberDiff line numberDiff line change
@@ -529,8 +529,14 @@ const char * NoteBinaryStoreTransmit(uint8_t *unencodedData, uint32_t unencodedL
529529
return err;
530530
}
531531

532-
// Issue a "card.binary" request.
533-
J *rsp = NoteRequestResponse(NoteNewRequest("card.binary"));
532+
// Issue a "card.binary" request. The length is reset if this is the
533+
// first segment, clearing out any error that might potentially be
534+
// pending from a previous use of the binary store.
535+
J *req = NoteNewRequest("card.binary");
536+
if (notecardOffset == 0) {
537+
JAddBoolToObject(req, "reset", true);
538+
}
539+
J *rsp = NoteRequestResponse(req);
534540
if (!rsp) {
535541
const char *err = ERRSTR("unable to issue binary request", c_err);
536542
NOTE_C_LOG_ERROR(err);

0 commit comments

Comments
 (0)