diff --git a/software/sys_controller/Makefile b/software/sys_controller/Makefile index 1711559..ed6950c 100644 --- a/software/sys_controller/Makefile +++ b/software/sys_controller/Makefile @@ -165,7 +165,11 @@ C_SRCS += ossc/menu_sjis.c else C_SRCS += ossc/menu.c endif +ifeq ($(OSDLANG),JP) +C_SRCS += ossc/userdata_sjis.c +else C_SRCS += ossc/userdata.c +endif C_SRCS += ossc/utils.c C_SRCS += ulibSD/sd_io.c C_SRCS += ulibSD/spi_io.c @@ -971,7 +975,7 @@ clean : clean_elf_derived_files endif clean : - @$(RM) -r $(ELF) $(OBJDUMP_NAME) $(LINKER_MAP_NAME) $(OBJ_ROOT_DIR) $(RUNTIME_ROOT_DIR) $(FORCE_REBUILD_DEP_LIST) ossc/menu_sjis.c + @$(RM) -r $(ELF) $(OBJDUMP_NAME) $(LINKER_MAP_NAME) $(OBJ_ROOT_DIR) $(RUNTIME_ROOT_DIR) $(FORCE_REBUILD_DEP_LIST) ossc/menu_sjis.c ossc/userdata_sjis.c @$(ECHO) [$(APP_NAME) clean complete] # Clean just the BSP. @@ -1131,6 +1135,9 @@ print-elf-name: ossc/menu_sjis.c: ossc/menu.c iconv -f UTF-8 -t SHIFT-JIS ossc/menu.c > ossc/menu_sjis.c +ossc/userdata_sjis.c: ossc/userdata.c + iconv -f UTF-8 -t SHIFT-JIS ossc/userdata.c > ossc/userdata_sjis.c + mem_init/sys_onchip_memory2_0.hex: sys_controller.elf $(RV_OBJCOPY) --change-addresses -0x10000 -O binary --gap-fill 0 $< mem_init/sys_onchip_memory2_0.bin ../../tools/bin2hex 4 mem_init/sys_onchip_memory2_0.bin mem_init/sys_onchip_memory2_0.hex diff --git a/software/sys_controller/ossc/menu.c b/software/sys_controller/ossc/menu.c index 59f2dcd..d6fcbcc 100644 --- a/software/sys_controller/ossc/menu.c +++ b/software/sys_controller/ossc/menu.c @@ -29,12 +29,6 @@ #define OPT_NOWRAP 0 #define OPT_WRAP 1 -#ifdef OSDLANG_JP -#define LNG(e, j) j -#else -#define LNG(e, j) e -#endif - extern char row1[LCD_ROW_LEN+1], row2[LCD_ROW_LEN+1], menu_row1[LCD_ROW_LEN+1], menu_row2[LCD_ROW_LEN+1]; extern avmode_t cm; extern avconfig_t tc; diff --git a/software/sys_controller/ossc/menu.h b/software/sys_controller/ossc/menu.h index e01f0ce..2485449 100644 --- a/software/sys_controller/ossc/menu.h +++ b/software/sys_controller/ossc/menu.h @@ -23,6 +23,12 @@ #include "alt_types.h" #include "controls.h" +#ifdef OSDLANG_JP +#define LNG(e, j) j +#else +#define LNG(e, j) e +#endif + typedef enum { OPT_AVCONFIG_SELECTION, OPT_AVCONFIG_NUMVALUE, diff --git a/software/sys_controller/ossc/userdata.c b/software/sys_controller/ossc/userdata.c index 245ca06..3aae397 100644 --- a/software/sys_controller/ossc/userdata.c +++ b/software/sys_controller/ossc/userdata.c @@ -371,12 +371,18 @@ int export_userdata() alt_u8 prompt_state = 0; useconds_t prompt_delay; const alt_u8 prompt_transitions[] = { 1, 2, 0, 0, }; - const alt_u8 prompt_ofs[] = { 0, 16, 31, 48, }; + const alt_u8 prompt_ofs[] = { 0, 16, 31, LNG(48, 47), }; const char *prompt_msgs = + LNG( "SD CARD WILL BE" "\0" // [ 0..15] "OVERWRITTEN!!!" "\0" // [16..30] "Export? 1=Y, 2=N""\0" // [31..47] - "Press 1 or 2"; // [48..60] + "Press 1 or 2", // [48..60] + "SDカードヲウワガキシマス" "\0" // [ 0..15] + "ゴチュウイクダサイ!!!" "\0" // [16..30] + "1=ジッコウスル 2=ヤメル" "\0" // [31..46] + "ドチラカエランデクダサイ" // [47..60] + ); alt_u32 btn_vec; _Static_assert(SD_BLK_SIZE == FAT16_SECTOR_SIZE, "Sector size mismatch");