Skip to content

Commit

Permalink
Merge pull request #20 from ARMmbed/f/serial-write-send-length
Browse files Browse the repository at this point in the history
Send information about data size in serial write
  • Loading branch information
thegecko authored May 25, 2018
2 parents 7e8399a + 30f29a9 commit c7e16b3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/serial/serial.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ export class Serial {
let arrayData = [];
if (data || data !== "") {
arrayData = data.split("").map((e: any) => e.charCodeAt());
arrayData.unshift(arrayData.length);
}
return await this.dap.writeSerial(arrayData);
}
Expand Down

0 comments on commit c7e16b3

Please sign in to comment.