1
0
mirror of https://github.com/mist-devel/mist-firmware.git synced 2026-02-26 16:23:35 +00:00

[firmware] updated firmware for minimig, updated boot text, real rtl version read, config display on boot, cleaned up cart stuff.

This commit is contained in:
Rok Krajnc
2015-05-29 17:01:54 +00:00
parent 1ac253c864
commit 8a5c7450bf
6 changed files with 42 additions and 39 deletions

4
boot.c
View File

@@ -42,10 +42,10 @@ static void mem_write16(unsigned short x) {
unsigned short bcurx=0;
unsigned short bcury=96;
static int bootscreen_adr = 0x80000 + 120*640/8;
static int bootscreen_adr = 0x80000 + /*120*/112*640/8;
void BootHome() {
bootscreen_adr = 0x80000 + 120*640/8;
bootscreen_adr = 0x80000 + /*120*/112*640/8;
}
//// boot font ////

View File

@@ -473,6 +473,15 @@ unsigned char LoadConfiguration(char *filename)
BootPrint("Defaults set\n");
}
// print config to boot screen
if (minimig_v2()) {
char cfg_str[41];
sprintf(cfg_str, "CPU: %s", config_cpu_msg[config.cpu]); BootPrintEx(cfg_str);
sprintf(cfg_str, "Chipset: %s", config_chipset_msg [(config.chipset >> 2) & (minimig_v1()?3:7)]); BootPrintEx(cfg_str);
sprintf(cfg_str, "Memory: CHIP: %s FAST: %s SLOW: %s", config_memory_fast_msg[config.memory >> 4 & 0x03], config_memory_chip_msg[config.memory & 0x03], config_memory_slow_msg[config.memory >> 2 & 0x03]); BootPrintEx(cfg_str);
}
WaitTimer(6000);
key = OsdGetCtrl();
if (key == KEY_F1) {
// force NTSC mode if F1 pressed
@@ -509,14 +518,8 @@ void ApplyConfiguration(char reloadkickstart)
}
if (!CheckButton() && !config.disable_ar3) {
// if menu button pressed don't load Action Replay
#ifndef ACTIONREPLAY_BROKEN
if(config.memory & 0x20) {
BootPrint("More than 2MB of Fast RAM configured - disabling Action Replay!");
} else {
UploadActionReplay();
}
#endif
// load Action Replay
UploadActionReplay();
}
}
} else {

26
fpga.c
View File

@@ -833,7 +833,12 @@ void fpga_init(char *name) {
if(minimig_v2()) {
EnableOsd();
SPI(OSD_CMD_VERSION);
char ver_beta = SPI(0xff);
char ver_major = SPI(0xff);
char ver_minor = SPI(0xff);
DisableOsd();
SPIN(); SPIN(); SPIN(); SPIN();
SPI(OSD_CMD_RST);
rstval = (SPI_RST_USR | SPI_RST_CPU | SPI_CPU_HLT);
SPI(rstval);
@@ -847,15 +852,16 @@ void fpga_init(char *name) {
SPIN(); SPIN(); SPIN(); SPIN();
WaitTimer(100);
BootInit();
WaitTimer(1000);
BootPrintEx("**** MINIMIG-AGA for MiST (BETA) ****");
WaitTimer(500);
char rtl_ver[45];
sprintf(rtl_ver, "**** MINIMIG-AGA v%d.%d%s for MiST ****", ver_major, ver_minor, ver_beta ? " BETA" : "");
BootPrintEx(rtl_ver);
BootPrintEx(" ");
//BootPrintEx("Original Minimig by Dennis van Weeren");
//BootPrintEx("Updates by Jakub Bednarski, Tobias Gubener, Sascha Boing, A.M. Robinson & others");
BootPrintEx("MINIMIG-AGA by Rok Krajnc (rok.krajnc@gmail.com)");
BootPrintEx("MINIMIG-AGA for MiST by Rok Krajnc (rok.krajnc@gmail.com)");
BootPrintEx("Original Minimig by Dennis van Weeren");
BootPrintEx("Updates by Jakub Bednarski, Tobias Gubener, Sascha Boing, A.M. Robinson & others");
BootPrintEx("MiST by Till Harbaum (till@harbaum.org)");
//BootPrintEx("For updates & code see https://github.com/rkrajnc/minimig-de1");
//BootPrintEx("For support, see http://www.minimig.net");
BootPrintEx("For updates & code see https://github.com/rkrajnc/minimig-mist");
BootPrintEx(" ");
WaitTimer(1000);
}
@@ -868,10 +874,6 @@ void fpga_init(char *name) {
df[2].status = 0;
df[3].status = 0;
if(minimig_v2())
BootPrintEx("Booting ...");
WaitTimer(6000);
config.kickstart.name[0]=0;
SetConfigurationFilename(0); // Use default config
LoadConfiguration(0); // Use slot-based config filename

28
menu.c
View File

@@ -102,11 +102,7 @@ const char *helptexts[]={
" Welcome to Minimig! Use the cursor keys to navigate the menus. Use space bar or enter to select an item. Press Esc or F12 to exit the menus. Joystick emulation on the numeric keypad can be toggled with the numlock key, while pressing Ctrl-Alt-0 (numeric keypad) toggles autofire mode.",
" Minimig can emulate an A600 IDE harddisk interface. The emulation can make use of Minimig-style hardfiles (complete disk images) or UAE-style hardfiles (filesystem images with no partition table). It is also possible to use either the entire SD card or an individual partition as an emulated harddisk.",
" Minimig's processor core can emulate a 68000 or 68020 processor (though the 68020 mode is still experimental.) If you're running software built for 68000, there's no advantage to using the 68020 mode, since the 68000 emulation runs just as fast.",
#ifdef ACTIONREPLAY_BROKEN
" Minimig can make use of up to 2 megabytes of Chip RAM, up to 1.5 megabytes of Slow RAM (A500 Trapdoor RAM), and up to 8 megabytes of true Fast RAM.",
#else
" Minimig can make use of up to 2 megabytes of Chip RAM, up to 1.5 megabytes of Slow RAM (A500 Trapdoor RAM), and up to 8 megabytes of true Fast RAM. To use the Action Replay feature you will need an Action Replay 3 ROM file on the SD card, named AR3.ROM. You will also need to set Fast RAM to no more than 2 megabytes.",
#endif
" Minimig can make use of up to 2 megabytes of Chip RAM, up to 1.5 megabytes of Slow RAM (A500 Trapdoor RAM), and up to 24 megabytes of true Fast RAM. To use the HRTmon feature you will need a file on the SD card named hrtmon.rom.",
" Minimig's video features include a blur filter, to simulate the poorer picture quality on older monitors, and also scanline generation to simulate the appearance of a screen with low vertical resolution.",
0
};
@@ -1886,33 +1882,28 @@ void HandleUI(void)
OsdSetTitle("Memory",OSD_ARROW_LEFT|OSD_ARROW_RIGHT);
OsdWrite(0, "", 0,0);
strcpy(s, " CHIP : ");
strcpy(s, " CHIP : ");
strcat(s, config_memory_chip_msg[config.memory & 0x03]);
OsdWrite(1, s, menusub == 0,0);
strcpy(s, " SLOW : ");
strcpy(s, " SLOW : ");
strcat(s, config_memory_slow_msg[config.memory >> 2 & 0x03]);
OsdWrite(2, s, menusub == 1,0);
strcpy(s, " FAST : ");
strcpy(s, " FAST : ");
strcat(s, config_memory_fast_msg[config.memory >> 4 & 0x03]);
OsdWrite(3, s, menusub == 2,0);
OsdWrite(4, "", 0,0);
strcpy(s, " ROM : ");
strcpy(s, " ROM : ");
if (config.kickstart.long_name[0])
strncat(s, config.kickstart.long_name, sizeof(config.kickstart.long_name));
else
strncat(s, config.kickstart.name, sizeof(config.kickstart.name));
OsdWrite(5, s, menusub == 3,0);
#ifdef ACTIONREPLAY_BROKEN
OsdWrite(0, "", 0,0);
menumask&=0xef; // Remove bit 4
#else
strcpy(s, " AR3 : ");
strcpy(s, " HRTmon: ");
strcat(s, config.disable_ar3 ? "disabled" : "enabled ");
OsdWrite(6, s, menusub == 4,config.memory&0x20); // Grey out AR3 if more than 2MB fast memory
#endif
OsdWrite(6, s, menusub == 4,0);
OsdWrite(7, STD_EXIT, menusub == 5,0);
@@ -2612,9 +2603,12 @@ void HandleUI(void)
break;
case MENU_FIRMWARE_CORE_FILE_SELECTED :
// close OSD now as the new core may not even have one
OsdDisable();
// close OSD now as the new core may not even have one
// reset minimig boot text position
BootHome();
fpga_init(file.name);
menustate = MENU_NONE1;

3
menu.h
View File

@@ -104,6 +104,9 @@ extern const char *config_memory_chip_msg[];
extern const char *config_memory_slow_msg[];
extern const char *config_memory_fast_msg[];
extern const char *config_scanline_msg[];
extern const char *config_cpu_msg[];
extern const char *config_hdf_msg[];
extern const char *config_chipset_msg[];
void InsertFloppy(adfTYPE *drive);

1
osd.h
View File

@@ -42,6 +42,7 @@
#define OSD_CMD_JOY 0x64
#define OSD_CMD_OSD_WR 0x0c
#define OSD_CMD_WR 0x1c
#define OSD_CMD_VERSION 0x88
#define DISABLE_KEYBOARD 0x02 // disable keyboard while OSD is active