forked from PR77/68000_Relocator_FLASH_Kickstart
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1. Turns out VBCC does maths a little differently and ROM2 reading was completely broken for both CLI and GUI 2. Turns out KS1.3 is really picky on path formation, so fix that
- Loading branch information
Showing
6 changed files
with
27 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,3 +37,7 @@ Logic/_xmsgs/ | |
Logic/FLASH_KICKSTART.tim | ||
Logic/FLASH_KICKSTART.tspec | ||
*.zip | ||
*.lha | ||
*.adf | ||
*.uaem | ||
.info |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -277,7 +277,7 @@ static void WriteRomText(const char *text, UBYTE *buffer, struct Window *window, | |
static char *GetFile() | ||
{ | ||
struct rtFileRequester *filereq; | ||
char filename[34]; | ||
char filename[128]; | ||
char *fullpath = malloc(256 * sizeof(char)); | ||
FILE *romFile; | ||
struct romInfo romInfo; | ||
|
@@ -300,13 +300,25 @@ static char *GetFile() | |
rtEZRequest("Out of memory!", "Oh no!", NULL, NULL); | ||
} | ||
|
||
snprintf(fullpath, 255, "%s/%s", filereq->Dir, filename); | ||
// Turns out WB doesn't like DF0:/filename.rom | ||
if (filereq->Dir[(strlen(filereq->Dir) - 1)] == ':') | ||
{ | ||
snprintf(fullpath, 255, "%s%s", filereq->Dir, filename); | ||
} | ||
else if (!strlen(filereq->Dir)) | ||
{ | ||
snprintf(fullpath, 255, "%s", filename); | ||
} | ||
else | ||
{ | ||
snprintf(fullpath, 255, "%s/%s", filereq->Dir, filename); | ||
} | ||
romFile = fopen(fullpath, "r"); | ||
|
||
if (!romFile) | ||
{ | ||
free(fullpath); | ||
rtEZRequest("Could no open ROM file", "OK", NULL, NULL); | ||
rtEZRequest("Could not open ROM file", "OK", NULL, NULL); | ||
return NULL; | ||
} | ||
|
||
|
@@ -340,7 +352,8 @@ static void getRom(int romID, struct ConfigDev *myCD, struct Window *myWindow) | |
} | ||
else | ||
{ | ||
getRomInfo((UBYTE *)(myCD->cd_BoardAddr + (512 * 1024)), &rInfo); | ||
ULONG romAddr = (ULONG)myCD->cd_BoardAddr + (512 * 1024); | ||
getRomInfo((UBYTE *)romAddr, &rInfo); | ||
} | ||
|
||
displayRomInfo(&rInfo, &rtext); | ||
|
@@ -628,7 +641,7 @@ int main() | |
} | ||
|
||
case GADABOUT: | ||
rtEZRequest("Flash Kickstart Programmer v1.3\nCreated by Andrew (LinuxJedi) Hutchings\[email protected]\nThis software is released under a GPLv3 license\n\nBased on work by Paul Raspa.", | ||
rtEZRequest("Flash Kickstart Programmer v1.4\nCreated by Andrew (LinuxJedi) Hutchings\[email protected]\nThis software is released under a GPLv3 license\n\nBased on work by Paul Raspa.", | ||
"Cool!", NULL, NULL); | ||
break; | ||
|
||
|