a

Dependencies:   Locate Move Servo button mbed

Fork of 3rdcompfixstart by 涼太郎 中村

main.cpp

Committer:
sakanakuuun
Date:
2016-09-07
Revision:
9:94aa6a12b730
Parent:
8:21f40f92215f
Child:
10:118d86939032

File content as of revision 9:94aa6a12b730:

#include "mbed.h"
#include "math.h"
#include "locate.h"
#include "move.h"

DigitalIn start(USER_BUTTON);
DigitalOut buzzer(PB_10);

int main()
{
    setup();
    initmotor();
    
    buzzer = 0;
    while(start);
    buzzer = 1;
    wait_us(1);
    while(!start);
    while(start);
    buzzer = 0;
    
    while(1)
    {
        back300();
        pmove(300,300);
        pmove(0,300);
        pmove(0,0);
    }
    while(1) {
        update();
    }
    
}