From bdbbb753c58304b4d6ce61048cfb08e21d0a00b9 Mon Sep 17 00:00:00 2001 From: Solomon Peachy Date: Thu, 24 Sep 2026 15:44:56 -0400 Subject: [PATCH] ipod6gboot: Silence build warning introduced in af2a3b74f4 (ipod6g doesn't utilize the QR Code stuff used by the nano3g) Change-Id: I99c9e565b5a4c7212662eab097f1bae2f4ed0ea4 --- bootloader/ipod-s5l87xx.c | 68 ++++++++++++++++++++++----------------- 1 file changed, 38 insertions(+), 30 deletions(-) diff --git a/bootloader/ipod-s5l87xx.c b/bootloader/ipod-s5l87xx.c index 2ff2206a57..ef97a7dfb6 100644 --- a/bootloader/ipod-s5l87xx.c +++ b/bootloader/ipod-s5l87xx.c @@ -65,6 +65,9 @@ #include "norboot-target.h" #endif +#if defined(IPOD_NANO3G) +#define USE_QRCODE +#endif #define ERR_RB 0 #define ERR_OF 1 @@ -887,6 +890,40 @@ static void devel_menu(void) } #endif /* S5L87XX_DEVELOPMENT_BOOTLOADER */ +#ifdef IPOD_NANO3G +static const char qr_code_data_nano[][22] = { + /* + * qrencode -o - -t ascii -s 1 -m 0 -i 'https://rockbox.org/IPNBL' | \ + * cut -c 1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41 | \ + * awk '{ print "\"" $0 "\"," }' + */ + + "####### # #######", + "# # ## # # #", + "# ### # ## # # ### #", + "# ### # # # # # ### #", + "# ### # # ## # ### #", + "# # #### # #", + "####### # # # #######", + " ## ", + "##### ######## # # # ", + "# # #### # # #", + " # # # #", + "## # # # # ## #### ", + "# ### ## ### ", + " ## # # ####", + "####### ## # ### #", + "# # ### # ## ", + "# ### # # #### ###", + "# ### # ### ### ## ", + "# ### # #### # # ", + "# # # ## ## # #", + "####### # ## ## ", +}; +#define qr_code_data qr_code_data_nano +#endif + +#ifdef USE_QRCODE static void lcd_qr_code(const char *data, unsigned int row_stride, int x, int y, unsigned int qr_cols, unsigned int qr_rows, unsigned int modules_scale, unsigned int margin_thickness) @@ -919,41 +956,12 @@ static void lcd_qr_code(const char *data, unsigned int row_stride, lcd_update(); } -static const char qr_code_data[][22] = { - /* - * qrencode -o - -t ascii -s 1 -m 0 -i 'https://rockbox.org/IPNBL' | \ - * cut -c 1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41 | \ - * awk '{ print "\"" $0 "\"," }' - */ - - "####### # #######", - "# # ## # # #", - "# ### # ## # # ### #", - "# ### # # # # # ### #", - "# ### # # ## # ### #", - "# # #### # #", - "####### # # # #######", - " ## ", - "##### ######## # # # ", - "# # #### # # #", - " # # # #", - "## # # # # ## #### ", - "# ### ## ### ", - " ## # # ####", - "####### ## # ### #", - "# # ### # ## ", - "# ### # # #### ###", - "# ### # ### ### ## ", - "# ### # #### # # ", - "# # # ## ## # #", - "####### # ## ## ", -}; - enum { QR_COLS = sizeof(qr_code_data[0]) - 1, QR_ROWS = sizeof(qr_code_data) / sizeof(qr_code_data[0]), QR_STRIDE = sizeof(qr_code_data[0]), }; +#endif /* USE_QRCODE */ void main(void) {