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: QEI accelerator bit_test cyclic_io cyclic_var cylinder event_var limit mbed mecanum motor_drive pid pid_encoder rs422_put sbdbt servo
Fork of 17robo_Practice1 by
headerfile_unuse/cyclic_.h@66:1664ee92539d, 2017-09-24 (annotated)
- Committer:
 - echo_piyo
 - Date:
 - Sun Sep 24 05:25:03 2017 +0000
 - Revision:
 - 66:1664ee92539d
 - Parent:
 - cyclic.h@32:f535ace7c529
 
????2??
Who changed what in which revision?
| User | Revision | Line number | New contents of line | 
|---|---|---|---|
| echo_piyo | 14:aac2f18f6779 | 1 | class Cyclic | 
| echo_piyo | 14:aac2f18f6779 | 2 | { | 
| echo_piyo | 14:aac2f18f6779 | 3 | public: | 
| echo_piyo | 14:aac2f18f6779 | 4 | void cyclic(int state_in) | 
| echo_piyo | 14:aac2f18f6779 | 5 | { | 
| echo_piyo | 14:aac2f18f6779 | 6 | if(state_in) | 
| echo_piyo | 14:aac2f18f6779 | 7 | { | 
| echo_piyo | 14:aac2f18f6779 | 8 | if(flag == false) | 
| echo_piyo | 14:aac2f18f6779 | 9 | { | 
| echo_piyo | 32:f535ace7c529 | 10 | state = !state; | 
| echo_piyo | 14:aac2f18f6779 | 11 | } | 
| echo_piyo | 14:aac2f18f6779 | 12 | flag = true; | 
| echo_piyo | 14:aac2f18f6779 | 13 | } | 
| echo_piyo | 14:aac2f18f6779 | 14 | else flag = false; | 
| echo_piyo | 14:aac2f18f6779 | 15 | } | 
| echo_piyo | 14:aac2f18f6779 | 16 | |
| echo_piyo | 14:aac2f18f6779 | 17 | int getState() | 
| echo_piyo | 14:aac2f18f6779 | 18 | { | 
| echo_piyo | 14:aac2f18f6779 | 19 | return state; | 
| echo_piyo | 14:aac2f18f6779 | 20 | } | 
| echo_piyo | 14:aac2f18f6779 | 21 | |
| echo_piyo | 14:aac2f18f6779 | 22 | private: | 
| echo_piyo | 14:aac2f18f6779 | 23 | bool flag; | 
| echo_piyo | 14:aac2f18f6779 | 24 | bool state; | 
| echo_piyo | 14:aac2f18f6779 | 25 | }; | 
