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.
Diff: SavedGames/SavedGames.h
- Revision:
- 64:e9dfc35a1738
- Parent:
- 63:4631447440cf
- Child:
- 67:a2984682d641
diff -r 4631447440cf -r e9dfc35a1738 SavedGames/SavedGames.h --- a/SavedGames/SavedGames.h Thu May 21 00:09:10 2020 +0000 +++ b/SavedGames/SavedGames.h Thu May 21 14:26:23 2020 +0000 @@ -6,7 +6,6 @@ #include "N5110.h" #include "Gamepad.h" #include "SDFileSystem.h" -#include <vector> struct SavedGamesData{ int score; /**< Score variable */ @@ -35,17 +34,6 @@ */ void init(SDFileSystem &sd,N5110 &lcd); - /** Check if sd card is inserted and print message if not - * @param lcd @details N5110 object - * @param sd @details sd card object - */ - void check_sd_present(SDFileSystem &sd,N5110 &lcd); - - /** shows error if saved data files opens incorrectly - * @param lcd @details N5110 object - */ - void error_open_file(N5110 &lcd); - /** Adds saved data to sd card * @param sd @details sd card object * @param data @details SavedGamesData struct @@ -75,11 +63,6 @@ */ void save_game_screen(N5110 &lcd); - /** Draws no saved files screen - * @param lcd @details N5110 object - */ - void no_saved_files(N5110 &lcd); - // Accessors and mutators -------------------------------------------------- /** Gets error flag @@ -90,7 +73,7 @@ /** set error * @param error; */ - bool set_error(bool error); + void set_error(bool error); /** Gets the displayed saved game number * @return display_data_number_; @@ -98,6 +81,24 @@ int get_display_data_number(); private: + // Function prototypes ----------------------------------------------------- + + /** Check if sd card is inserted and print message if not + * @param lcd @details N5110 object + * @param sd @details sd card object + * @note Dont think sd.card_present()function acutally works + */ + void check_sd_present(SDFileSystem &sd,N5110 &lcd); + + /** shows error if saved data files opens incorrectly + * @param lcd @details N5110 object + */ + void error_open_file(N5110 &lcd); + + /** Draws no saved files screen + * @param lcd @details N5110 object + */ + void no_saved_files(N5110 &lcd); // Varibles ----------------------------------------------------------------