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 BSP_DISCO_F746NG
main.cpp
- Committer:
- guillaume_m
- Date:
- 2020-11-18
- Revision:
- 2:3e54ffabcc47
File content as of revision 2:3e54ffabcc47:
#include "mbed.h"
#include "stm32746g_discovery_lcd.h"
#include "stm32746g_discovery_ts.h"
#include "header.h"
int main(){
uint8_t status;
BSP_LCD_Init();
BSP_LCD_LayerDefaultInit(LTDC_ACTIVE_LAYER, LCD_FB_START_ADDRESS);
BSP_LCD_SelectLayer(LTDC_ACTIVE_LAYER);
status = BSP_TS_Init(BSP_LCD_GetXSize(), BSP_LCD_GetYSize());
if (status != TS_OK) {
BSP_LCD_Clear(LCD_COLOR_RED);
BSP_LCD_SetBackColor(LCD_COLOR_RED);
BSP_LCD_SetTextColor(LCD_COLOR_WHITE);
BSP_LCD_DisplayStringAt(0, LINE(5), (uint8_t *)"TOUCHSCREEN INIT FAIL", CENTER_MODE);
}
else {
BSP_LCD_Clear(LCD_COLOR_BLACK);
BSP_LCD_SetBackColor(LCD_COLOR_BLACK);
int rejouer=0;
GRILLE G={0};
GRILLE Gsomme={0};
init_cellules(G);
partie(G,Gsomme);
rejouer = fin_de_partie(G,Gsomme);
if (rejouer==1){
main();
}
}
return 0;
}