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.
Revision 2:4090898287d5, committed 2016-03-07
- Comitter:
- yangcq88517
- Date:
- Mon Mar 07 14:45:16 2016 +0000
- Parent:
- 1:58ab657cd515
- Commit message:
- update document
Changed in this revision
| SP03.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/SP03.h Mon Mar 07 14:38:55 2016 +0000
+++ b/SP03.h Mon Mar 07 14:45:16 2016 +0000
@@ -2,7 +2,31 @@
#define Smartlab_Drive_SP03
#include "mbed.h"
-
+/**
+* Example:
+* @code
+* #include "mbed.h"
+* #include "SP03.h"
+*
+* DigitalOut myled(LED1);
+* SP03 sp03(p28, p27);
+*
+* int main()
+* {
+* sp03.setSpeed(SP03::SPEED_NORMAL);
+*
+* sp03.setVolume(SP03::VOLUME_MAX);
+*
+* while(1) {
+* if (!sp03.isSpeaking()) {
+* myled = 1;
+* sp03.speak("Hello CQ 1 2 2 3 4 6 76 7 9 9 08 8");
+* } else
+* myled = 0;
+* }
+* }
+* @endcode
+*/
class SP03
{
private: