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.
Dependencies: mbed FATFileSystem
Menu/Menu.h
- Committer:
- ellisbhastroud
- Date:
- 2019-03-20
- Revision:
- 2:81cfa8310f55
- Parent:
- 1:6179c2d67d19
- Child:
- 3:a8960004d261
File content as of revision 2:81cfa8310f55:
#ifndef MENU_H
#define MENU_H
#include "mbed.h"
#include "N5110.h"
#include "Gamepad.h"
/** Enum for menu options */
enum MenuChoices {
START, /**< Begin Game */
HIGHSCORES, /**< View Highscores */
SETTINGS, /**< View Settings */
};
/** Menu Class
* @brief Library for controlling menu options
* @author Ellis Blackford Stroud
* @date May, 2018
*/
class Menu {
public:
/** Constructor */
Menu();
/** Destructor */
~Menu();
/** Prints opening message */
void print_welcome(N5110 &lcd);
/** Prints menu screen */
void print_menu(N5110 &lcd);
/** Prints highscore screen */
void print_highscores(N5110 &lcd);
/** Prints settings screen */
void print_settings(N5110 &lcd);
/** Prints start screen */
void print_start(N5110 &lcd);
/** Updates and returns menu choice
* @returns an enum: START, HIGHSCORES, SETTINGS
*/
MenuChoices menu_choice(MenuChoices menu, Gamepad &pad, N5110 &lcd);
private:
};
#endif