From c77136a24837a41fe1561778d4563d22679850fb Mon Sep 17 00:00:00 2001 From: graham sanderson Date: Mon, 4 Apr 2022 12:45:05 -0500 Subject: [PATCH] Add binary info indicating WAD/WXD type and flash load address --- src/w_file_memory.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/w_file_memory.c b/src/w_file_memory.c index 3aaead07..812823af 100644 --- a/src/w_file_memory.c +++ b/src/w_file_memory.c @@ -28,7 +28,7 @@ #include "w_wad.h" #if PICO_BUILD #include "pico.h" -#include "pico.h" +#include "pico/binary_info.h" #else #define panic I_Error #endif @@ -38,6 +38,13 @@ #error TINY_WAD_ADDR must be specified #endif #define wad_map_base ((const uint8_t *)TINY_WAD_ADDR) +// simplest thing here is to use a feature, rather than a separate feature group +#if WHD_SUPER_TINY +#define ADDR_FNAME "WHX at " __XSTRING(TINY_WAD_ADDR) +#else +#define ADDR_FNAME "WHD at " __XSTRING(TINY_WAD_ADDR) +#endif +bi_decl(bi_program_feature(ADDR_FNAME)); #endif #if !USE_WHD