From 89e0f3c70880da5ba9aaedb5c2007bea540e0eef Mon Sep 17 00:00:00 2001 From: nakasima Date: Wed, 26 Dec 2007 04:50:36 +0000 Subject: [PATCH] =?UTF-8?q?GCD=E3=83=95=E3=82=A1=E3=83=BC=E3=83=A0LCD?= =?UTF-8?q?=E8=A1=A8=E7=A4=BA=E3=83=87=E3=83=A2=E8=BF=BD=E5=8A=A0=E3=80=82?= =?UTF-8?q?=E3=82=B9=E3=82=BF=E3=83=BC=E3=83=88=E3=82=A2=E3=83=83=E3=83=97?= =?UTF-8?q?=E3=81=A7=E3=82=B7=E3=82=B9=E3=83=86=E3=83=A0=E9=A0=98=E5=9F=9F?= =?UTF-8?q?=E3=82=AF=E3=83=AA=E3=82=A2=E5=BE=8C=E3=81=ABSCFG=E3=82=92?= =?UTF-8?q?=E3=82=B3=E3=83=94=E3=83=BC=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlIPL/trunk@401 b08762b0-b915-fc4b-9d8c-17b2551a87ff --- build/Makefile | 4 +- build/gcdfirm/Makefile | 34 + build/gcdfirm/gcdfirm-disp/ARM7/Makefile | 51 ++ build/gcdfirm/gcdfirm-disp/ARM7/main.c | 66 ++ build/gcdfirm/gcdfirm-disp/ARM9/Makefile | 59 ++ build/gcdfirm/gcdfirm-disp/ARM9/font.c | 588 ++++++++++++++++++ .../gcdfirm/gcdfirm-disp/ARM9/include/font.h | 60 ++ .../gcdfirm-disp/ARM9/include/screen.h | 52 ++ build/gcdfirm/gcdfirm-disp/ARM9/main.c | 150 +++++ build/gcdfirm/gcdfirm-disp/ARM9/screen.c | 120 ++++ build/gcdfirm/gcdfirm-disp/Makefile | 52 ++ build/gcdfirm/gcdfirm-disp/gcdfirm.gcdsf | 21 + build/gcdfirm/gcdfirm-disp/wram_regs/Makefile | 57 ++ .../gcdfirm-disp/wram_regs/wram_regs.c | 91 +++ build/gcdfirm/gcdfirm-print/Makefile | 46 ++ build/gcdfirm/gcdfirm-print/gcdfirm.gcdsf | 22 + build/libraries/init/ARM7/crt0_firm.c | 76 ++- build/libraries/init/ARM9/crt0_firm.c | 57 +- build/libraries/mi/ARM9/mi_init_mainMemory.c | 11 +- build/libraries/pxi/common/pxi_firm.c | 45 ++ build/norfirm/Makefile | 1 + build/norfirm/firm-dev/ARM7/Makefile | 49 ++ build/norfirm/firm-dev/ARM7/main.c | 55 ++ build/norfirm/firm-dev/ARM9/Makefile | 48 ++ build/norfirm/firm-dev/ARM9/main.c | 41 ++ build/norfirm/firm-dev/Makefile | 53 ++ build/norfirm/firm-dev/norfirm.norsf | 25 + build/norfirm/firm-dev/wram_regs/Makefile | 57 ++ build/norfirm/firm-dev/wram_regs/wram_regs.c | 91 +++ include/firm/pxi/common/pxi_firm.h | 33 + readme.txt | 2 + tools/bin/gcdfirm_header_twlj.template.sbin | Bin 0 -> 16384 bytes 32 files changed, 2107 insertions(+), 10 deletions(-) create mode 100644 build/gcdfirm/Makefile create mode 100644 build/gcdfirm/gcdfirm-disp/ARM7/Makefile create mode 100644 build/gcdfirm/gcdfirm-disp/ARM7/main.c create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/Makefile create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/font.c create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/include/font.h create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/include/screen.h create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/main.c create mode 100644 build/gcdfirm/gcdfirm-disp/ARM9/screen.c create mode 100644 build/gcdfirm/gcdfirm-disp/Makefile create mode 100644 build/gcdfirm/gcdfirm-disp/gcdfirm.gcdsf create mode 100644 build/gcdfirm/gcdfirm-disp/wram_regs/Makefile create mode 100644 build/gcdfirm/gcdfirm-disp/wram_regs/wram_regs.c create mode 100644 build/gcdfirm/gcdfirm-print/Makefile create mode 100644 build/gcdfirm/gcdfirm-print/gcdfirm.gcdsf create mode 100644 build/norfirm/firm-dev/ARM7/Makefile create mode 100644 build/norfirm/firm-dev/ARM7/main.c create mode 100644 build/norfirm/firm-dev/ARM9/Makefile create mode 100644 build/norfirm/firm-dev/ARM9/main.c create mode 100644 build/norfirm/firm-dev/Makefile create mode 100644 build/norfirm/firm-dev/norfirm.norsf create mode 100644 build/norfirm/firm-dev/wram_regs/Makefile create mode 100644 build/norfirm/firm-dev/wram_regs/wram_regs.c create mode 100644 tools/bin/gcdfirm_header_twlj.template.sbin diff --git a/build/Makefile b/build/Makefile index d972d5b4..fc4cb349 100644 --- a/build/Makefile +++ b/build/Makefile @@ -27,7 +27,9 @@ SUBDIRS = \ nandfirm \ libraries_sysmenu\ components \ - systemmenu_RED + systemmenu_RED \ + gcdfirm \ + ifdef TWL_IPL_WITH_TESTS SUBDIRS += tests endif diff --git a/build/gcdfirm/Makefile b/build/gcdfirm/Makefile new file mode 100644 index 00000000..9d23e443 --- /dev/null +++ b/build/gcdfirm/Makefile @@ -0,0 +1,34 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - firmware +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + + +#---------------------------------------------------------------------------- + +SUBDIRS = \ + gcdfirm-disp \ + gcdfirm-print \ + + +#---------------------------------------------------------------------------- + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-disp/ARM7/Makefile b/build/gcdfirm/gcdfirm-disp/ARM7/Makefile new file mode 100644 index 00000000..ac07e3ac --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM7/Makefile @@ -0,0 +1,51 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - tools - menu-launcher +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +TWL_PROC = ARM7 + +SUBDIRS = + +LINCLUDES = ../include + +#---------------------------------------------------------------------------- + +TARGET_BIN = gcdfirm_disp7.tef + +SRCS = main.c + +CRT0_O = crt0_firm.o + +ADDRESS_STATIC = 0x037b8000 + +#LCFILE_TEMPLATE = $(FIRM_SPECDIR)/$(TWL_PROC)-$(TWL_PLATFORM)-PARTNER.lcf.template + +#SRCDIR = # using default +#LCFILE = # using default + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +MAKELCF_FLAGS += -DADDRESS_LTDWRAM='0x037c0000' + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-disp/ARM7/main.c b/build/gcdfirm/gcdfirm-disp/ARM7/main.c new file mode 100644 index 00000000..d9d563b4 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM7/main.c @@ -0,0 +1,66 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - firm_writer_gcd + File: main.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: $ + $NoKeywords: $ + *---------------------------------------------------------------------------*/ +#include +#include + +//#define PRINT_DEBUG + +#ifndef PRINT_DEBUG +#undef OS_TPrintf +#undef OS_PutChar +#define OS_TPrintf(...) ((void)0) +#define OS_PutChar(...) ((void)0) +#endif // PRINT_DEBUG + +void TwlSpMain( void ) +{ +#ifdef PRINT_DEBUG + reg_SCFG_JTAG = REG_SCFG_JTAG_CPUJE_MASK | REG_SCFG_JTAG_ARM7SEL_MASK; +#endif // PRINT_DEBUG + + MIi_CpuClearFast( 0, (void*)OSi_GetFromBromAddr(), sizeof(OSFromBromBuf) ); + + OS_InitFIRM(); + + OS_TPrintf( "\nARM7 starts.\n" ); + + OS_EnableInterrupts(); + OS_EnableIrq(); + + PM_InitFIRM(); + PMi_SetParams( REG_PMIC_BL_BRT_A_ADDR, PMIC_BACKLIGHT_BRIGHT_DEFAULT, PMIC_BL_BRT_A_MASK ); + PMi_SetParams( REG_PMIC_BL_BRT_B_ADDR, PMIC_BACKLIGHT_BRIGHT_DEFAULT, PMIC_BL_BRT_B_MASK ); + PM_BackLightOn( TRUE ); + + // ボタンが押されるまで待つ + OS_TPrintf( "\nPress A button.\n"); + while ( !(PAD_Read() & PAD_BUTTON_A) ) + { + } + + OS_TPrintf( "\nARM7 ends.\n" ); + (void)OS_DisableIrq(); +// OSi_Finalize(); +#ifdef PRINT_DEBUG + reg_SCFG_JTAG = REG_SCFG_JTAG_CPUJE_MASK | REG_SCFG_JTAG_ARM7SEL_MASK; +#endif // PRINT_DEBUG + while (1) + { + } +// OS_Terminate(); +} + + diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/Makefile b/build/gcdfirm/gcdfirm-disp/ARM9/Makefile new file mode 100644 index 00000000..58234284 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/Makefile @@ -0,0 +1,59 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - nandfirm - menu-launcher +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +SUBDIRS = + +#LINCLUDES = ../include + +#---------------------------------------------------------------------------- + +TARGET_BIN = gcdfirm_disp9.srl + +SRCS = main.c \ + screen.c \ + font.c \ + +CRT0_O = crt0_firm.o + +ADDRESS_STATIC = 0x037c0000 + +MAKEROM_ARM7 = ../ARM7/bin/$(TWL_BUILDTYPE_ARM7)/gcdfirm_disp7.tef +MAKEROM_ARM7_BASE = $(basename $(MAKEROM_ARM7)) + +#LCFILE_TEMPLATE = $(FIRM_SPECDIR)/$(TWL_PROC)-$(TWL_PLATFORM)-PARTNER.lcf.template + +#SRCDIR = # using default +#LCFILE = # using default + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +# no thumb version + +#LLIBRARIES += libese$(TWL_LIBSUFFIX).a +LLIBRARIES += libese.TWL$(ARCHGEN_TYPE).a + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/font.c b/build/gcdfirm/gcdfirm-disp/ARM9/font.c new file mode 100644 index 00000000..ee49f50b --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/font.c @@ -0,0 +1,588 @@ +/*---------------------------------------------------------------------------* + Project: NitroSDK - SPI - demos - pm-1 + File: font.c + + Copyright 2003-2005 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: font.c,v $ + Revision 1.3 2005/02/28 05:26:11 yosizaki + do-indent. + + Revision 1.2 2004/11/02 07:19:52 terui + コメント内スペルミスを修正。 + + Revision 1.1 2004/08/07 01:59:51 yada + modified much + + $NoKeywords: $ + *---------------------------------------------------------------------------*/ + +#include "font.h" + + +/*---------------------------------------------------------------------------* + Character data + *---------------------------------------------------------------------------*/ +const u32 d_CharData[8 * 256] = { + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 0000h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x01010010, 0x01010010, 0x00000110, // 0001h + 0x00011010, 0x01100010, 0x00000010, 0x00000010, + 0x00000000, 0x01011010, 0x01010010, 0x00010010, // 0002h + 0x00100010, 0x00100010, 0x00100001, 0x00100001, + 0x00000000, 0x01010001, 0x01010001, 0x01111111, // 0003h + 0x00000001, 0x00000001, 0x00000001, 0x01111110, + 0x00000000, 0x01010000, 0x01111111, 0x00100000, // 0004h + 0x00100000, 0x00010000, 0x00001000, 0x00000110, + 0x00000000, 0x01010000, 0x01010100, 0x00001010, // 0005h + 0x00010001, 0x00100001, 0x01000000, 0x00000000, + 0x00000000, 0x01011000, 0x01011000, 0x01111111, // 0006h + 0x00001000, 0x00101010, 0x01001010, 0x01001001, + 0x00000000, 0x01010010, 0x01101111, 0x01010010, // 0007h + 0x00010010, 0x00010010, 0x00010010, 0x00001001, + 0x00000000, 0x01010010, 0x01011111, 0x00000100, // 0008h + 0x00011111, 0x00001000, 0x00000001, 0x00011110, + 0x00000000, 0x01010000, 0x01011000, 0x00000110, // 0009h + 0x00000001, 0x00000110, 0x00011000, 0x00100000, + 0x00000000, 0x01010000, 0x01111101, 0x00010001, // 000ah + 0x00010001, 0x00010001, 0x00010001, 0x00001010, + 0x00000000, 0x01010000, 0x01011110, 0x00100000, // 000bh + 0x00000000, 0x00000001, 0x00000001, 0x00111110, + 0x00000000, 0x01010100, 0x01011111, 0x00001000, // 000ch + 0x00010000, 0x00000001, 0x00000001, 0x00011110, + 0x00000000, 0x01010001, 0x01010001, 0x00000001, // 000dh + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x01010000, 0x01111111, 0x00011000, // 000eh + 0x00010100, 0x00010100, 0x00011000, 0x00001100, + 0x00000000, 0x01010010, 0x01111111, 0x00010010, // 000fh + 0x00010010, 0x00000010, 0x00000010, 0x00111100, + 0x00000000, 0x00001110, 0x01010100, 0x01010010, // 0010h + 0x00111111, 0x00000100, 0x00000100, 0x00011000, + 0x00000000, 0x01010100, 0x01011111, 0x00000100, // 0011h + 0x01110100, 0x00000010, 0x00001010, 0x01110010, + 0x00000000, 0x01010100, 0x01011111, 0x00000010, // 0012h + 0x00011110, 0x00100001, 0x00100000, 0x00011110, + 0x00000000, 0x01010000, 0x01011100, 0x00100011, // 0013h + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x01010000, 0x01111111, 0x00010000, // 0014h + 0x00001000, 0x00001000, 0x00001000, 0x00110000, + 0x00000000, 0x01010010, 0x01010010, 0x00001100, // 0015h + 0x00000010, 0x00000001, 0x00000001, 0x00111110, + 0x00000000, 0x01010001, 0x01111101, 0x00010001, // 0016h + 0x00010001, 0x00111001, 0x01010101, 0x00011001, + 0x00000000, 0x01010100, 0x01010011, 0x01110010, // 0017h + 0x00010001, 0x00010001, 0x00001010, 0x00000100, + 0x00000000, 0x01011110, 0x01011000, 0x00000100, // 0018h + 0x00101001, 0x01010001, 0x01010001, 0x00001100, + 0x00000000, 0x01010000, 0x01011100, 0x00010010, // 0019h + 0x00010010, 0x00100001, 0x01000000, 0x00000000, + 0x00000000, 0x01011101, 0x01010001, 0x00111101, // 001ah + 0x00010001, 0x00011001, 0x00110101, 0x00001001, + 0x00000000, 0x01110001, 0x01011101, 0x00110001, // 001bh + 0x00010001, 0x00111001, 0x01010101, 0x00011001, + 0x00000000, 0x01110100, 0x01010011, 0x00110010, // 001ch + 0x00010001, 0x00010001, 0x00001010, 0x00000100, + 0x00000000, 0x01101110, 0x01011000, 0x00100100, // 001dh + 0x00101001, 0x01010001, 0x01010001, 0x00001100, + 0x00000000, 0x01110000, 0x01011100, 0x00110010, // 001eh + 0x00010010, 0x00100001, 0x01000000, 0x00000000, + 0x00000000, 0x01111101, 0x01010001, 0x00111101, // 001fh + 0x00010001, 0x00011001, 0x00110101, 0x00001001, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 0020h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00001000, 0x00001000, 0x00001000, // 0021h + 0x00001000, 0x00001000, 0x00000000, 0x00001000, + 0x00000000, 0x01101100, 0x01001000, 0x00100100, // 0022h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00100100, 0x01111111, 0x00100100, // 0023h + 0x00100100, 0x01111111, 0x00010010, 0x00010010, + 0x00000000, 0x00001000, 0x01111110, 0x00001001, // 0024h + 0x00111110, 0x01001000, 0x00111111, 0x00001000, + 0x00000000, 0x01000010, 0x00100101, 0x00010010, // 0025h + 0x00001000, 0x00100100, 0x01010010, 0x00100001, + 0x00000000, 0x00001110, 0x00010001, 0x00001001, // 0026h + 0x01000110, 0x00101001, 0x00110001, 0x01001110, + 0x00000000, 0x00011000, 0x00010000, 0x00001000, // 0027h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x01110000, 0x00001000, 0x00000100, // 0028h + 0x00000100, 0x00000100, 0x00001000, 0x01110000, + 0x00000000, 0x00000111, 0x00001000, 0x00010000, // 0029h + 0x00010000, 0x00010000, 0x00001000, 0x00000111, + 0x00000000, 0x00001000, 0x01001001, 0x00101010, // 002ah + 0x00011100, 0x00101010, 0x01001001, 0x00001000, + 0x00000000, 0x00001000, 0x00001000, 0x00001000, // 002bh + 0x01111111, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 002ch + 0x00000000, 0x00001100, 0x00001000, 0x00000100, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 002dh + 0x01111111, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 002eh + 0x00000000, 0x00000000, 0x00000000, 0x00001100, + 0x00000000, 0x01000000, 0x00100000, 0x00010000, // 002fh + 0x00001000, 0x00000100, 0x00000010, 0x00000001, + 0x00000000, 0x00111110, 0x01000001, 0x01000001, // 0030h + 0x01000001, 0x01000001, 0x01000001, 0x00111110, + 0x00000000, 0x00011100, 0x00010000, 0x00010000, // 0031h + 0x00010000, 0x00010000, 0x00010000, 0x00010000, + 0x00000000, 0x00111110, 0x01000001, 0x01000000, // 0032h + 0x00111110, 0x00000001, 0x00000001, 0x01111111, + 0x00000000, 0x00111110, 0x01000001, 0x01000000, // 0033h + 0x00111110, 0x01000000, 0x01000001, 0x00111110, + 0x00000000, 0x00100000, 0x00110000, 0x00101000, // 0034h + 0x00100100, 0x00100010, 0x01111111, 0x00100000, + 0x00000000, 0x01111111, 0x00000001, 0x00111111, // 0035h + 0x01000000, 0x01000000, 0x01000001, 0x00111110, + 0x00000000, 0x00111110, 0x00000001, 0x00111111, // 0036h + 0x01000001, 0x01000001, 0x01000001, 0x00111110, + 0x00000000, 0x01111111, 0x00100000, 0x00100000, // 0037h + 0x00010000, 0x00010000, 0x00001000, 0x00001000, + 0x00000000, 0x00111110, 0x01000001, 0x01000001, // 0038h + 0x00111110, 0x01000001, 0x01000001, 0x00111110, + 0x00000000, 0x00111110, 0x01000001, 0x01000001, // 0039h + 0x01000001, 0x01111110, 0x01000000, 0x00111110, + 0x00000000, 0x00000000, 0x00001100, 0x00000000, // 003ah + 0x00000000, 0x00000000, 0x00001100, 0x00000000, + 0x00000000, 0x00000000, 0x00001100, 0x00000000, // 003bh + 0x00000000, 0x00001100, 0x00001000, 0x00000100, + 0x00000000, 0x01100000, 0x00011000, 0x00000110, // 003ch + 0x00000001, 0x00000110, 0x00011000, 0x01100000, + 0x00000000, 0x00000000, 0x01111111, 0x00000000, // 003dh + 0x00000000, 0x00000000, 0x01111111, 0x00000000, + 0x00000000, 0x00000011, 0x00001100, 0x00110000, // 003eh + 0x01000000, 0x00110000, 0x00001100, 0x00000011, + 0x00000000, 0x00111110, 0x01000001, 0x01000001, // 003fh + 0x00110000, 0x00001000, 0x00000000, 0x00001000, + 0x00000000, 0x00011100, 0x00100010, 0x01001001, // 0040h + 0x01010101, 0x01010101, 0x01010101, 0x00111010, + 0x00000000, 0x00001000, 0x00010100, 0x00010100, // 0041h + 0x00100010, 0x00111110, 0x01000001, 0x01000001, + 0x00000000, 0x00111111, 0x01000001, 0x01000001, // 0042h + 0x00111111, 0x01000001, 0x01000001, 0x00111111, + 0x00000000, 0x00111100, 0x01000010, 0x00000001, // 0043h + 0x00000001, 0x00000001, 0x01000010, 0x00111100, + 0x00000000, 0x00011111, 0x00100001, 0x01000001, // 0044h + 0x01000001, 0x01000001, 0x00100001, 0x00011111, + 0x00000000, 0x01111111, 0x00000001, 0x00000001, // 0045h + 0x01111111, 0x00000001, 0x00000001, 0x01111111, + 0x00000000, 0x01111111, 0x00000001, 0x00000001, // 0046h + 0x00111111, 0x00000001, 0x00000001, 0x00000001, + 0x00000000, 0x00111100, 0x01000010, 0x00000001, // 0047h + 0x01111001, 0x01000001, 0x01000010, 0x00111100, + 0x00000000, 0x01000001, 0x01000001, 0x01000001, // 0048h + 0x01111111, 0x01000001, 0x01000001, 0x01000001, + 0x00000000, 0x00111110, 0x00001000, 0x00001000, // 0049h + 0x00001000, 0x00001000, 0x00001000, 0x00111110, + 0x00000000, 0x01000000, 0x01000000, 0x01000000, // 004ah + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x01100001, 0x00011001, 0x00000101, // 004bh + 0x00000011, 0x00000101, 0x00011001, 0x01100001, + 0x00000000, 0x00000001, 0x00000001, 0x00000001, // 004ch + 0x00000001, 0x00000001, 0x00000001, 0x01111111, + 0x00000000, 0x01000001, 0x01100011, 0x01010101, // 004dh + 0x01001001, 0x01000001, 0x01000001, 0x01000001, + 0x00000000, 0x01000001, 0x01000011, 0x01000101, // 004eh + 0x01001001, 0x01010001, 0x01100001, 0x01000001, + 0x00000000, 0x00011100, 0x00100010, 0x01000001, // 004fh + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x00111111, 0x01000001, 0x01000001, // 0050h + 0x00111111, 0x00000001, 0x00000001, 0x00000001, + 0x00000000, 0x00011100, 0x00100010, 0x01000001, // 0051h + 0x01000001, 0x01011001, 0x00100010, 0x01011100, + 0x00000000, 0x00111111, 0x01000001, 0x01000001, // 0052h + 0x00111111, 0x01000001, 0x01000001, 0x01000001, + 0x00000000, 0x00111110, 0x01000001, 0x00000001, // 0053h + 0x00111110, 0x01000000, 0x01000001, 0x00111110, + 0x00000000, 0x01111111, 0x00001000, 0x00001000, // 0054h + 0x00001000, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x01000001, 0x01000001, 0x01000001, // 0055h + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x01000001, 0x01000001, 0x00100010, // 0056h + 0x00100010, 0x00010100, 0x00010100, 0x00001000, + 0x00000000, 0x01000001, 0x01000001, 0x01000001, // 0057h + 0x01001001, 0x01010101, 0x01100011, 0x01000001, + 0x00000000, 0x01000001, 0x00100010, 0x00010100, // 0058h + 0x00001000, 0x00010100, 0x00100010, 0x01000001, + 0x00000000, 0x01000001, 0x00100010, 0x00010100, // 0059h + 0x00001000, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x01111111, 0x00100000, 0x00010000, // 005ah + 0x00001000, 0x00000100, 0x00000010, 0x01111111, + 0x00000000, 0x01111100, 0x00000100, 0x00000100, // 005bh + 0x00000100, 0x00000100, 0x00000100, 0x01111100, + 0x00000000, 0x00100010, 0x00010100, 0x00111110, // 005ch + 0x00001000, 0x00111110, 0x00001000, 0x00001000, + 0x00000000, 0x00011111, 0x00010000, 0x00010000, // 005dh + 0x00010000, 0x00010000, 0x00010000, 0x00011111, + 0x00000000, 0x00001000, 0x00010100, 0x00100010, // 005eh + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 005fh + 0x00000000, 0x00000000, 0x00000000, 0x01111111, + 0x00000000, 0x00010000, 0x00001000, 0x00011000, // 0060h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00011110, 0x00100001, // 0061h + 0x00111110, 0x00100001, 0x00100001, 0x01011110, + 0x00000000, 0x00000001, 0x00000001, 0x00111111, // 0062h + 0x01000001, 0x01000001, 0x01000001, 0x00111111, + 0x00000000, 0x00000000, 0x00111100, 0x01000010, // 0063h + 0x00000001, 0x00000001, 0x01000010, 0x00111100, + 0x00000000, 0x01000000, 0x01000000, 0x01111110, // 0064h + 0x01000001, 0x01000001, 0x01000001, 0x01111110, + 0x00000000, 0x00000000, 0x00111110, 0x01000001, // 0065h + 0x01111111, 0x00000001, 0x01000001, 0x00111110, + 0x00000000, 0x00110000, 0x00001000, 0x00001000, // 0066h + 0x01111111, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x00000000, 0x01111110, 0x01000001, // 0067h + 0x01000001, 0x01111110, 0x01000000, 0x00111110, + 0x00000000, 0x00000001, 0x00000001, 0x00000001, // 0068h + 0x00111111, 0x01000001, 0x01000001, 0x01000001, + 0x00000000, 0x00001000, 0x00000000, 0x00001000, // 0069h + 0x00001000, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x00100000, 0x00000000, 0x00100000, // 006ah + 0x00100000, 0x00100001, 0x00100001, 0x00011110, + 0x00000000, 0x00000001, 0x00000001, 0x01100001, // 006bh + 0x00011001, 0x00000111, 0x00011001, 0x01100001, + 0x00000000, 0x00001000, 0x00001000, 0x00001000, // 006ch + 0x00001000, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x00000000, 0x00110111, 0x01001001, // 006dh + 0x01001001, 0x01001001, 0x01001001, 0x01001001, + 0x00000000, 0x00000000, 0x00111111, 0x01000001, // 006eh + 0x01000001, 0x01000001, 0x01000001, 0x01000001, + 0x00000000, 0x00000000, 0x00011100, 0x00100010, // 006fh + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x00000000, 0x00111101, 0x01000011, // 0070h + 0x01000001, 0x01000011, 0x00111101, 0x00000001, + 0x00000000, 0x00000000, 0x01011110, 0x01100001, // 0071h + 0x01000001, 0x01100001, 0x01011110, 0x01000000, + 0x00000000, 0x00000000, 0x00110001, 0x00001101, // 0072h + 0x00000011, 0x00000001, 0x00000001, 0x00000001, + 0x00000000, 0x00000000, 0x00111110, 0x01000001, // 0073h + 0x00001110, 0x00110000, 0x01000001, 0x00111110, + 0x00000000, 0x00000100, 0x00000100, 0x01111111, // 0074h + 0x00000100, 0x00000100, 0x00000100, 0x01111000, + 0x00000000, 0x00000000, 0x01000001, 0x01000001, // 0075h + 0x01000001, 0x01000001, 0x01000001, 0x01111110, + 0x00000000, 0x00000000, 0x01000001, 0x01000001, // 0076h + 0x00100010, 0x00100010, 0x00010100, 0x00001000, + 0x00000000, 0x00000000, 0x01000001, 0x01000001, // 0077h + 0x01001001, 0x00101010, 0x00101010, 0x00010100, + 0x00000000, 0x00000000, 0x00100001, 0x00010010, // 0078h + 0x00001100, 0x00001100, 0x00010010, 0x00100001, + 0x00000000, 0x00000000, 0x01000001, 0x01000001, // 0079h + 0x00100010, 0x00011100, 0x00001000, 0x00000110, + 0x00000000, 0x00000000, 0x00111111, 0x00010000, // 007ah + 0x00001000, 0x00000100, 0x00000010, 0x00111111, + 0x00000000, 0x00001000, 0x00011110, 0x01100100, // 007bh + 0x00011000, 0x00100100, 0x00000100, 0x01111000, + 0x00000000, 0x00000000, 0x00011110, 0x00000100, // 007ch + 0x00011110, 0x00110101, 0x00101101, 0x00010010, + 0x00000000, 0x00000000, 0x00000000, 0x00010001, // 007dh + 0x00100001, 0x00100001, 0x00000001, 0x00000010, + 0x00000000, 0x00000000, 0x00011100, 0x00000000, // 007eh + 0x00011110, 0x00100000, 0x00100000, 0x00011100, + 0x00000000, 0x00000000, 0x00011100, 0x00000000, // 007fh + 0x00111110, 0x00010000, 0x00001100, 0x00110010, + 0x00000000, 0x00000000, 0x00000100, 0x00101111, // 0080h + 0x01000100, 0x00011110, 0x00100101, 0x00010110, + 0x00000000, 0x00000000, 0x00001010, 0x00011110, // 0081h + 0x00101011, 0x00100010, 0x00010100, 0x00000100, + 0x00000000, 0x00000000, 0x00001000, 0x00011101, // 0082h + 0x00101011, 0x00101001, 0x00011001, 0x00000100, + 0x00000000, 0x00000000, 0x00001000, 0x00111000, // 0083h + 0x00001000, 0x00011110, 0x00101001, 0x00000110, + 0x00000000, 0x00000000, 0x00000000, 0x00011100, // 0084h + 0x00100011, 0x00100000, 0x00100000, 0x00011100, + 0x00000000, 0x00000110, 0x01001001, 0x00110000, // 0085h + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000100, 0x00111111, 0x00000100, // 0086h + 0x00111110, 0x01010101, 0x01001101, 0x00100110, + 0x00000000, 0x00000000, 0x00100001, 0x01000001, // 0087h + 0x01000001, 0x01000001, 0x00000001, 0x00000010, + 0x00000000, 0x00111100, 0x00000000, 0x00111110, // 0088h + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x00011100, 0x00000000, 0x00111110, // 0089h + 0x00010000, 0x00001000, 0x00010100, 0x01100010, + 0x00000000, 0x00100100, 0x01011111, 0x00000100, // 008ah + 0x00111110, 0x01000101, 0x01000101, 0x00100010, + 0x00000000, 0x00100010, 0x01001111, 0x01010010, // 008bh + 0x01010010, 0x00010010, 0x00010010, 0x00001001, + 0x00000000, 0x00000100, 0x00111110, 0x00001000, // 008ch + 0x00111110, 0x00010000, 0x00000010, 0x00111100, + 0x00000000, 0x00100000, 0x00011000, 0x00000110, // 008dh + 0x00000001, 0x00000110, 0x00011000, 0x00100000, + 0x00000000, 0x00100000, 0x01111101, 0x00100001, // 008eh + 0x00100001, 0x00100001, 0x00100001, 0x00010010, + 0x00000000, 0x00011110, 0x00100000, 0x00000000, // 008fh + 0x00000000, 0x00000001, 0x00000001, 0x00111110, + 0x00000000, 0x00001000, 0x01111111, 0x00010000, // 0090h + 0x00100000, 0x00000010, 0x00000010, 0x00111100, + 0x00000000, 0x00000001, 0x00000001, 0x00000001, // 0091h + 0x01000001, 0x01000001, 0x00100010, 0x00011100, + 0x00000000, 0x00010000, 0x01111111, 0x00011000, // 0092h + 0x00010100, 0x00010100, 0x00011000, 0x00001100, + 0x00000000, 0x00100010, 0x01111111, 0x00100010, // 0093h + 0x00100010, 0x00000010, 0x00000010, 0x01111100, + 0x00000000, 0x00111100, 0x00010000, 0x00001100, // 0094h + 0x01111111, 0x00001000, 0x00001000, 0x00110000, + 0x00000000, 0x00000100, 0x00011111, 0x00000100, // 0095h + 0x01110100, 0x00000010, 0x00001010, 0x01110010, + 0x00000000, 0x00001000, 0x01111111, 0x00000100, // 0096h + 0x00111100, 0x01000010, 0x01000000, 0x00111100, + 0x00000000, 0x00000000, 0x00011100, 0x00100011, // 0097h + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x01111111, 0x00010000, 0x00001000, // 0098h + 0x00001000, 0x00001000, 0x00001000, 0x00110000, + 0x00000000, 0x00000010, 0x00110010, 0x00001100, // 0099h + 0x00000010, 0x00000001, 0x00000001, 0x00111110, + 0x00000000, 0x00100100, 0x01001111, 0x01000010, // 009ah + 0x00010001, 0x00111100, 0x00010010, 0x00001100, + 0x00000000, 0x00000010, 0x01111010, 0x01000010, // 009bh + 0x00000010, 0x00000010, 0x00001010, 0x01110010, + 0x00000000, 0x00100010, 0x00111110, 0x01010010, // 009ch + 0x01001011, 0x01101101, 0x01010101, 0x00110010, + 0x00000000, 0x00110010, 0x01001011, 0x01000110, // 009dh + 0x01000110, 0x01110010, 0x01001011, 0x00110010, + 0x00000000, 0x00011100, 0x00101010, 0x01001001, // 009eh + 0x01001001, 0x01000101, 0x01000101, 0x00110010, + 0x00000000, 0x00100001, 0x01111101, 0x00100001, // 009fh + 0x00100001, 0x00111001, 0x01100101, 0x00011001, + 0x00000000, 0x00000100, 0x00100011, 0x01100010, // 00a0h + 0x00100001, 0x00100001, 0x00010010, 0x00001100, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00a1h + 0x00000000, 0x00000100, 0x00001010, 0x00000100, + 0x00000000, 0x01110000, 0x00010000, 0x00010000, // 00a2h + 0x00010000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00a3h + 0x00001000, 0x00001000, 0x00001000, 0x00001110, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00a4h + 0x00000000, 0x00000010, 0x00000100, 0x00000100, + 0x00000000, 0x00000000, 0x00000000, 0x00011000, // 00a5h + 0x00011000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x01111111, 0x01000000, 0x01111111, // 00a6h + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x00000000, 0x00111111, 0x00100000, // 00a7h + 0x00010100, 0x00001100, 0x00000100, 0x00000010, + 0x00000000, 0x00000000, 0x00100000, 0x00100000, // 00a8h + 0x00010000, 0x00001111, 0x00001000, 0x00001000, + 0x00000000, 0x00000000, 0x00000100, 0x00111111, // 00a9h + 0x00100001, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x00000000, 0x00000000, 0x00111110, // 00aah + 0x00001000, 0x00001000, 0x00001000, 0x01111111, + 0x00000000, 0x00000000, 0x00010000, 0x00111111, // 00abh + 0x00011000, 0x00010100, 0x00010010, 0x00011001, + 0x00000000, 0x00000000, 0x00000010, 0x00111111, // 00ach + 0x00100010, 0x00010010, 0x00000100, 0x00000100, + 0x00000000, 0x00000000, 0x00000000, 0x00111110, // 00adh + 0x00100000, 0x00100000, 0x00100000, 0x01111111, + 0x00000000, 0x00000000, 0x00111110, 0x00100000, // 00aeh + 0x00111110, 0x00100000, 0x00100000, 0x00111110, + 0x00000000, 0x00000000, 0x00100101, 0x00101010, // 00afh + 0x00101010, 0x00100000, 0x00010000, 0x00001110, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00b0h + 0x01111111, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x01111111, 0x01000000, 0x00101000, // 00b1h + 0x00011000, 0x00001000, 0x00001000, 0x00000100, + 0x00000000, 0x01000000, 0x00100000, 0x00011000, // 00b2h + 0x00010111, 0x00010000, 0x00010000, 0x00010000, + 0x00000000, 0x00001000, 0x01111111, 0x01000001, // 00b3h + 0x01000001, 0x01000000, 0x00100000, 0x00011000, + 0x00000000, 0x00000000, 0x00111110, 0x00001000, // 00b4h + 0x00001000, 0x00001000, 0x00001000, 0x01111111, + 0x00000000, 0x00100000, 0x01111111, 0x00110000, // 00b5h + 0x00101000, 0x00100100, 0x00100010, 0x00110001, + 0x00000000, 0x00000100, 0x01111111, 0x01000100, // 00b6h + 0x01000100, 0x01000100, 0x01000010, 0x00100001, + 0x00000000, 0x00000100, 0x00111111, 0x00001000, // 00b7h + 0x01111111, 0x00010000, 0x00010000, 0x00010000, + 0x00000000, 0x01111100, 0x01000100, 0x01000100, // 00b8h + 0x01000010, 0x01000000, 0x00100000, 0x00011000, + 0x00000000, 0x00000010, 0x01111110, 0x00100010, // 00b9h + 0x00100001, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x01111110, 0x01000000, 0x01000000, // 00bah + 0x01000000, 0x01000000, 0x01000000, 0x01111110, + 0x00000000, 0x00100010, 0x01111111, 0x00100010, // 00bbh + 0x00100010, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x00000011, 0x00000100, 0x01000011, // 00bch + 0x01000100, 0x00100000, 0x00011000, 0x00000111, + 0x00000000, 0x01111111, 0x01000000, 0x00100000, // 00bdh + 0x00010000, 0x00011000, 0x00100100, 0x01000011, + 0x00000000, 0x00000010, 0x01111111, 0x01000010, // 00beh + 0x00100010, 0x00000010, 0x00000010, 0x01111100, + 0x00000000, 0x01000001, 0x01000010, 0x01000000, // 00bfh + 0x00100000, 0x00100000, 0x00011000, 0x00000110, + 0x00000000, 0x01111110, 0x01000010, 0x01001110, // 00c0h + 0x01110001, 0x01000000, 0x00100000, 0x00011000, + 0x00000000, 0x01100000, 0x00011110, 0x00010000, // 00c1h + 0x01111111, 0x00010000, 0x00010000, 0x00001100, + 0x00000000, 0x01000101, 0x01001010, 0x01001010, // 00c2h + 0x01000000, 0x00100000, 0x00010000, 0x00001110, + 0x00000000, 0x00111110, 0x00000000, 0x01111111, // 00c3h + 0x00010000, 0x00010000, 0x00001000, 0x00000110, + 0x00000000, 0x00000010, 0x00000010, 0x00000110, // 00c4h + 0x00011010, 0x01100010, 0x00000010, 0x00000010, + 0x00000000, 0x00010000, 0x00010000, 0x01111111, // 00c5h + 0x00010000, 0x00010000, 0x00001000, 0x00000110, + 0x00000000, 0x00000000, 0x00111110, 0x00000000, // 00c6h + 0x00000000, 0x00000000, 0x00000000, 0x01111111, + 0x00000000, 0x01111110, 0x01000000, 0x01000100, // 00c7h + 0x00101000, 0x00010000, 0x00101000, 0x01000110, + 0x00000000, 0x00001000, 0x01111111, 0x00100000, // 00c8h + 0x00010000, 0x00011100, 0x01101011, 0x00001000, + 0x00000000, 0x01000000, 0x01000000, 0x01000000, // 00c9h + 0x00100000, 0x00100000, 0x00011000, 0x00000111, + 0x00000000, 0x00010010, 0x00100010, 0x00100010, // 00cah + 0x01000010, 0x01000010, 0x01000001, 0x01000001, + 0x00000000, 0x00000001, 0x00000001, 0x01111111, // 00cbh + 0x00000001, 0x00000001, 0x00000001, 0x01111110, + 0x00000000, 0x01111111, 0x01000000, 0x01000000, // 00cch + 0x01000000, 0x00100000, 0x00010000, 0x00001110, + 0x00000000, 0x00000000, 0x00000100, 0x00001010, // 00cdh + 0x00010001, 0x00100001, 0x01000000, 0x00000000, + 0x00000000, 0x00001000, 0x00001000, 0x01111111, // 00ceh + 0x00001000, 0x00101010, 0x01001010, 0x01001001, + 0x00000000, 0x01111111, 0x01000000, 0x01000000, // 00cfh + 0x00100010, 0x00010100, 0x00001000, 0x00010000, + 0x00000000, 0x00001110, 0x01110000, 0x00001110, // 00d0h + 0x01110000, 0x00000110, 0x00011000, 0x01100000, + 0x00000000, 0x00001000, 0x00001000, 0x00000100, // 00d1h + 0x00000100, 0x00100010, 0x01000010, 0x01111111, + 0x00000000, 0x01000000, 0x01000000, 0x00100100, // 00d2h + 0x00101000, 0x00010000, 0x00101100, 0x01000011, + 0x00000000, 0x01111111, 0x00000100, 0x01111111, // 00d3h + 0x00000100, 0x00000100, 0x00000100, 0x01111000, + 0x00000000, 0x00000010, 0x01111111, 0x01000010, // 00d4h + 0x00100010, 0x00010100, 0x00000100, 0x00000100, + 0x00000000, 0x00000000, 0x00111110, 0x00100000, // 00d5h + 0x00100000, 0x00100000, 0x00100000, 0x01111111, + 0x00000000, 0x01111110, 0x01000000, 0x01000000, // 00d6h + 0x01111110, 0x01000000, 0x01000000, 0x01111110, + 0x00000000, 0x00111110, 0x00000000, 0x01111111, // 00d7h + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x01000010, 0x01000010, 0x01000010, // 00d8h + 0x01000010, 0x01000000, 0x00100000, 0x00011000, + 0x00000000, 0x00001010, 0x00001010, 0x00001010, // 00d9h + 0x01001010, 0x01001010, 0x00101010, 0x00011001, + 0x00000000, 0x00000010, 0x00000010, 0x01000010, // 00dah + 0x01000010, 0x00100010, 0x00010010, 0x00001110, + 0x00000000, 0x01111111, 0x01000001, 0x01000001, // 00dbh + 0x01000001, 0x01000001, 0x01000001, 0x01111111, + 0x00000000, 0x01111111, 0x01000001, 0x01000001, // 00dch + 0x01000000, 0x01000000, 0x00100000, 0x00011100, + 0x00000000, 0x01000011, 0x01000100, 0x01000000, // 00ddh + 0x01000000, 0x00100000, 0x00010000, 0x00001111, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00deh + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // 00dfh + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00011110, 0x00001000, 0x00000100, // 00e0h + 0x00101001, 0x01010001, 0x01010001, 0x00001100, + 0x00000000, 0x00000000, 0x00001100, 0x00010010, // 00e1h + 0x00010010, 0x00100001, 0x01000000, 0x00000000, + 0x00000000, 0x01111101, 0x00100001, 0x01111101, // 00e2h + 0x00100001, 0x00111001, 0x01100101, 0x00011001, + 0x00000000, 0x00111100, 0x00010000, 0x00111100, // 00e3h + 0x00010000, 0x00011100, 0x00110010, 0x00001100, + 0x00000000, 0x00001110, 0x00101000, 0x00101000, // 00e4h + 0x00111110, 0x01100101, 0x00100101, 0x00010010, + 0x00000000, 0x00000100, 0x00101111, 0x01000100, // 00e5h + 0x00000110, 0x01000101, 0x01000101, 0x00111110, + 0x00000000, 0x00100010, 0x00100010, 0x00111110, // 00e6h + 0x01010010, 0x01010101, 0x01001101, 0x00100110, + 0x00000000, 0x00000100, 0x00011111, 0x00000010, // 00e7h + 0x00011111, 0x01000010, 0x01000010, 0x00111100, + 0x00000000, 0x00010010, 0x00111110, 0x01010011, // 00e8h + 0x01000010, 0x00100100, 0x00000100, 0x00000100, + 0x00000000, 0x00001000, 0x00111101, 0x01001011, // 00e9h + 0x01001001, 0x01001001, 0x00111000, 0x00000100, + 0x00000000, 0x00001000, 0x00111000, 0x00001000, // 00eah + 0x00001000, 0x00011110, 0x00101001, 0x00000110, + 0x00000000, 0x00011000, 0x00100000, 0x00000100, // 00ebh + 0x00111010, 0x01000110, 0x01000000, 0x00111000, + 0x00000000, 0x01000010, 0x01000010, 0x01000010, // 00ech + 0x01000110, 0x01000000, 0x00100000, 0x00011000, + 0x00000000, 0x00111110, 0x00010000, 0x00111100, // 00edh + 0x01000011, 0x01001100, 0x01010010, 0x00111100, + 0x00000000, 0x00100010, 0x00110011, 0x00101010, // 00eeh + 0x00100110, 0x00100010, 0x00100011, 0x01000010, + 0x00000000, 0x00111110, 0x00010000, 0x00111100, // 00efh + 0x01000011, 0x01000000, 0x01000010, 0x00111100, + 0x00000000, 0x00000010, 0x00111011, 0x01000110, // 00f0h + 0x01000010, 0x01000011, 0x01000010, 0x00110010, + 0x00000000, 0x00000100, 0x00000100, 0x00000010, // 00f1h + 0x01000110, 0x01000101, 0x01000101, 0x00111001, + 0x00000000, 0x01010100, 0x01111111, 0x00100100, // 00f2h + 0x00100100, 0x00100100, 0x00100010, 0x00010001, + 0x00000000, 0x01010100, 0x01011111, 0x00000100, // 00f3h + 0x00111111, 0x00001000, 0x00001000, 0x00001000, + 0x00000000, 0x01011110, 0x01100010, 0x00100010, // 00f4h + 0x00100001, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x01010010, 0x01111110, 0x00100010, // 00f5h + 0x00100001, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x01010000, 0x01111111, 0x00100000, // 00f6h + 0x00100000, 0x00100000, 0x00100000, 0x00111111, + 0x00000000, 0x01010010, 0x01010010, 0x00111111, // 00f7h + 0x00010010, 0x00010000, 0x00010000, 0x00001100, + 0x00000000, 0x01010011, 0x01010100, 0x00100011, // 00f8h + 0x00100100, 0x00010000, 0x00001000, 0x00000111, + 0x00000000, 0x01010000, 0x01011111, 0x00010000, // 00f9h + 0x00001000, 0x00001100, 0x00010010, 0x00100001, + 0x00000000, 0x01010010, 0x01111111, 0x00100010, // 00fah + 0x00010010, 0x00000010, 0x00000010, 0x00111100, + 0x00000000, 0x01010001, 0x01010010, 0x00100000, // 00fbh + 0x00100000, 0x00010000, 0x00001000, 0x00000110, + 0x00000000, 0x01011110, 0x01010010, 0x00100110, // 00fch + 0x00111001, 0x00100000, 0x00010000, 0x00001100, + 0x00000000, 0x01010000, 0x01011110, 0x00010000, // 00fdh + 0x01111111, 0x00010000, 0x00010000, 0x00001100, + 0x00000000, 0x00100101, 0x01001010, 0x00101010, // 00feh + 0x00100000, 0x00010000, 0x00001000, 0x00000111, + 0x00000000, 0x01011110, 0x01010000, 0x00111111, // 00ffh + 0x00001000, 0x00001000, 0x00001000, 0x00000110 +}; + + +/*---------------------------------------------------------------------------* + Palette data + *---------------------------------------------------------------------------*/ +const u32 d_PaletteData[8 * 16] = { + 0x00000000, 0x00000000, 0x00000000, 0x00000000, // black + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x001f0000, 0x00000000, 0x00000000, 0x00000000, // red + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x03e00000, 0x00000000, 0x00000000, 0x00000000, // green + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x7c000000, 0x00000000, 0x00000000, 0x00000000, // blue + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x03ff0000, 0x00000000, 0x00000000, 0x00000000, // yellow + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x7c1f0000, 0x00000000, 0x00000000, 0x00000000, // purple + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x7fe00000, 0x00000000, 0x00000000, 0x00000000, // light blue + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00180000, 0x00000000, 0x00000000, 0x00000000, // dark red + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x03000000, 0x00000000, 0x00000000, 0x00000000, // dark green + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x60000000, 0x00000000, 0x00000000, 0x00000000, // dark blue + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x03180000, 0x00000000, 0x00000000, 0x00000000, // dark yellow + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x60180000, 0x00000000, 0x00000000, 0x00000000, // dark purple + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x63000000, 0x00000000, 0x00000000, 0x00000000, // dark light blue + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x56b50000, 0x00000000, 0x00000000, 0x00000000, // gray + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x2d6b0000, 0x00000000, 0x00000000, 0x00000000, // dark gray + 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x7fff0000, 0x00000000, 0x00000000, 0x00000000, // white + 0x00000000, 0x00000000, 0x00000000, 0x00000000 +}; + +/*---------------------------------------------------------------------------* + End of file + *---------------------------------------------------------------------------*/ diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/include/font.h b/build/gcdfirm/gcdfirm-disp/ARM9/include/font.h new file mode 100644 index 00000000..30d49e95 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/include/font.h @@ -0,0 +1,60 @@ +/*---------------------------------------------------------------------------* + Project: NitroSDK - SPI - demos - pm-1 + File: font.h + + Copyright 2003-2005 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: font.h,v $ + Revision 1.2 2005/02/28 05:26:12 yosizaki + do-indent. + + Revision 1.1 2004/08/07 01:59:51 yada + modified much + + $NoKeywords: $ + *---------------------------------------------------------------------------*/ + +#ifndef FONT_H_ +#define FONT_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +/*===========================================================================*/ + +#include + +typedef enum +{ + FONT_BLOCK = 0, + FONT_RED = 1, + FONT_GREEN = 2, + FONT_BLUE = 3, + FONT_YELLOW = 4, + FONT_PURPLE = 5, + FONT_CYAAN = 6, + FONT_WHITE = 15 +} +MYFontColor; + +extern const u32 d_CharData[8 * 256]; +extern const u32 d_PaletteData[8 * 16]; + +/*===========================================================================*/ + +#ifdef __cplusplus +} /* extern "C" */ +#endif + +#endif /* FONT_H_ */ + +/*---------------------------------------------------------------------------* + End of file + *---------------------------------------------------------------------------*/ diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/include/screen.h b/build/gcdfirm/gcdfirm-disp/ARM9/include/screen.h new file mode 100644 index 00000000..81ed6790 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/include/screen.h @@ -0,0 +1,52 @@ +/*---------------------------------------------------------------------------* + Project: NitroSDK - SPI - demos - pm-1 + File: screen.h + + Copyright 2003-2006 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: screen.h,v $ + Revision 1.3 2006/01/18 02:12:28 kitase_hirotake + do-indent + + Revision 1.2 2005/02/28 05:26:12 yosizaki + do-indent. + + Revision 1.1 2004/08/07 01:59:51 yada + modified much + + $NoKeywords: $ + *---------------------------------------------------------------------------*/ + +#ifndef SCREEN_H_ +#define SCREEN_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +/*===========================================================================*/ +#include + +extern u16 gScreen[32 * 32]; + +void ClearScreen(void); +void PrintString(s16 x, s16 y, u8 palette, char *text, ...); +void ColorString(s16 x, s16 y, s16 length, u8 palette); + +/*===========================================================================*/ + +#ifdef __cplusplus +} /* extern "C" */ +#endif + +#endif /* SCREEN_H_ */ + +/*---------------------------------------------------------------------------* + End of file + *---------------------------------------------------------------------------*/ diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/main.c b/build/gcdfirm/gcdfirm-disp/ARM9/main.c new file mode 100644 index 00000000..fb48c3d9 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/main.c @@ -0,0 +1,150 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - ts_dev9 + File: main.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: $ + $NoKeywords: $ + *---------------------------------------------------------------------------*/ +#include +#include "font.h" +#include "screen.h" +//#include + +//#define PRINT_DEBUG + +#ifndef PRINT_DEBUG +#undef OS_TPrintf +#define OS_TPrintf(...) ((void)0) +#endif // PRINT_DEBUG + +static void myInit(void); +static void myVBlankIntr(void); + +void TwlMain( void ) +{ + s16 x = 2, y = 2; + + OS_TPrintf( "\nGCD Boot time is %d msec.\n", OS_TicksToMilliSecondsBROM32(OS_GetTick())); + + MIi_CpuClearFast( 0, (void*)OSi_GetFromBromAddr(), sizeof(OSFromBromBuf) ); + + myInit(); + + OS_TPrintf( "\nARM9 starts.\n" ); + + //---- clear screen buffer + ClearScreen(); + + PrintString( x, y, FONT_CYAAN, "Gcdfirm-Disp" ); + PrintString( (s16)(x+17), y++, FONT_WHITE, "%s", __DATE__ ); + PrintString( (s16)(x+20), y++, FONT_WHITE, "%s", __TIME__ ); + y++; + + PrintString( x, y++, FONT_YELLOW, "Hello!"); + + OS_TPrintf( "\nARM9 ends.\n" ); + + OS_WaitVBlankIntr(); + + OS_Terminate(); +} + +//---------------------------------------------------------------- +// myInit +// +void myInit(void) +{ + //---- init + OS_InitFIRM(); + OS_InitTick(); + OS_InitAlarm(); + FX_Init(); + GX_Init(); + GX_DispOff(); + GXS_DispOff(); + + //---- init displaying + GX_SetBankForLCDC(GX_VRAM_LCDC_ALL); + MI_CpuClearFast((void *)HW_LCDC_VRAM, HW_LCDC_VRAM_SIZE); + (void)GX_DisableBankForLCDC(); + + MI_CpuFillFast((void *)HW_OAM, 192, HW_OAM_SIZE); + MI_CpuClearFast((void *)HW_PLTT, HW_PLTT_SIZE); + MI_CpuFillFast((void *)HW_DB_OAM, 192, HW_DB_OAM_SIZE); + MI_CpuClearFast((void *)HW_DB_PLTT, HW_DB_PLTT_SIZE); + + //---- setting 2D for top screen + GX_SetBankForBG(GX_VRAM_BG_128_A); + + G2_SetBG0Control(GX_BG_SCRSIZE_TEXT_256x256, + GX_BG_COLORMODE_16, + GX_BG_SCRBASE_0xf800, GX_BG_CHARBASE_0x00000, GX_BG_EXTPLTT_01); + G2_SetBG0Priority(0); + G2_BG0Mosaic(FALSE); + GX_SetGraphicsMode(GX_DISPMODE_GRAPHICS, GX_BGMODE_0, GX_BG0_AS_2D); + GX_SetVisiblePlane(GX_PLANEMASK_BG0); + + GX_LoadBG0Char(d_CharData, 0, sizeof(d_CharData)); + GX_LoadBGPltt(d_PaletteData, 0, sizeof(d_PaletteData)); + + + + //---- setting 2D for bottom screen + GX_SetBankForSubBG(GX_VRAM_SUB_BG_128_C); + + G2S_SetBG0Control(GX_BG_SCRSIZE_TEXT_256x256, + GX_BG_COLORMODE_16, + GX_BG_SCRBASE_0xf800, GX_BG_CHARBASE_0x00000, GX_BG_EXTPLTT_01); + G2S_SetBG0Priority(0); + G2S_BG0Mosaic(FALSE); + GXS_SetGraphicsMode(GX_BGMODE_0); + GXS_SetVisiblePlane(GX_PLANEMASK_BG0); + + GXS_LoadBG0Char(d_CharData, 0, sizeof(d_CharData)); + GXS_LoadBGPltt(d_PaletteData, 0, sizeof(d_PaletteData)); + + + //---- screen + MI_CpuFillFast((void *)gScreen, 0, sizeof(gScreen)); + DC_FlushRange(gScreen, sizeof(gScreen)); + /* DMA操作でIOレジスタへアクセスするのでキャッシュの Wait は不要 */ + // DC_WaitWriteBufferEmpty(); + GX_LoadBG0Scr(gScreen, 0, sizeof(gScreen)); + GXS_LoadBG0Scr(gScreen, 0, sizeof(gScreen)); + + //---- init interrupt + OS_SetIrqFunction(OS_IE_V_BLANK, myVBlankIntr); + (void)OS_EnableIrqMask(OS_IE_V_BLANK); + (void)GX_VBlankIntr(TRUE); + (void)OS_EnableIrq(); + (void)OS_EnableInterrupts(); + + //---- start displaying + GX_DispOn(); + GXS_DispOn(); +} + +//---------------------------------------------------------------- +// myVBlankIntr +// vblank interrupt handler +// +static void myVBlankIntr(void) +{ + //---- upload pseudo screen to VRAM + DC_FlushRange(gScreen, sizeof(gScreen)); + /* DMA操作でIOレジスタへアクセスするのでキャッシュの Wait は不要 */ + // DC_WaitWriteBufferEmpty(); + GX_LoadBG0Scr(gScreen, 0, sizeof(gScreen)); + GXS_LoadBG0Scr(gScreen, 0, sizeof(gScreen)); + + OS_SetIrqCheckFlag(OS_IE_V_BLANK); +} + diff --git a/build/gcdfirm/gcdfirm-disp/ARM9/screen.c b/build/gcdfirm/gcdfirm-disp/ARM9/screen.c new file mode 100644 index 00000000..8e20145a --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/ARM9/screen.c @@ -0,0 +1,120 @@ +/*---------------------------------------------------------------------------* + Project: NitroSDK - SPI - demos - pm-1 + File: screen.c + + Copyright 2003-2006 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Log: screen.c,v $ + Revision 1.3 2006/01/18 02:12:28 kitase_hirotake + do-indent + + Revision 1.2 2005/02/28 05:26:12 yosizaki + do-indent. + + Revision 1.1 2004/08/07 01:59:51 yada + modified much + + $NoKeywords: $ + *---------------------------------------------------------------------------*/ +#include +#include "screen.h" + +u16 gScreen[32 * 32]; +//u16 gScreen2[ 32 * 32 ]; + +// ** these code are refer to rtc sample. thanks. +/*---------------------------------------------------------------------------* + Name: ClearScreen + + Description: clear screen buffer + + Arguments: None. + + Returns: None. + *---------------------------------------------------------------------------*/ +void ClearScreen(void) +{ + MI_CpuClearFast((void *)gScreen, sizeof(gScreen)); +} + +/*---------------------------------------------------------------------------* + Name: PrintString + + Description: enter string into screen buffer + string must be within 32 chars + + Arguments: x : x + y : y + palette : color (0-15) + text : string. end mark is NULL + + Returns: None. + *---------------------------------------------------------------------------*/ +void PrintString(s16 x, s16 y, u8 palette, char *text, ...) +{ + va_list vlist; + char temp[32 + 2], *tempPtr; + s32 i; + u16 *p, *pLimit; + + va_start(vlist, text); + (void)vsnprintf(temp, 33, text, vlist); + va_end(vlist); + + *(u16 *)(&temp[32]) = 0; + p = &gScreen[((y * 32) + x) % (32 * 32)]; + pLimit = &gScreen[32 * 32]; + tempPtr = &temp[0]; + + for (i = 0; *tempPtr; i++, tempPtr++) + { + *p = (u16)((palette << 12) | *tempPtr); + if (++p >= pLimit) + { + p = &gScreen[0]; + } + } +} + +/*---------------------------------------------------------------------------* + Name: ColorString + + Description: change string color which is put in screen buffer + + Arguments: x : x + y : y + length : number of characters to change color + palette : color (0-15) + + Returns: None. + *---------------------------------------------------------------------------*/ +void ColorString(s16 x, s16 y, s16 length, u8 palette) +{ + s32 i; + u16 *p, *pLimit; + + if (length < 0) + return; + + p = &gScreen[((y * 32) + x) % (32 * 32)]; + pLimit = &gScreen[32 * 32]; + + for (i = 0; i < length; i++) + { + u16 temp = *p; + temp &= 0x0fff; + temp |= (palette << 12); + *p = temp; + + if (++p >= pLimit) + { + p = &gScreen[0]; + } + } +} diff --git a/build/gcdfirm/gcdfirm-disp/Makefile b/build/gcdfirm/gcdfirm-disp/Makefile new file mode 100644 index 00000000..9aa71c02 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/Makefile @@ -0,0 +1,52 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - nandfirm - gcdfirm-disp +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + + +# if you have valid keys, set environment value like below +#export TWL_KEYSDIR='$(FIRM_ROOT)/../twl_firmware/bootrom/build/keys' + + +#---------------------------------------------------------------------------- + +SUBDIRS = \ + wram_regs \ + ARM7 \ + ARM9 \ + +TARGET_FIRM_BIN = gcdfirm_disp-$(TWL_BUILD_TYPE)$(CODEGEN_ARCH).gcd +BINDIR = . +MAKEFIRM_ARM9 = ARM9/bin/$(TWL_BUILDTYPE_ARM9)/gcdfirm_disp9.tef +MAKEFIRM_ARM7 = ARM7/bin/$(TWL_BUILDTYPE_ARM7)/gcdfirm_disp7.tef +MAKEFIRM_RSA_PRVKEY = $(TWL_KEYSDIR)/rsa/private_gcd.der +LDEPENDS_BIN += wram_regs/wram_regs.rbin + +MAKEFIRM_FLAGS += -p +FIRM_SPEC = gcdfirm.gcdsf + +LDIRT_CLEAN += $(TARGETS) \ + rsa_public.sbin \ + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build: $(TARGET_BIN) + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-disp/gcdfirm.gcdsf b/build/gcdfirm/gcdfirm-disp/gcdfirm.gcdsf new file mode 100644 index 00000000..b5a9fa74 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/gcdfirm.gcdsf @@ -0,0 +1,21 @@ +#GCDSF --- Gcdfirm Spec File + +VERSION : 0x0 # GENERATE + +RSA_KEY : $(MAKEFIRM_RSA_PRVKEY) +OUT_KEY : rsa_public.sbin + +WRAM_RBIN : ./wram_regs/wram_regs.rbin + +ARM9_COMP : FALSE # TRUE or FALSE, should be before ARM9_SBIN +ARM9_SBIN : $(MAKEFIRM_ARM9).TWL.FLX.sbin +ARM9_ELF : $(MAKEFIRM_ARM9).tef + +ARM7_COMP : FALSE # TRUE or FALSE, should be before ARM7_SBIN +ARM7_SBIN : $(MAKEFIRM_ARM7).TWL.FLX.sbin +ARM7_ELF : $(MAKEFIRM_ARM7).tef + +ARM9_X2 : TRUE # TRUE or FALSE + +#NORFIRM : $(NORFIRM_BIN) +#NANDFIRM : $(NANDFIRM_BIN) diff --git a/build/gcdfirm/gcdfirm-disp/wram_regs/Makefile b/build/gcdfirm/gcdfirm-disp/wram_regs/Makefile new file mode 100644 index 00000000..66504d9a --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/wram_regs/Makefile @@ -0,0 +1,57 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - nandfirm - menu-launcher +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +override TARGET_PLATFORM := TWL +override TARGET_CODEGEN := ARM +override TWL_ARCHGEN := LIMITED + +override TARGET_FINALROM := TRUE +override TARGET_RELEASE := +override TARGET_DEBUG := + +SUBDIRS = + +LINCLUDES = ../include + + +#---------------------------------------------------------------------------- + +TARGET_BIN = wram_regs.rbin + +SRCS = \ + wram_regs.c \ + +#SRCDIR = # using default +#LCFILE = # using default + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +INSTALL_DIR = . +INSTALL_TARGETS = $(BINDIR)/$(TARGET_BIN) + + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-disp/wram_regs/wram_regs.c b/build/gcdfirm/gcdfirm-disp/wram_regs/wram_regs.c new file mode 100644 index 00000000..f03e0e14 --- /dev/null +++ b/build/gcdfirm/gcdfirm-disp/wram_regs/wram_regs.c @@ -0,0 +1,91 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - nandfirm + File: wram_regs.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: 2007-11-12#$ + $Rev: 149 $ + $Author: yutaka $ + *---------------------------------------------------------------------------*/ +#include +#include + +MIHeader_WramRegs wram_regs_init = +{ + // ARM9 + { + REG_MI_MBK_A0_FIELD( 1, MI_WRAM_A_OFFSET_0KB , MI_WRAM_ARM9 ), + REG_MI_MBK_A1_FIELD( 1, MI_WRAM_A_OFFSET_64KB , MI_WRAM_ARM9 ), + REG_MI_MBK_A2_FIELD( 1, MI_WRAM_A_OFFSET_128KB, MI_WRAM_ARM9 ), + REG_MI_MBK_A3_FIELD( 1, MI_WRAM_A_OFFSET_192KB, MI_WRAM_ARM9 ), + }, + { + REG_MI_MBK_B0_FIELD( 1, MI_WRAM_BC_OFFSET_0KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B1_FIELD( 1, MI_WRAM_BC_OFFSET_32KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B2_FIELD( 1, MI_WRAM_BC_OFFSET_64KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B3_FIELD( 1, MI_WRAM_BC_OFFSET_96KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B4_FIELD( 1, MI_WRAM_BC_OFFSET_128KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B5_FIELD( 1, MI_WRAM_BC_OFFSET_160KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B6_FIELD( 1, MI_WRAM_BC_OFFSET_192KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B7_FIELD( 1, MI_WRAM_BC_OFFSET_224KB, MI_WRAM_ARM7 ), + }, + { + REG_MI_MBK_C0_FIELD( 1, MI_WRAM_BC_OFFSET_0KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C1_FIELD( 1, MI_WRAM_BC_OFFSET_32KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C2_FIELD( 1, MI_WRAM_BC_OFFSET_64KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C3_FIELD( 1, MI_WRAM_BC_OFFSET_96KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C4_FIELD( 1, MI_WRAM_BC_OFFSET_128KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C5_FIELD( 1, MI_WRAM_BC_OFFSET_160KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C6_FIELD( 1, MI_WRAM_BC_OFFSET_192KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C7_FIELD( 1, MI_WRAM_BC_OFFSET_224KB, MI_WRAM_ARM7 ), + }, + REG_MI_MBK6_FIELD( REG_WRAM_MAP_CONV_ADDR( 6, A, EADDR, HW_WRAM_AREA_HALF ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 6, A, SADDR, HW_WRAM_AREA_HALF - HW_WRAM_A_SIZE ) + ), + REG_MI_MBK7_FIELD( REG_WRAM_MAP_CONV_ADDR( 7, B, EADDR, HW_WRAM_AREA + HW_WRAM_B_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 7, B, SADDR, HW_WRAM_AREA ) + ), + REG_MI_MBK8_FIELD( REG_WRAM_MAP_CONV_ADDR( 8, C, EADDR, MI_WRAM_MAP_NULL ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 8, C, SADDR, MI_WRAM_MAP_NULL ) + ), + + // ARM7 + REG_MI_MBK6_FIELD( REG_WRAM_MAP_CONV_ADDR( 6, A, EADDR, MI_WRAM_MAP_NULL ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 6, A, SADDR, MI_WRAM_MAP_NULL ) + ), + REG_MI_MBK7_FIELD( REG_WRAM_MAP_CONV_ADDR( 7, B, EADDR, HW_WRAM_AREA + HW_WRAM_B_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 7, B, SADDR, HW_WRAM_AREA ) + ), + REG_MI_MBK8_FIELD( REG_WRAM_MAP_CONV_ADDR( 8, C, EADDR, HW_WRAM_AREA_HALF - HW_WRAM_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 8, C, SADDR, HW_WRAM_AREA_HALF - HW_WRAM_SIZE - HW_WRAM_C_SIZE ) + ), + + // WRAM Lock + { + 0, + 0, + 0, + }, + + // WRAM-0/1 + 3, + + // VRAM-C + 7, + // VRAM-D + 7, +}; + diff --git a/build/gcdfirm/gcdfirm-print/Makefile b/build/gcdfirm/gcdfirm-print/Makefile new file mode 100644 index 00000000..b6e8206f --- /dev/null +++ b/build/gcdfirm/gcdfirm-print/Makefile @@ -0,0 +1,46 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - build +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + + +#---------------------------------------------------------------------------- + +SUBDIRS = ../../norfirm/norfirm-print + +TARGET_FIRM_BIN = gcdfirm_print-$(TWL_BUILD_TYPE).gcd +BINDIR = . +MAKEFIRM_ARM9 = ../../norfirm/norfirm-print/ARM9/bin/$(TWL_BUILDTYPE_ARM9)/twl_norfirm9_print.tef +MAKEFIRM_ARM7 = ../../norfirm/norfirm-print/ARM7/bin/$(TWL_BUILDTYPE_ARM7)/twl_norfirm7_print.tef +MAKEFIRM_RSA_PRVKEY = $(TWL_KEYSDIR)/rsa/private_gcd.der +LDEPENDS_BIN += ../../norfirm/norfirm-print/wram_regs/wram_regs.rbin + +MAKEFIRM_FLAGS += -p +FIRM_SPEC = gcdfirm.gcdsf + +LDIRT_CLEAN += $(TARGETS) \ + rsa_public.sbin \ + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build: $(TARGET_BIN) + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/gcdfirm/gcdfirm-print/gcdfirm.gcdsf b/build/gcdfirm/gcdfirm-print/gcdfirm.gcdsf new file mode 100644 index 00000000..1a0a93a2 --- /dev/null +++ b/build/gcdfirm/gcdfirm-print/gcdfirm.gcdsf @@ -0,0 +1,22 @@ +#GCDSF --- Gcdfirm Spec File + +VERSION : GENERATE + +RSA_KEY : $(MAKEFIRM_RSA_PRVKEY) +OUT_KEY : rsa_public.sbin + +WRAM_RBIN: ../../norfirm/norfirm-print/wram_regs/wram_regs.rbin + +DECOMP_PROC : ARM9 # ARM9 or ARM7 + +ARM9_COMP : FALSE # TRUE or FALSE, should be before ARM9_SBIN +ARM9_SBIN : $(MAKEFIRM_ARM9).TWL.FLX.sbin +ARM9_ELF : $(MAKEFIRM_ARM9).tef + +ARM7_COMP : FALSE # TRUE or FALSE, should be before ARM7_SBIN +ARM7_SBIN : $(MAKEFIRM_ARM7).TWL.FLX.sbin +ARM7_ELF : $(MAKEFIRM_ARM7).tef + +ARM9_X2 : TRUE # TRUE or FALSE + +NCD_ROMOFS : 0x07fe00 diff --git a/build/libraries/init/ARM7/crt0_firm.c b/build/libraries/init/ARM7/crt0_firm.c index e7f6f629..c2bd7c17 100644 --- a/build/libraries/init/ARM7/crt0_firm.c +++ b/build/libraries/init/ARM7/crt0_firm.c @@ -33,6 +33,8 @@ extern void OS_IrqHandler(void); extern void _fp_init(void); extern void __call_static_initializers(void); +static void INITi_CpuClear32(register u32 data, register void *destp, register u32 size); +static void INITi_CpuClearFast(register u32 data, register void* destp, register u32 size); static void INITi_DoAutoload(void); static void INITi_ShelterLtdBinary(void); static void INITi_CopySysConfig( void ); @@ -128,9 +130,7 @@ SDK_WEAK_SYMBOL asm void _start( void ) #endif movne r0, #FIRM_PXI_ID_WARMBOOT moveq r0, #FIRM_PXI_ID_COLDBOOT - bl PXI_SendByIntf - mov r0, #FIRM_PXI_ID_INIT_MMEM - bl PXI_WaitByIntf + bl PXIi_SendByIntf #endif // SDK_TS #endif // FIRM_DISABLE_CR_AT_WARMBOOT @@ -142,6 +142,19 @@ SDK_WEAK_SYMBOL asm void _start( void ) tst r2, r1 beq @1 + mov r0, #FIRM_PXI_ID_INIT_MMEM + bl PXIi_WaitIDByIntf + + //---- clear HW_MAIN_MEM_SHARED + mov r0, #0 + ldr r1, =HW_TWL_ROM_HEADER_BUF + mov r2, #HW_MAIN_MEM_SYSTEM_END - HW_TWL_ROM_HEADER_BUF // include HW_MAIN_MEM_SHARED + bl INITi_CpuClearFast + + //---- notify to clear HW_MAIN_MEM_SHARED + mov r0, #FIRM_PXI_ID_INIT_MMEM + bl PXIi_SendIDByIntf + /* SCFG を HW_SYS_CONF_BUF へコピー */ bl INITi_CopySysConfig @@ -193,6 +206,63 @@ SDK_WEAK_SYMBOL asm void _start( void ) bx r1 } + +/*---------------------------------------------------------------------------* + Name: INITi_CpuClearFast + Description: 32 Byte 単位でバッファのクリアを行う。 + Arguments: r0 - クリアする値。 + r1 - クリア先へのポインタ。 + r2 - 連続してクリアするバッファ長。 + Returns: なし。 + *---------------------------------------------------------------------------*/ +static asm void +INITi_CpuClearFast(register u32 data, register void* destp, register u32 size) +{ + stmfd sp!, {r4-r9} + + add r9, r1, r2 // r9: destEndp = destp + size + mov r12, r2, lsr #5 // r12: destBlockEndp = destp + size/32*32 + add r12, r1, r12, lsl #5 + + mov r2, r0 + mov r3, r2 + mov r4, r2 + mov r5, r2 + mov r6, r2 + mov r7, r2 + mov r8, r2 + +@40: + cmp r1, r12 // while (destp < destBlockEndp) + stmltia r1!, {r0, r2-r8} // *((vu32 *)(destp++)) = data + blt @40 +@41: + cmp r1, r9 // while (destp < destEndp) + stmltia r1!, {r0} // *((vu32 *)(destp++)) = data + blt @41 + + ldmfd sp!, {r4-r9} + bx lr +} + +/*---------------------------------------------------------------------------* + Name: INITi_CpuClear32 + Description: 32 bit 単位でバッファのクリアを行う。 + Arguments: r0 - クリアする値。 + r1 - クリア先へのポインタ。 + r2 - 連続してクリアするバッファ長。 + Returns: なし。 + *---------------------------------------------------------------------------*/ +static asm void +INITi_CpuClear32(register u32 data, register void* destp, register u32 size) +{ + add r12, r1, r2 +@001: cmp r1, r12 + strlt r0, [r1], #4 + blt @001 + bx lr +} + /*---------------------------------------------------------------------------* Name: INITi_DoAutoload Description: リンク情報に沿って、各オートロードブロックの固定データ部の展開 diff --git a/build/libraries/init/ARM9/crt0_firm.c b/build/libraries/init/ARM9/crt0_firm.c index 711574a1..bd051802 100644 --- a/build/libraries/init/ARM9/crt0_firm.c +++ b/build/libraries/init/ARM9/crt0_firm.c @@ -34,6 +34,7 @@ extern void __call_static_initializers(void); /* 内部関数プロトタイプ定義 */ static void INITi_CpuClear32(register u32 data, register void *destp, register u32 size); +static void INITi_CpuClearFast(register u32 data, register void* destp, register u32 size); static void INITi_InitCoprocessor(void); static void INITi_InitRegion(void); static void INITi_DoAutoload(void); @@ -127,7 +128,7 @@ SDK_WEAK_SYMBOL asm void _start( void ) //---- read reset flag from pmic #ifdef SDK_TS #ifdef FIRM_DISABLE_CR_AT_WARMBOOT -@0: bl PXI_RecvByIntf +@0: bl PXIi_RecvIDByIntf cmp r0, #FIRM_PXI_ID_COLDBOOT cmpne r0, #FIRM_PXI_ID_WARMBOOT bne @0 @@ -138,15 +139,21 @@ SDK_WEAK_SYMBOL asm void _start( void ) movne r0, #FALSE bl MIi_InitMainMemCR - mov r0, #FIRM_PXI_ID_INIT_MMEM - bl PXI_SendByIntf - #else // !FIRM_DISABLE_CR_AT_WARMBOOT //---- initialize Main Memory bl MIi_InitMainMemCR #endif // !FIRM_DISABLE_CR_AT_WARMBOOT #endif // SDK_TS + + //---- notify main memory mode into burst mode + mov r0, #FIRM_PXI_ID_INIT_MMEM + bl PXIi_SendIDByIntf + + //---- wait to clear HW_MAIN_MEM_SHARED + mov r0, #FIRM_PXI_ID_INIT_MMEM + bl PXIi_WaitIDByIntf + /* システム制御コプロセッサ初期化 */ bl INITi_InitCoprocessor @@ -160,6 +167,7 @@ SDK_WEAK_SYMBOL asm void _start( void ) mov r2, #HW_DTCM_SIZE bl INITi_CpuClear32 +#if 0 // BG/OBJ palette (1KB) mov r0, #0 ldr r1, =HW_PLTT @@ -171,6 +179,7 @@ SDK_WEAK_SYMBOL asm void _start( void ) ldr r1, =HW_OAM mov r2, #HW_OAM_SIZE bl INITi_CpuClear32 +#endif //---- load autoload block and initialize bss // bl INITi_DoAutoload @@ -184,7 +193,7 @@ SDK_WEAK_SYMBOL asm void _start( void ) ldr r1, [r3, #12] // SDK_STATIC_BSS_START ldr r2, [r3, #16] // SDK_STATIC_BSS_END sub r2, r2, r1 - bl INITi_CpuClear32 + bl INITi_CpuClearFast //---- flush static bss region // (r0 == #0, r3 == _start_ModuleParams::BSS_segment_start) @@ -221,6 +230,44 @@ SDK_WEAK_SYMBOL asm void _start( void ) bx r1 } +/*---------------------------------------------------------------------------* + Name: INITi_CpuClearFast + Description: 32 Byte 単位でバッファのクリアを行う。 + Arguments: r0 - クリアする値。 + r1 - クリア先へのポインタ。 + r2 - 連続してクリアするバッファ長。 + Returns: なし。 + *---------------------------------------------------------------------------*/ +static asm void +INITi_CpuClearFast(register u32 data, register void* destp, register u32 size) +{ + stmfd sp!, {r4-r9} + + add r9, r1, r2 // r9: destEndp = destp + size + mov r12, r2, lsr #5 // r12: destBlockEndp = destp + size/32*32 + add r12, r1, r12, lsl #5 + + mov r2, r0 + mov r3, r2 + mov r4, r2 + mov r5, r2 + mov r6, r2 + mov r7, r2 + mov r8, r2 + +@40: + cmp r1, r12 // while (destp < destBlockEndp) + stmltia r1!, {r0, r2-r8} // *((vu32 *)(destp++)) = data + blt @40 +@41: + cmp r1, r9 // while (destp < destEndp) + stmltia r1!, {r0} // *((vu32 *)(destp++)) = data + blt @41 + + ldmfd sp!, {r4-r9} + bx lr +} + /*---------------------------------------------------------------------------* Name: INITi_CpuClear32 Description: 32 bit 単位でバッファのクリアを行う。 diff --git a/build/libraries/mi/ARM9/mi_init_mainMemory.c b/build/libraries/mi/ARM9/mi_init_mainMemory.c index ede898af..083ce2b8 100644 --- a/build/libraries/mi/ARM9/mi_init_mainMemory.c +++ b/build/libraries/mi/ARM9/mi_init_mainMemory.c @@ -94,7 +94,16 @@ asm void MIi_InitMainMemCR( BOOL setCR ) @10: ldr r3, =REG_EXMEMCNT_ADDR - mov r1, #REG_MI_EXMEMCNT_IFM_MASK | REG_MI_EXMEMCNT_CE2_MASK + ldr r1, = (1 << REG_MI_EXMEMCNT_IFM_SHIFT) | \ + (1 << REG_MI_EXMEMCNT_CE2_SHIFT) | \ + (MI_PROCESSOR_ARM7 << REG_MI_EXMEMCNT_EP_SHIFT) | \ + (MI_PROCESSOR_ARM7 << REG_MI_EXMEMCNT_MPA_SHIFT) | \ + (MI_PROCESSOR_ARM7 << REG_MI_EXMEMCNT_MPB_SHIFT) | \ + (MI_PROCESSOR_ARM7 << REG_MI_EXMEMCNT_CP_SHIFT) | \ + (MIi_PHI_CLOCK_LOW << REG_MI_EXMEMCNT_PHI_SHIFT) | \ + (MI_CTRDG_ROMCYCLE1_18 << REG_MI_EXMEMCNT_ROM1st_SHIFT) | \ + (MI_CTRDG_ROMCYCLE2_6 << REG_MI_EXMEMCNT_ROM2nd_SHIFT) | \ + (MI_CTRDG_RAMCYCLE_10 << REG_MI_EXMEMCNT_RAM_SHIFT) strh r1, [r3] bx r12 diff --git a/build/libraries/pxi/common/pxi_firm.c b/build/libraries/pxi/common/pxi_firm.c index 48adc723..1659f5f3 100644 --- a/build/libraries/pxi/common/pxi_firm.c +++ b/build/libraries/pxi/common/pxi_firm.c @@ -219,3 +219,48 @@ FIRMPxiID PXI_RecvID( void ) OS_RestoreInterrupts( enabled ); } } + +/*---------------------------------------------------------------------------* + Name: PXIi_SendIDByIntf + + Description: Send 4bit id to the other processor + + Arguments: id sending id + + Returns: None + *---------------------------------------------------------------------------*/ +void PXIi_SendIDByIntf( u32 id ) +{ + reg_PXI_INTF = (u16)(id << REG_PXI_INTF_SEND_SHIFT); +} + +/*---------------------------------------------------------------------------* + Name: PXIi_RecvIDByIntf + + Description: Receive 4bit id from the other processor + + Arguments: None + + Returns: received id + *---------------------------------------------------------------------------*/ +u32 PXIi_RecvIDByIntf( void ) +{ + return (u32)((reg_PXI_INTF & REG_PXI_INTF_RECV_MASK) >> REG_PXI_INTF_RECV_SHIFT); +} + +/*---------------------------------------------------------------------------* + Name: PXIi_WaitIDByIntf + + Description: Wait 4bit id from the other processor + + Arguments: id waiting id + + Returns: None + *---------------------------------------------------------------------------*/ +void PXIi_WaitIDByIntf( u32 id ) +{ + while (PXIi_RecvIDByIntf() != id) + { + } +} + diff --git a/build/norfirm/Makefile b/build/norfirm/Makefile index d118dd75..e49922b3 100644 --- a/build/norfirm/Makefile +++ b/build/norfirm/Makefile @@ -22,6 +22,7 @@ include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs #---------------------------------------------------------------------------- SUBDIRS = \ + firm-dev \ norfirm-print \ norfirm-empty \ diff --git a/build/norfirm/firm-dev/ARM7/Makefile b/build/norfirm/firm-dev/ARM7/Makefile new file mode 100644 index 00000000..97c1de2a --- /dev/null +++ b/build/norfirm/firm-dev/ARM7/Makefile @@ -0,0 +1,49 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - tools - firm-dev +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +TWL_PROC = ARM7 + +SUBDIRS = + +LINCLUDES = ../include + +#---------------------------------------------------------------------------- + +TARGET_BIN = firm_dev7.tef + +CRT0_O = crt0_firm.o + +SRCS = \ + main.c \ + +#SRCDIR = # using default +#LCFILE = # using default + +MAKELCF_FLAGS += -DADDRESS_LTDWRAM='0x037c0000' + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/norfirm/firm-dev/ARM7/main.c b/build/norfirm/firm-dev/ARM7/main.c new file mode 100644 index 00000000..f004af8d --- /dev/null +++ b/build/norfirm/firm-dev/ARM7/main.c @@ -0,0 +1,55 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - norfirm-print + File: main.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: 2007-09-11#$ + $Rev: 22 $ + $Author: yutaka $ + *---------------------------------------------------------------------------*/ +#include +#include "reboot.h" + +//#define PRINT_DEBUG + +#ifndef PRINT_DEBUG +#undef OS_TPrintf +#define OS_TPrintf(...) ((void)0) +#endif // PRINT_DEBUG + +void TwlSpMain( void ) +{ + OS_TPrintf( "\nNOR Boot time is %d msec.\n", OS_TicksToMilliSecondsBROM32(OS_GetTick())); + +// MIi_CpuClearFast( 0, (void*)HW_TWL_ROM_HEADER_BUF, HW_MAIN_MEM_SYSTEM_END - HW_TWL_ROM_HEADER_BUF ); // include HW_MAIN_MEM_SHARED + MIi_CpuClearFast( 0, (void*)OSi_GetFromBromAddr(), sizeof(OSFromBromBuf) ); + + OS_InitFIRM(); + + OS_TPrintf( "\nARM7 starts.\n" ); + + OS_EnableInterrupts(); + OS_EnableIrq(); + + PM_InitFIRM(); + PMi_SetParams( REG_PMIC_BL_BRT_A_ADDR, PMIC_BACKLIGHT_BRIGHT_MAX, PMIC_BL_BRT_A_MASK ); + PMi_SetParams( REG_PMIC_BL_BRT_B_ADDR, PMIC_BACKLIGHT_BRIGHT_MAX, PMIC_BL_BRT_B_MASK ); + PM_BackLightOn( TRUE ); + + OS_TPrintf( "\nARM7 ends.\n" ); + + REBOOT_DisableInterruptsAndProtectionUnit(); + reg_SCFG_JTAG = REG_SCFG_JTAG_CPUJE_MASK | REG_SCFG_JTAG_ARM7SEL_MASK | REG_SCFG_JTAG_DSPJE_MASK; + while (1) + { + } +// OS_Terminate(); +} + diff --git a/build/norfirm/firm-dev/ARM9/Makefile b/build/norfirm/firm-dev/ARM9/Makefile new file mode 100644 index 00000000..6b2904e5 --- /dev/null +++ b/build/norfirm/firm-dev/ARM9/Makefile @@ -0,0 +1,48 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - tools - firm-dev +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +SUBDIRS = + +LINCLUDES = ../include + +#---------------------------------------------------------------------------- + +TARGET_BIN = firm_dev9.srl + +SRCS = main.c + +CRT0_O = crt0_firm.o + +MAKEROM_ARM7 = ../ARM7/bin/$(TWL_BUILDTYPE_ARM7)/firm_dev7.tef +MAKEROM_ARM7_BASE = $(basename $(MAKEROM_ARM7)) + +#SRCDIR = # using default +#LCFILE = # using default + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/norfirm/firm-dev/ARM9/main.c b/build/norfirm/firm-dev/ARM9/main.c new file mode 100644 index 00000000..13b33851 --- /dev/null +++ b/build/norfirm/firm-dev/ARM9/main.c @@ -0,0 +1,41 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - norfirm-print + File: main.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: 2007-09-11#$ + $Rev: 22 $ + $Author: yutaka $ + *---------------------------------------------------------------------------*/ +#include +#include "reboot.h" + +//#define PRINT_DEBUG + +#ifndef PRINT_DEBUG +#undef OS_TPrintf +#define OS_TPrintf(...) ((void)0) +#endif // PRINT_DEBUG + +void TwlMain( void ) +{ + OS_TPrintf( "\nNOR Boot time is %d msec.\n", OS_TicksToMilliSecondsBROM32(OS_GetTick())); + + MIi_CpuClearFast( 0, (void*)OSi_GetFromBromAddr(), sizeof(OSFromBromBuf) ); + + OS_InitFIRM(); + + OS_TPrintf( "\nARM9 starts.\n" ); + OS_TPrintf( "\nARM9 ends.\n" ); + + REBOOT_DisableInterruptsAndProtectionUnit(); + OS_Terminate(); +} + diff --git a/build/norfirm/firm-dev/Makefile b/build/norfirm/firm-dev/Makefile new file mode 100644 index 00000000..44af7dc9 --- /dev/null +++ b/build/norfirm/firm-dev/Makefile @@ -0,0 +1,53 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - build +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + + +# if you have no valid key, comment out next line +#TWL_KEYSDIR = $(FIRM_ROOT)/../twl_firmware/bootrom/build/keys + + +#---------------------------------------------------------------------------- + +SUBDIRS = \ + wram_regs \ + ARM7 \ + ARM9 \ + +TARGET_FIRM_BIN = firm_dev-$(TWL_BUILD_TYPE)$(CODEGEN_ARCH).nor +BINDIR = . +MAKEFIRM_ARM9 = ARM9/bin/$(TWL_BUILDTYPE_ARM9)/firm_dev9.tef +MAKEFIRM_ARM7 = ARM7/bin/$(TWL_BUILDTYPE_ARM7)/firm_dev7.tef +MAKEFIRM_RSA_PRVKEY = $(TWL_KEYSDIR)/rsa/private_nor.der +LDEPENDS_BIN += wram_regs/wram_regs.rbin + +MAKEFIRM_FLAGS += -p +FIRM_SPEC = norfirm.norsf + +LDIRT_CLEAN += $(TARGETS) \ + rsa_public.sbin \ + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +#---------------------------------------------------------------------------- + +do-build: $(TARGET_BIN) + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/norfirm/firm-dev/norfirm.norsf b/build/norfirm/firm-dev/norfirm.norsf new file mode 100644 index 00000000..42f93272 --- /dev/null +++ b/build/norfirm/firm-dev/norfirm.norsf @@ -0,0 +1,25 @@ +#NORSF --- Norfirm Spec File + +VERSION : GENERATE + +BOOT_NAND : TRUE # TRUE or FALSE + +RSA_KEY : $(MAKEFIRM_RSA_PRVKEY) +OUT_KEY : rsa_public.sbin + +WRAM_RBIN: ./wram_regs/wram_regs.rbin + +DECOMP_PROC : ARM9 # ARM9 or ARM7 + +ARM9_COMP : TRUE # TRUE or FALSE, should be before ARM9_SBIN +ARM9_SBIN : $(MAKEFIRM_ARM9).TWL.FLX.sbin +ARM9_ELF : $(MAKEFIRM_ARM9).tef + +ARM7_COMP : TRUE # TRUE or FALSE, should be before ARM7_SBIN +ARM7_SBIN : $(MAKEFIRM_ARM7).TWL.FLX.sbin +ARM7_ELF : $(MAKEFIRM_ARM7).tef + +NCD_ROMOFS : 0x07fe00 + +BAUDRATE : 8M # 4M or 8M +ARM9_X2 : TRUE # TRUE or FALSE diff --git a/build/norfirm/firm-dev/wram_regs/Makefile b/build/norfirm/firm-dev/wram_regs/Makefile new file mode 100644 index 00000000..427c35a2 --- /dev/null +++ b/build/norfirm/firm-dev/wram_regs/Makefile @@ -0,0 +1,57 @@ +#! make -f +#---------------------------------------------------------------------------- +# Project: TwlFirm - tools - norfirm-print +# File: Makefile +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev:$ +# $Author:$ +#---------------------------------------------------------------------------- + +override TARGET_PLATFORM := TWL +override TARGET_CODEGEN := ARM +override TWL_ARCHGEN := LIMITED + +override TARGET_FINALROM := TRUE +override TARGET_RELEASE := +override TARGET_DEBUG := + +SUBDIRS = + +LINCLUDES = ../include + + +#---------------------------------------------------------------------------- + +TARGET_BIN = wram_regs.rbin + +SRCS = \ + wram_regs.c \ + +#SRCDIR = # using default +#LCFILE = # using default + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/commondefs + +INSTALL_DIR = . +INSTALL_TARGETS = $(BINDIR)/$(TARGET_BIN) + + +#---------------------------------------------------------------------------- + +do-build: $(TARGETS) + + +include $(TWL_IPL_RED_ROOT)/build/buildtools/modulerules + + +#===== End of Makefile ===== diff --git a/build/norfirm/firm-dev/wram_regs/wram_regs.c b/build/norfirm/firm-dev/wram_regs/wram_regs.c new file mode 100644 index 00000000..f03e0e14 --- /dev/null +++ b/build/norfirm/firm-dev/wram_regs/wram_regs.c @@ -0,0 +1,91 @@ +/*---------------------------------------------------------------------------* + Project: TwlFirm - tools - nandfirm + File: wram_regs.c + + Copyright 2007 Nintendo. All rights reserved. + + These coded instructions, statements, and computer programs contain + proprietary information of Nintendo of America Inc. and/or Nintendo + Company Ltd., and are protected by Federal copyright law. They may + not be disclosed to third parties or copied or duplicated in any form, + in whole or in part, without the prior written consent of Nintendo. + + $Date:: 2007-11-12#$ + $Rev: 149 $ + $Author: yutaka $ + *---------------------------------------------------------------------------*/ +#include +#include + +MIHeader_WramRegs wram_regs_init = +{ + // ARM9 + { + REG_MI_MBK_A0_FIELD( 1, MI_WRAM_A_OFFSET_0KB , MI_WRAM_ARM9 ), + REG_MI_MBK_A1_FIELD( 1, MI_WRAM_A_OFFSET_64KB , MI_WRAM_ARM9 ), + REG_MI_MBK_A2_FIELD( 1, MI_WRAM_A_OFFSET_128KB, MI_WRAM_ARM9 ), + REG_MI_MBK_A3_FIELD( 1, MI_WRAM_A_OFFSET_192KB, MI_WRAM_ARM9 ), + }, + { + REG_MI_MBK_B0_FIELD( 1, MI_WRAM_BC_OFFSET_0KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B1_FIELD( 1, MI_WRAM_BC_OFFSET_32KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B2_FIELD( 1, MI_WRAM_BC_OFFSET_64KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B3_FIELD( 1, MI_WRAM_BC_OFFSET_96KB , MI_WRAM_ARM7 ), + REG_MI_MBK_B4_FIELD( 1, MI_WRAM_BC_OFFSET_128KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B5_FIELD( 1, MI_WRAM_BC_OFFSET_160KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B6_FIELD( 1, MI_WRAM_BC_OFFSET_192KB, MI_WRAM_ARM7 ), + REG_MI_MBK_B7_FIELD( 1, MI_WRAM_BC_OFFSET_224KB, MI_WRAM_ARM7 ), + }, + { + REG_MI_MBK_C0_FIELD( 1, MI_WRAM_BC_OFFSET_0KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C1_FIELD( 1, MI_WRAM_BC_OFFSET_32KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C2_FIELD( 1, MI_WRAM_BC_OFFSET_64KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C3_FIELD( 1, MI_WRAM_BC_OFFSET_96KB , MI_WRAM_ARM7 ), + REG_MI_MBK_C4_FIELD( 1, MI_WRAM_BC_OFFSET_128KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C5_FIELD( 1, MI_WRAM_BC_OFFSET_160KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C6_FIELD( 1, MI_WRAM_BC_OFFSET_192KB, MI_WRAM_ARM7 ), + REG_MI_MBK_C7_FIELD( 1, MI_WRAM_BC_OFFSET_224KB, MI_WRAM_ARM7 ), + }, + REG_MI_MBK6_FIELD( REG_WRAM_MAP_CONV_ADDR( 6, A, EADDR, HW_WRAM_AREA_HALF ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 6, A, SADDR, HW_WRAM_AREA_HALF - HW_WRAM_A_SIZE ) + ), + REG_MI_MBK7_FIELD( REG_WRAM_MAP_CONV_ADDR( 7, B, EADDR, HW_WRAM_AREA + HW_WRAM_B_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 7, B, SADDR, HW_WRAM_AREA ) + ), + REG_MI_MBK8_FIELD( REG_WRAM_MAP_CONV_ADDR( 8, C, EADDR, MI_WRAM_MAP_NULL ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 8, C, SADDR, MI_WRAM_MAP_NULL ) + ), + + // ARM7 + REG_MI_MBK6_FIELD( REG_WRAM_MAP_CONV_ADDR( 6, A, EADDR, MI_WRAM_MAP_NULL ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 6, A, SADDR, MI_WRAM_MAP_NULL ) + ), + REG_MI_MBK7_FIELD( REG_WRAM_MAP_CONV_ADDR( 7, B, EADDR, HW_WRAM_AREA + HW_WRAM_B_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 7, B, SADDR, HW_WRAM_AREA ) + ), + REG_MI_MBK8_FIELD( REG_WRAM_MAP_CONV_ADDR( 8, C, EADDR, HW_WRAM_AREA_HALF - HW_WRAM_SIZE ), + MI_WRAM_IMAGE_256KB, + REG_WRAM_MAP_CONV_ADDR( 8, C, SADDR, HW_WRAM_AREA_HALF - HW_WRAM_SIZE - HW_WRAM_C_SIZE ) + ), + + // WRAM Lock + { + 0, + 0, + 0, + }, + + // WRAM-0/1 + 3, + + // VRAM-C + 7, + // VRAM-D + 7, +}; + diff --git a/include/firm/pxi/common/pxi_firm.h b/include/firm/pxi/common/pxi_firm.h index 5fc1f7f8..b6eb7687 100644 --- a/include/firm/pxi/common/pxi_firm.h +++ b/include/firm/pxi/common/pxi_firm.h @@ -114,6 +114,39 @@ void PXI_NotifyID( FIRMPxiID id ); *---------------------------------------------------------------------------*/ FIRMPxiID PXI_RecvID( void ); +/*---------------------------------------------------------------------------* + Name: PXIi_SendIDByIntf + + Description: send 4bit id to other processor + + Arguments: id notifying id + + Returns: None + *---------------------------------------------------------------------------*/ +void PXIi_SendIDByIntf( u32 id ); + +/*---------------------------------------------------------------------------* + Name: PXIi_RecvIDByIntf + + Description: receive 4bit id from the other processor + + Arguments: None + + Returns: received id + *---------------------------------------------------------------------------*/ +u32 PXIi_RecvIDByIntf( void ); + +/*---------------------------------------------------------------------------* + Name: PXIi_WaitIDByIntf + + Description: Wait 4bit id from the other processor + + Arguments: id waiting id + + Returns: None + *---------------------------------------------------------------------------*/ +void PXIi_WaitIDByIntf( u32 id ); + #ifdef __cplusplus } /* extern "C" */ diff --git a/readme.txt b/readme.txt index 79bb1509..444bf78a 100644 --- a/readme.txt +++ b/readme.txt @@ -10,4 +10,6 @@ 2.環境変数の設定  TWLIPL_ROOT ex.) TWLIPL_ROOT=c:/TwlIPL + TWL_KEYSDIR(ブートROMから起動可能なファームを作成する場合、鍵はtwl_firmwareリポジトリ内) + ex.) TWL_KEYSDIR=c:/twl_firmware diff --git a/tools/bin/gcdfirm_header_twlj.template.sbin b/tools/bin/gcdfirm_header_twlj.template.sbin new file mode 100644 index 0000000000000000000000000000000000000000..60ed6b7f1c5e8d50dba1c3820d4dcff7ea73a12b GIT binary patch literal 16384 zcmeI&RZJZ~*DheJxH}Zxxa-D!;||5$-QC@#xDVBiayd|BFVQ_E$RIY|k zVy5p5=I+zjrQABYyD69%HZf>hfBD(>xd$3AIjEKEs@UahbYgPaMpI)mujKL89kFNL z`?^;0n`o)FF@6c*Ar9rGuZzs$dlLEr`b3`ac!n4!1uADVO~68m`iIAzTydHlcN7rh ze$yN|Nt!y3s?#0JGCO8v0hD)%~{9$FKV1nuQ*7h;w$reb>84|(_=Rp8+v z!#SF!3r71HB9XO5%DZ*kgDc#!U+zFc(~NB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