Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: SensoryTest
Fork of btbee by
Revision 4:3cdbefbd2409, committed 2014-02-05
- Comitter:
- ngoldin
- Date:
- Wed Feb 05 11:18:48 2014 +0000
- Parent:
- 3:ddeb620fb25e
- Child:
- 5:2e759cc06191
- Commit message:
- fixed read_line. hopefully.
Changed in this revision
| btbee.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/btbee.cpp Wed Feb 05 10:32:04 2014 +0000
+++ b/btbee.cpp Wed Feb 05 11:18:48 2014 +0000
@@ -60,12 +60,12 @@
int pos=0;
do
{
- while(!readable()){}
- if (pos==len){return 0;}
+ while(!readable()){} //wait until readable
+ if (pos==len){return 0;}
arr[pos]=getc();
pos++;
*chars_read = pos;
}
-while (!(arr[pos]=='\n'));
+while (!(arr[pos-1]=='\n'));
return 1;
}
