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.
Fork of PokittoLib by
Core Class Reference
#include <PokittoCore.h>
Public Member Functions | |
| Core () | |
| Create a Core runtime instance. | |
Static Public Member Functions | |
| static void | begin () |
| Initialize runtime (use this one) | |
| static void | init () |
| Initialize runtime (deprecated, avoid) | |
| static void | init (uint8_t) |
| Initialize runtime with options (deprecated, avoid) | |
| static bool | isRunning () |
| Return run state (1 = running, 0 = shutting down) | |
| static void | quit () |
| Stop running. | |
| static void | initDisplay () |
| Initialize display. | |
| static void | initRandom () |
| Initialize random generator. | |
| static void | initGPIO () |
| Initialize GPIO. | |
| static void | initLCD () |
| Initialize LCD. | |
| static void | initAudio () |
| Initialize Audio. | |
| static void | initBacklight () |
| Initialize backlight. | |
| static void | initClock () |
| Initialize runtime clock. | |
| static uint32_t | getTime () |
| Get value of time elapsed during program in milliseconds. | |
| static void | wait (uint16_t) |
| Wait for n milliseconds. | |
| static void | showLogo () |
| Display Pokitto logo. | |
Static Public Attributes | |
| static Backlight | backlight |
| Backlight component of the Core runtime. | |
| static Buttons | buttons |
| Buttons component of the Core runtime. | |
| static Battery | battery |
| Battery component of the Core runtime. | |
| static Sound | sound |
| Sound component of the Core runtime. | |
| static Display | display |
| Display component of the Core runtime. | |
Detailed Description
Core class.
The Core class is a class consisting of static data and methods. It handles the lowlevel hardware functions of the Pokitto. It is declared as static to prevent several instances running at same time. Example:
// A simple "Hello World!" program with Pokitto #include "Pokitto.h " Pokitto::Core myApp; int main() { myApp.begin(); // This starts up the console (the display, buttons etc.) while(myApp.isRunning()) { if(myApp.Update()) { myApp.display.print("Hello World!"); } } }
Definition at line 100 of file PokittoCore.h.
Constructor & Destructor Documentation
| Core | ( | ) |
Create a Core runtime instance.
Definition at line 162 of file PokittoCore.cpp.
Member Function Documentation
| void begin | ( | ) | [static] |
Initialize runtime (use this one)
Definition at line 414 of file PokittoCore.cpp.
| uint32_t getTime | ( | ) | [static] |
Get value of time elapsed during program in milliseconds.
Definition at line 74 of file PokittoClock.cpp.
| void init | ( | ) | [static] |
Initialize runtime (deprecated, avoid)
Definition at line 484 of file PokittoCore.cpp.
| void init | ( | uint8_t | switches ) | [static] |
Initialize runtime with options (deprecated, avoid)
Definition at line 496 of file PokittoCore.cpp.
| static void initAudio | ( | ) | [static] |
Initialize Audio.
| static void initBacklight | ( | ) | [static] |
Initialize backlight.
| void initClock | ( | ) | [static] |
Initialize runtime clock.
Definition at line 61 of file PokittoClock.cpp.
| void initDisplay | ( | ) | [static] |
Initialize display.
Definition at line 521 of file PokittoCore.cpp.
| void initGPIO | ( | ) | [static] |
| static void initLCD | ( | ) | [static] |
Initialize LCD.
| void initRandom | ( | ) | [static] |
Initialize random generator.
Definition at line 50 of file PokittoHW.cpp.
| bool isRunning | ( | ) | [static] |
Return run state (1 = running, 0 = shutting down)
Definition at line 514 of file PokittoCore.cpp.
| void quit | ( | ) | [static] |
Stop running.
Definition at line 46 of file PokittoHW.cpp.
| void showLogo | ( | ) | [static] |
Display Pokitto logo.
POKITTO CLEAN
POKITTO FADE IN
POKITTO WAIT
Definition at line 530 of file PokittoCore.cpp.
| void wait | ( | uint16_t | ms ) | [static] |
Wait for n milliseconds.
Definition at line 78 of file PokittoClock.cpp.
Field Documentation
Backlight backlight [static] |
Battery battery [static] |
Battery component of the Core runtime.
Definition at line 112 of file PokittoCore.h.
Buttons buttons [static] |
Buttons component of the Core runtime.
Definition at line 110 of file PokittoCore.h.
Display display [static] |
Display component of the Core runtime.
Definition at line 116 of file PokittoCore.h.
Sound sound [static] |
Sound component of the Core runtime.
Definition at line 114 of file PokittoCore.h.
Generated on Tue Jul 12 2022 18:08:14 by
1.7.2
