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 0:049b3f6beb94, committed 2017-05-11
- Comitter:
- namazunlv100
- Date:
- Thu May 11 08:12:00 2017 +0000
- Commit message:
- testMock
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
mbed.bld | Show annotated file Show diff for this revision Revisions of this file |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Thu May 11 08:12:00 2017 +0000 @@ -0,0 +1,33 @@ +#include "mbed.h" + /*Fセンサ完成後*/ +AnalogIn lisensa1(PTB0); +AnalogIn lisensa2(PTB2); +AnalogIn trsensa1(PTB1); +AnalogIn trsensa2(PTB3); +DigitalIn ftrsensa1(PTE21); +DigitalIn ftrsensa2(PTE23); /*Analogにする時pinを変える必要あり 右下PTC2 Digitalの時にはPTE23*/ +BusOut moter1(PTA1,PTA2); +PwmOut power1(PTD4); /*上限0.001,下限0.0005*/ +BusOut moter2(PTC0,PTC7); +PwmOut power2(PTA12); +BusOut moter3(PTC6,PTC5); +PwmOut power3(PTA4); +DigitalOut myled1(PTB8); +DigitalOut myled2(PTB10); +DigitalOut myled3(PTB9); +DigitalOut myled4(PTB11); +DigitalOut myled5(PTE2); + +int main() { + while(1) { + myled2 = 0; + myled5 = 0; + if(trsensa1 > 0.05){ + myled2 = 1; + } + if(trsensa2 > 0.03){ + myled5 = 1; + } + } +} + \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Thu May 11 08:12:00 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/9bcdf88f62b0 \ No newline at end of file