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 Gamepad Joystick
Homepage Class Reference
#include <homepage.h>
| Public Member Functions | |
| Homepage () | |
| Constructor. | |
| ~Homepage () | |
| Destructor. | |
| void | welcome (N5110 &lcd, BusOut &output, Bgm &bgm) | 
| The welcome functions including lcd,leds and sound. | |
| void | over (N5110 &lcd, BusOut &output) | 
| The over functions including lcd and leds. | |
| void | homepage (N5110 &lcd, InterruptIn &buttonB, InterruptIn &start, int *score, int n) | 
| The over functions including lcd and leds. | |
| void | displayCurScore (N5110 &lcd, int score) | 
| The rangking lists. | |
| void | rules (N5110 &lcd, InterruptIn &buttonB) | 
| Draw images including a plane, a bullet and an enemy in the welcome page. | |
| int | again (N5110 &lcd, int score, InterruptIn &buttonX, InterruptIn &buttonY) | 
| Play again the game when score > 10 Back when score <=10. | |
Detailed Description
Homepage Class.
Library for different pages in the screen of mbed, University of Leeds
- Date:
- May 2020
Definition at line 14 of file homepage.h.
Constructor & Destructor Documentation
| Homepage | ( | ) | 
Constructor.
Definition at line 3 of file homepage.cpp.
| ~Homepage | ( | ) | 
Destructor.
Definition at line 7 of file homepage.cpp.
Member Function Documentation
| int again | ( | N5110 & | lcd, | 
| int | score, | ||
| InterruptIn & | buttonX, | ||
| InterruptIn & | buttonY | ||
| ) | 
Play again the game when score > 10 Back when score <=10.
- Parameters:
- 
  lcd (N5110) total score in one game (int) the button X (InterruptIn) the button Y (InterruptIn) 
- Returns:
- the score that need to be added to the previous one
Definition at line 80 of file homepage.cpp.
| void displayCurScore | ( | N5110 & | lcd, | 
| int | score | ||
| ) | 
The rangking lists.
- Parameters:
- 
  lcd (N5110) the vector of scores in the history (int) the size of score vector (int) 
Definition at line 57 of file homepage.cpp.
| void homepage | ( | N5110 & | lcd, | 
| InterruptIn & | buttonB, | ||
| InterruptIn & | start, | ||
| int * | score, | ||
| int | n | ||
| ) | 
The over functions including lcd and leds.
- Parameters:
- 
  lcd (N5110) the button A (InterruptIn) the button B (InterruptIn) the start button (InterruptIn) 
Definition at line 34 of file homepage.cpp.
| void over | ( | N5110 & | lcd, | 
| BusOut & | output | ||
| ) | 
The over functions including lcd and leds.
- Parameters:
- 
  lcd (N5110) a stream of output bits to control leds (Busout) 
Definition at line 22 of file homepage.cpp.
| void rules | ( | N5110 & | lcd, | 
| InterruptIn & | buttonB | ||
| ) | 
Draw images including a plane, a bullet and an enemy in the welcome page.
- Parameters:
- 
  lcd (N5110) the value of score (int) Display rules of the game lcd (N5110) the button B (InterruptIn) 
Definition at line 63 of file homepage.cpp.
| void welcome | ( | N5110 & | lcd, | 
| BusOut & | output, | ||
| Bgm & | bgm | ||
| ) | 
The welcome functions including lcd,leds and sound.
- Parameters:
- 
  lcd (N5110) stream of output bits to control leds (Busout) the welcome song (Sound) 
Definition at line 10 of file homepage.cpp.
Generated on Thu Jul 14 2022 01:43:57 by
 1.7.2
 1.7.2