diff --git a/src/bootldr/Makefile b/src/bootldr/Makefile index 0d39961..aae0385 100644 --- a/src/bootldr/Makefile +++ b/src/bootldr/Makefile @@ -55,7 +55,7 @@ TARGET = $(OBJDIR)/sd2snes_bootldr # List C source files here. (C dependencies are automatically generated.) -SRC = timer.c main.c ff.c clock.c uart.c power.c led.c faulthandler.c crc16.c crc32.c sdnative.c fileops.c iap.c printf.c +SRC = timer.c main.c ff.c clock.c uart.c power.c led.c faulthandler.c crc32.c sdnative.c fileops.c iap.c printf.c # usbcontrol.c usb_hid.c usbhw_lpc.c usbinit.c usbstdreq.c diff --git a/src/bootldr/config.h b/src/bootldr/config.h index a53859c..88be1af 100644 --- a/src/bootldr/config.h +++ b/src/bootldr/config.h @@ -1,11 +1,11 @@ #ifndef _CONFIG_H #define _CONFIG_H +#define DEBUG_BL // #define DEBUG_SD // #define DEBUG_IRQ -// #define DEBUG_MSU1 -// #define DEBUG_UART +#define DEBUG_UART #ifdef DEBUG_UART #define DBG_UART @@ -13,9 +13,13 @@ #define DBG_UART while(0) #endif +#ifdef DEBUG_BL +#define DBG_BL +#else #define DBG_BL while(0) +#endif -#define FW_START (0x00002000L) +#define FW_START (0x00003000L) #define FLASH_SECTORS (17) @@ -52,7 +56,7 @@ #define CONFIG_UART_PCLKDIV 1 #define CONFIG_UART_TX_BUF_SHIFT 8 #define CONFIG_UART_BAUDRATE 921600 -//#define CONFIG_UART_DEADLOCKABLE +#define CONFIG_UART_DEADLOCKABLE #define SSP_CLK_DIVISOR_FAST 2 #define SSP_CLK_DIVISOR_SLOW 250 diff --git a/src/bootldr/lpc1754.cfg b/src/bootldr/lpc1754.cfg index 5983e8c..5126cd4 100644 --- a/src/bootldr/lpc1754.cfg +++ b/src/bootldr/lpc1754.cfg @@ -26,7 +26,7 @@ if { [info exists CPUTAPID ] } { } #delays on reset lines -adapter_nsrst_delay 200 +#adapter_nsrst_delay 200 jtag_ntrst_delay 200 # LPC2000 & LPC1700 -> SRST causes TRST diff --git a/src/bootldr/lpc1754boot.ld b/src/bootldr/lpc1754boot.ld index 3ca18c6..e0d8512 100644 --- a/src/bootldr/lpc1754boot.ld +++ b/src/bootldr/lpc1754boot.ld @@ -10,7 +10,7 @@ ENTRY(_start) MEMORY { - flash (rx) : ORIGIN = 0x00000000, LENGTH = 0x02000 + flash (rx) : ORIGIN = 0x00000000, LENGTH = 0x03000 ram (rwx) : ORIGIN = 0x10000000, LENGTH = 0x03fe0 /* leave room for IAP */ ahbram (rwx) : ORIGIN = 0x2007C000, LENGTH = 0x04000 } diff --git a/src/bootldr/openocd-usb.cfg b/src/bootldr/openocd-usb.cfg index d552239..1fcd482 100644 --- a/src/bootldr/openocd-usb.cfg +++ b/src/bootldr/openocd-usb.cfg @@ -9,4 +9,4 @@ ft2232_vid_pid 0x0403 0x6010 ft2232_device_desc "Dual RS232" ft2232_layout "oocdlink" ft2232_latency 2 -adapter_khz 10 +#adapter_khz 10