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: StrLib myTimer RingBuffer
Revision 5:63925964cbd5, committed 2015-11-20
- Comitter:
- AkinoriHashimoto
- Date:
- Fri Nov 20 07:15:40 2015 +0000
- Parent:
- 4:8b74db22e4c6
- Commit message:
- add reboot().
Changed in this revision
--- a/RN41.cpp Mon Nov 16 04:11:50 2015 +0000
+++ b/RN41.cpp Fri Nov 20 07:15:40 2015 +0000
@@ -158,6 +158,17 @@
return NG;
}
+bool RN41::reboot()
+{
+ if(!enterCMD())
+ return ; // CMD入れず
+ sendCMD("R,1");
+
+// bool2 find= chkReply("Reboot!\r", 100);
+
+ return chkReply("Reboot!\r", 100).b1;
+}
+
void RN41::sendCMD(string str, bool addCR)
{
--- a/RN41.h Mon Nov 16 04:11:50 2015 +0000
+++ b/RN41.h Fri Nov 20 07:15:40 2015 +0000
@@ -102,6 +102,7 @@
bool enterCMD();
int connect(string addr); // 必ず、Checkを呼ぶこと。2-5sかかるよ
bool disconnect();
+ bool reboot();
private:
RawSerial rn41;
--- a/myTimer.lib Mon Nov 16 04:11:50 2015 +0000 +++ b/myTimer.lib Fri Nov 20 07:15:40 2015 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/users/AkinoriHashimoto/code/myTimer/#de4737751df6 +http://mbed.org/users/AkinoriHashimoto/code/myTimer/#2f7a8e62597a