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.
Diff: bluetoothFunc.h
- Revision:
- 0:912c221cc186
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/bluetoothFunc.h Sat Apr 28 22:07:24 2018 +0000 @@ -0,0 +1,18 @@ +bool bluetoothFunc(int& num, int& upOrDown){ + char bnum = blue.getc(); + bool dataValid = false; + if (bnum =='!') { + bnum = blue.getc(); + if (bnum == 'B') { + bnum = blue.getc(); + num = bnum - '0'; + upOrDown = blue.getc() - '0'; + dataValid = true; + } + } + if(dataValid){ + return true; + } else { + return false; + } +} \ No newline at end of file