first commit
This commit is contained in:
commit
5893b00dd2
1669 changed files with 1982740 additions and 0 deletions
25
libraries/M5Unified/examples/PlatformIO_SDL/src/sdl_main.cpp
Normal file
25
libraries/M5Unified/examples/PlatformIO_SDL/src/sdl_main.cpp
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
#include <M5GFX.h>
|
||||
#if defined ( SDL_h_ )
|
||||
|
||||
void setup(void);
|
||||
void loop(void);
|
||||
|
||||
__attribute__((weak))
|
||||
int user_func(bool* running)
|
||||
{
|
||||
setup();
|
||||
do
|
||||
{
|
||||
loop();
|
||||
} while (*running);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int main(int, char**)
|
||||
{
|
||||
// The second argument is effective for step execution with breakpoints.
|
||||
// You can specify the time in milliseconds to perform slow execution that ensures screen updates.
|
||||
return lgfx::Panel_sdl::main(user_func, 128);
|
||||
}
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue