From d5beea3551e430ab538032cd845e147b5ef78105 Mon Sep 17 00:00:00 2001 From: Alexandre Abadie Date: Tue, 12 Apr 2022 09:36:31 +0200 Subject: [PATCH] tests/disp_dev: use width/height defines from riot_logo.h --- tests/disp_dev/main.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/disp_dev/main.c b/tests/disp_dev/main.c index 18c149b3a9..b903af65f5 100644 --- a/tests/disp_dev/main.c +++ b/tests/disp_dev/main.c @@ -64,7 +64,12 @@ int main(void) disp_dev_map(disp_dev->dev, 0, max_width - 1, y, y, display_buffer); } - disp_dev_map(disp_dev->dev, 95, 222, 85, 153, (const uint16_t *)picture); + disp_dev_map( + disp_dev->dev, + ((max_width - RIOT_LOGO_WIDTH) >> 1), ((max_width + RIOT_LOGO_WIDTH) >> 1) - 1, + ((max_height - RIOT_LOGO_HEIGHT) >> 1), ((max_height + RIOT_LOGO_HEIGHT) >> 1) - 1, + (const uint16_t *)picture + ); puts("SUCCESS");