\r
$(OBJDIR)/fpgaimage.s19: $(OBJDIR)/fpgaimg.o\r
@echo obj/fpgaimage.s19\r
- @$(LD) -g -Tldscript-fpga -o $(OBJDIR)\fpgaimage.elf $(OBJDIR)/fpgaimg.o\r
+ @$(LD) -g -Tldscript-fpga -o $(OBJDIR)\fpgaimage.elf -Map=obj/fpgaimage.map $(OBJDIR)/fpgaimg.o\r
@$(OBJCOPY) -Osrec --srec-forceS3 $(OBJDIR)\fpgaimage.elf $(OBJDIR)\fpgaimage.s19\r
\r
$(OBJDIR)/osimage.s19: $(OBJ) $(OBJCOMMON)\r
@echo obj/osimage.s19\r
- @$(LD) -g -Tldscript -o $(OBJDIR)\osimage.elf $(OBJ) $(OBJCOMMON) $(LIB)\libgcc.a\r
+ @$(LD) -g -Tldscript -o $(OBJDIR)\osimage.elf $(OBJ) $(OBJCOMMON) -Map=obj/osimage.map $(LIB)\libgcc.a\r
@$(OBJCOPY) -Osrec --srec-forceS3 $(OBJDIR)\osimage.elf $(OBJDIR)\osimage.s19\r
\r
osimage.s19: $(OBJDIR)/osimage.s19 $(OBJDIR)/fpgaimage.s19\r
\r
// The large multi-purpose buffer, typically used to hold A/D samples,\r
// maybe processed in some way.\r
-DWORD BigBuf[16000];\r
+DWORD BigBuf[10000];\r
\r
/// appmain.h\r
void ReadMem(int addr);\r
int n = 1250;\r
\r
// clear buffer\r
+ DbpIntegers((DWORD)BigBuf, sizeof(BigBuf), 0x12345678);\r
memset(BigBuf,0,sizeof(BigBuf));\r
\r
// Set up the synchronous serial port\r
FpgaWriteConfWord(FPGA_MAJOR_MODE_OFF);\r
}\r
\r
-// this is a dummy function to get around\r
-// a possible flash bug in the bootloader\r
-// delete once you've added more code.\r
-void DummyDummyDummy(void)\r
-{\r
- FpgaSendCommand(FPGA_CMD_SET_DIVISOR, 88); //134.8Khz\r
- FpgaWriteConfWord(FPGA_MAJOR_MODE_LF_PASSTHRU);\r
- AcquireTiType();\r
- FpgaWriteConfWord(FPGA_MAJOR_MODE_OFF);\r
-}\r
-\r
// arguments: 64bit data split into 32bit idhi:idlo and optional 16bit crc\r
// if crc provided, it will be written with the data verbatim (even if bogus)\r
// if not provided a valid crc will be computed from the data and written.\r
\r
$(OBJDIR)/bootrom.s19: $(OBJFLASH)\r
@echo obj/bootrom.s19\r
- @$(LD) -g -Tldscript-flash --oformat elf32-littlearm -o $(OBJDIR)/bootrom.elf $(OBJFLASH)\r
+ @$(LD) -g -Tldscript-flash --oformat elf32-littlearm -Map=obj/bootrom.map -o $(OBJDIR)/bootrom.elf $(OBJFLASH)\r
@$(OBJCOPY) -Osrec --srec-forceS3 $(OBJDIR)/bootrom.elf $(OBJDIR)/bootrom.s19\r
\r
$(OBJDIR)/bootrom-forjtag.s19: $(OBJJTAG)\r
@echo obj/bootrom-forjtag.s19\r
- @$(LD) -g -Tldscript-ram-jtag --oformat elf32-littlearm -o $(OBJDIR)/bootrom-forjtag.elf $(OBJJTAG)\r
+ @$(LD) -g -Tldscript-ram-jtag --oformat elf32-littlearm -Map=obj/bootrom-forjtag.map -o $(OBJDIR)/bootrom-forjtag.elf $(OBJJTAG)\r
@$(OBJCOPY) -Osrec --srec-forceS3 $(OBJDIR)/bootrom-forjtag.elf $(OBJDIR)/bootrom-forjtag.s19\r
\r
$(OBJDIR)/bootrom.o: bootrom.c $(INCLUDES)\r
\r
DWORD written;\r
OVERLAPPED ov;\r
+\r
memset(&ov, 0, sizeof(ov));\r
WriteFile(UsbHandle, buf, 65, &written, &ov);\r
if(GetLastError() != ERROR_IO_PENDING) {\r
UsbCommand c;\r
memset(&c, 0, sizeof(c));\r
\r
- printf("expected = %08x flush, ", ExpectedAddr);\r
-\r
int i;\r
for(i = 0; i < 240; i += 48) {\r
c.cmd = CMD_SETUP_WRITE;\r
\r
c.cmd = CMD_FINISH_WRITE;\r
c.ext1 = (ExpectedAddr-1) & (~255);\r
- printf("c.ext1 = %08x\r", c.ext1);\r
+ printf("Flashing address: %08x\r", c.ext1);\r
memcpy(c.d.asBytes, QueuedToSend+240, 16);\r
SendCommand(&c, TRUE);\r
\r