Skip to content

Commit a80a5c9

Browse files
fix arduino scouting example
1 parent a9c16b8 commit a80a5c9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/arduino/z_scout.ino

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ void fprintzid(z_id_t zid) {
4747
void fprintwhatami(z_whatami_t whatami) {
4848
z_view_string_t s;
4949
z_whatami_to_view_string(whatami, &s);
50-
Serial.write(z_string_data(z_loan(s)), z_string_len(z_loan(s)));
50+
Serial.write(z_string_data(z_view_string_loan(&s)), z_string_len(z_view_string_loan(&s)));
5151
}
5252

5353
void fprintlocators(const z_loaned_string_array_t *locs) {
@@ -71,7 +71,7 @@ void fprinthello(const z_loaned_hello_t *hello) {
7171
Serial.print(", whatami: ");
7272
fprintwhatami(z_hello_whatami(hello));
7373
Serial.print(", locators: ");
74-
fprintlocators(z_hello_locators(z_loan(hello)));
74+
fprintlocators(z_hello_locators(hello));
7575
Serial.println(" }");
7676
}
7777

0 commit comments

Comments
 (0)