
My ELEC2645 Project Zhou Jingyuan 200986046
Dependencies: ZhouJingyuan mbed
main.h
- Committer:
- Iverson66
- Date:
- 2016-05-05
- Revision:
- 0:c5868f162227
File content as of revision 0:c5868f162227:
#ifndef MAIN_H #define MAIN_H #include "mbed.h" #include "N5110.h" #include <stdlib.h> //headfile for the random value #include <time.h> #define DIRECTION_TOLERANCE 0.05 // change this to alter tolerance of joystick direction // function prototypes void calibrateJoystick(); // the function about read default positions of the joystick to calibrate later readings void updateJoystick(); //the function to recognize the direction of the joystick void illustration(); //the explication of the game void moving (); //moving for the practice void moving2 (); //moving for the second challenge int setpointx (int); //get x value of the ball int setpointy (int); //get y value of the ball //global constant in the function int printFlag = 0; //to refresh the ticker function int x = 55; // initial x value of people int y = 23; // initial y value of people int q=50; //the initial constant for the second part game int r=0; //to break the while(1) loop #endif