
障害物回避走行プログラム
Revision 2:3a891c8d5b82, committed 2020-07-22
- Comitter:
- tomotsugu
- Date:
- Wed Jul 22 03:23:50 2020 +0000
- Parent:
- 1:9787fdc9b191
- Child:
- 3:85fb510925f5
- Commit message:
- avoidance
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed Jul 22 03:14:33 2020 +0000 +++ b/main.cpp Wed Jul 22 03:23:50 2020 +0000 @@ -86,6 +86,7 @@ /* 障害物回避走行 */ void avoidance(){ + Thread ws_thread(watchsurrounding); // watchsurroundingをスレッド化 while(1){ if(flag == 0){ // 障害物がない場合 run = ADVANCE; // 前進 @@ -164,6 +165,6 @@ } } flag = 0; // フラグを0にセット - Thread::signal_set(0x1); // watchsurroundingのシグナルをセット + ws_thread.signal_set(0x1); // watchsurroundingのシグナルをセット } } \ No newline at end of file