ECE2035 Project 2

Dependencies:   mbed mbed-rtos SDFileSystem

Committer:
kwengryn3
Date:
Tue Apr 20 18:15:22 2021 +0000
Revision:
10:1994adcfc86f
Parent:
7:95db0d89fbac
adv features

Who changed what in which revision?

UserRevisionLine numberNew contents of line
kwengryn3 0:bff8b9020128 1 //=================================================================
kwengryn3 0:bff8b9020128 2 // The header file defining the fruit module
kwengryn3 0:bff8b9020128 3 //
kwengryn3 0:bff8b9020128 4 // Copyright 2020 Georgia Tech. All rights reserved.
kwengryn3 0:bff8b9020128 5 // The materials provided by the instructor in this course are for
kwengryn3 0:bff8b9020128 6 // the use of the students currently enrolled in the course.
kwengryn3 0:bff8b9020128 7 // Copyrighted course materials may not be further disseminated.
kwengryn3 0:bff8b9020128 8 // This file must not be made publicly available anywhere.
kwengryn3 0:bff8b9020128 9 //==================================================================
kwengryn3 0:bff8b9020128 10 #ifndef FRUIT_PRIVATE_H
kwengryn3 0:bff8b9020128 11 #define FRUIT_PRIVATE_H
kwengryn3 0:bff8b9020128 12
kwengryn3 0:bff8b9020128 13 #include "mbed.h"
kwengryn3 0:bff8b9020128 14 #include "globals.h"
kwengryn3 0:bff8b9020128 15 #include "fruit_public.h"
kwengryn3 0:bff8b9020128 16
kwengryn3 0:bff8b9020128 17 //==== [private settings] ====
kwengryn3 7:95db0d89fbac 18 const int FRUIT_INTERVAL = 30;
kwengryn3 4:8e15742ebcc6 19 const int FRUIT_SPEED = 2;
kwengryn3 4:8e15742ebcc6 20 const int FRUIT_SIZE = 10;
kwengryn3 4:8e15742ebcc6 21 const int PLAYER_SPACE = 20;
kwengryn3 0:bff8b9020128 22
kwengryn3 0:bff8b9020128 23 //==== [private type] ====
kwengryn3 0:bff8b9020128 24
kwengryn3 0:bff8b9020128 25 //==== [private function] ====
kwengryn3 0:bff8b9020128 26 /** Generate a random fruit and add it to the fruit DLL
kwengryn3 0:bff8b9020128 27 */
kwengryn3 0:bff8b9020128 28 void fruit_create(void);
kwengryn3 0:bff8b9020128 29 /** Iterate over all fruit and update their positions using the rate of motion
kwengryn3 0:bff8b9020128 30 * and the deltaX and deltaY generated by fruit create
kwengryn3 0:bff8b9020128 31 */
kwengryn3 0:bff8b9020128 32 void fruit_update_position(void);
kwengryn3 0:bff8b9020128 33
kwengryn3 0:bff8b9020128 34 #endif //FRUIT_PRIVATE_H
kwengryn3 0:bff8b9020128 35
kwengryn3 0:bff8b9020128 36