Skip to content

Commit

Permalink
Merge pull request #2316 from arduino/benjamindannegard/giga-display-…
Browse files Browse the repository at this point in the history
…shield-add-delay

[GIGA Display Shield] Added delays to all sketches
  • Loading branch information
BenjaminDannegard authored Dec 16, 2024
2 parents 109c079 + 0ed56c9 commit d84b3c1
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ To use the library, we simply need to create a display object, initialize the li
GigaDisplay_GFX display; // create the object
void setup() {
delay(3000);
display.begin(); //init library
display.setCursor(10,10); //x,y
Expand Down Expand Up @@ -97,6 +98,7 @@ GigaDisplay_GFX display; // create the object
#define BLACK 0x0000
void setup() {
delay(3000);
display.begin();
display.fillScreen(BLACK);
display.setCursor(10,10); //x,y
Expand Down Expand Up @@ -131,6 +133,7 @@ GigaDisplay_GFX display;
#define BLACK 0x0000
void setup() {
delay(3000);
display.begin();
display.fillScreen(WHITE);
display.drawTriangle(100, 200, 300, 400, 300, 600, BLACK);
Expand Down Expand Up @@ -173,6 +176,7 @@ int counter;
void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
delay(3000);
display.begin();
if (touchDetector.begin()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ In the `setup()`, we begin by initializing the display and the touch detector.

```arduino
void setup(){
delay(3000);
Display.begin();
TouchDetector.begin();
}
Expand Down Expand Up @@ -154,6 +155,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
Arduino_GigaDisplayTouch TouchDetector;
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down Expand Up @@ -236,6 +238,7 @@ To make sure we see the image use the align function to make it centered. Then a
Arduino_H7_Video Display(800, 480, GigaDisplayShield);
void setup() {
delay(3000);
Display.begin();
lv_obj_t * screen = lv_obj_create(lv_scr_act());
Expand Down Expand Up @@ -335,6 +338,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
Arduino_GigaDisplayTouch TouchDetector;
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down Expand Up @@ -410,6 +414,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
Arduino_GigaDisplayTouch TouchDetector;
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down Expand Up @@ -506,6 +511,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield); /* Arduino_H7_Vi
Arduino_GigaDisplayTouch TouchDetector;
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down Expand Up @@ -634,6 +640,7 @@ static void set_slider_val(void * bar, int32_t val) {
}
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down Expand Up @@ -752,6 +759,7 @@ static void btn_event_cb(lv_event_t * e) {
}
void setup() {
delay(3000);
Display.begin();
TouchDetector.begin();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Let's first draw the background of the image. Start by initializing the display

```arduino
void setup() {
delay(3000);
Display.begin();
Display.beginDraw();
Expand Down Expand Up @@ -97,6 +98,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
//Arduino_H7_Video Display(1024, 768, USBCVideo);
void setup() {
delay(3000);
Display.begin();
Display.beginDraw();
Expand Down Expand Up @@ -193,6 +195,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
Image img_arduinologo(ENCODING_RGB16, (uint8_t *) texture_raw, 300, 300);
void setup() {
delay(3000);
Display.begin();
Display.beginDraw();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ int lastTouch;
int threshold = 250; //time in milliseconds
void setup() {
delay(3000);
Serial.begin(115200);
while(!Serial) {}
Expand Down Expand Up @@ -147,6 +148,7 @@ int threshold = 250;
bool switch_1;
void setup() {
delay(3000);
// put your setup code here, to run once:
Serial.begin(9600);
display.begin();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ LV_IMG_DECLARE(img_arduinologo);
lv_obj_t * img;
void setup() {
delay(3000);
Serial.begin(115200);
Display.begin();
Expand Down Expand Up @@ -91,6 +92,7 @@ The easiest way to tell what values you are getting depending on the orientation
BoschSensorClass imu(Wire1);
void setup(){
delay(3000);
Serial.begin(115200);
imu.begin();
}
Expand Down Expand Up @@ -131,6 +133,7 @@ LV_IMG_DECLARE(img_arduinologo);
lv_obj_t * img;
void setup() {
delay(3000);
Serial.begin(115200);
Display.begin();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ short sampleBuffer[512];
volatile int samplesRead;
void setup() {
delay(3000);
Display.begin();
Display.beginDraw();
Display.background(255, 255, 255);
Expand Down Expand Up @@ -316,6 +317,7 @@ lv_anim_t a;
int micValue;
void setup() {
delay(3000);
Display.begin();
PDM.onReceive(onPDMdata);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ void blinkLED(uint32_t count = 0xFFFFFFFF)
uint32_t palette[256];
void setup() {
delay(3000);
// Init the cam QVGA, 30FPS
if (!cam.begin(CAMERA_R320x240, IMAGE_MODE, 30)) {
blinkLED();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ Arduino_H7_Video Display(800, 480, GigaDisplayShield);
Arduino_GigaDisplayTouch Touch;
void setup() {
delay(3000);
Display.begin();
Touch.begin();
Expand Down Expand Up @@ -119,6 +120,7 @@ Then it is as simple as using the names of the widgets in a LVGL function. For e

```arduino
void setup() {
delay(3000);
Display.begin();
Touch.begin();
Expand Down Expand Up @@ -182,6 +184,7 @@ static void ButtonDec_evt_handler(lv_event_t * e) {
}
void setup() {
delay(3000);
Display.begin();
Touch.begin();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ When creating elements, information about the screen and placement needs to be p

```arduino
void setup() {
delay(3000);
/* Init SEGGER emWin library. It also init display and touch controller */
GUI_Init();
Expand All @@ -73,6 +74,7 @@ Here is an example that sets the screen background color to green and prints the
#include <DIALOG.h>
void setup() {
delay(3000);
GUI_Init();
GUI_MULTIBUF_Begin();
GUI_SetBkColor(GUI_GREEN);
Expand Down Expand Up @@ -261,6 +263,7 @@ static void _cbWin(WM_MESSAGE * pMsg) {
}
void setup() {
delay(3000);
GUI_Init();
WM_MULTIBUF_Enable(1);
WM_CreateWindowAsChild(0, 0, LCD_GetXSize(), LCD_GetYSize(), WM_HBKWIN, WM_CF_SHOW, _cbWin, 0);
Expand Down Expand Up @@ -358,6 +361,7 @@ static void _cbChildWinCheck(WM_MESSAGE * pMsg) {
}
void setup() {
delay(3000);
/* Init SEGGER emWin library. It also init display and touch controller */
GUI_Init();
Expand Down Expand Up @@ -469,6 +473,7 @@ static void _cbChildWinSlider(WM_MESSAGE * pMsg) {
}
void setup() {
delay(3000);
/* Init SEGGER emWin library. It also init display and touch controller */
GUI_Init();
Expand Down Expand Up @@ -608,6 +613,7 @@ int progbarCnt = 0;
unsigned long previousMillis = 0;
void setup() {
delay(3000);
/* Init SEGGER emWin library. It also init display and touch controller */
GUI_Init();
Expand Down Expand Up @@ -732,6 +738,7 @@ static void _cbChildWinBtn(WM_MESSAGE * pMsg) {
}
void setup() {
delay(3000);
/* Init SEGGER emWin library. It also init display and touch controller */
GUI_Init();
Expand Down

0 comments on commit d84b3c1

Please sign in to comment.