ELEC2645 (2017/18) / Mbed 2 deprecated el17yw

Dependencies:   mbed

Committer:
RickYu
Date:
Sat May 05 20:27:06 2018 +0000
Revision:
30:057301068dac
Parent:
27:eab2cf10554e
fix the bug in the menu

Who changed what in which revision?

UserRevisionLine numberNew contents of line
RickYu 20:a3fd428fb4f4 1 #ifndef HELP_H
RickYu 19:362ad1cd6d4a 2 #define HELP_H
RickYu 19:362ad1cd6d4a 3 #include "mbed.h"
RickYu 19:362ad1cd6d4a 4 #include "N5110.h"
RickYu 19:362ad1cd6d4a 5 #include "Gamepad.h"
RickYu 19:362ad1cd6d4a 6
RickYu 19:362ad1cd6d4a 7
RickYu 19:362ad1cd6d4a 8 class help{
RickYu 19:362ad1cd6d4a 9
RickYu 19:362ad1cd6d4a 10 public:
RickYu 19:362ad1cd6d4a 11 help();
RickYu 19:362ad1cd6d4a 12 ~help();
RickYu 26:6a1476a0bba9 13
RickYu 26:6a1476a0bba9 14 void draw_arrow(N5110 &lcd);
RickYu 26:6a1476a0bba9 15 void update(Gamepad &pad,N5110 &lcd); //switch between "game" and "help"
RickYu 19:362ad1cd6d4a 16
RickYu 26:6a1476a0bba9 17 //move the page in "help" model
RickYu 26:6a1476a0bba9 18 void page_on(Gamepad &pad,N5110 &lcd);
RickYu 26:6a1476a0bba9 19 void page_back(Gamepad &pad,N5110 &lcd);
RickYu 30:057301068dac 20 void prevent_page(Gamepad &pad,N5110 &lcd);
RickYu 26:6a1476a0bba9 21
RickYu 26:6a1476a0bba9 22 //draw two models
RickYu 26:6a1476a0bba9 23 void model_1(Gamepad &pad,N5110 &lcd);
RickYu 26:6a1476a0bba9 24 void model_2(Gamepad &pad,N5110 &lcd);
RickYu 26:6a1476a0bba9 25
RickYu 26:6a1476a0bba9 26 //write the help and introduction
RickYu 21:f48e269bafa4 27 void statement1(N5110 &lcd);
RickYu 21:f48e269bafa4 28 void statement2(N5110 &lcd);
RickYu 21:f48e269bafa4 29 void statement3(N5110 &lcd);
RickYu 30:057301068dac 30
RickYu 21:f48e269bafa4 31
RickYu 26:6a1476a0bba9 32
RickYu 19:362ad1cd6d4a 33 private:
RickYu 19:362ad1cd6d4a 34
RickYu 19:362ad1cd6d4a 35 int arrow_x;
RickYu 19:362ad1cd6d4a 36 int arrow_y;
RickYu 20:a3fd428fb4f4 37 int arrow_speed;
RickYu 22:c1e1283c6356 38 int choice;
RickYu 22:c1e1283c6356 39 int page;
RickYu 26:6a1476a0bba9 40 };
RickYu 26:6a1476a0bba9 41 #endif