Added Samsung SPC-6000A and SPC-6033P. Patch from Greatpsycho.

This commit is contained in:
SarahW 2020-11-14 12:25:36 +00:00
commit 9bdbcc18c0
8 changed files with 105 additions and 4 deletions

View file

@ -268,7 +268,7 @@ uint8_t ati28800k_in(uint16_t addr, void *p)
void ati28800_recalctimings(svga_t *svga)
{
ati28800_t *ati28800 = (ati28800_t *)svga->p;
pclog("ati28800_recalctimings\n");
//pclog("ati28800_recalctimings\n");
switch (((ati28800->regs[0xbe] & 0x10) >> 1) | ((ati28800->regs[0xb9] & 2) << 1) | ((svga->miscout & 0x0C) >> 2))
{
@ -299,7 +299,7 @@ void ati28800_recalctimings(svga_t *svga)
if (!svga->scrblank && (ati28800->regs[0xb0] & 0x20)) /*Extended 256 colour modes*/
{
pclog("8bpp_highres\n");
//pclog("8bpp_highres\n");
svga->render = svga_render_8bpp_highres;
svga->rowoffset <<= 1;
svga->ma <<= 1;
@ -407,6 +407,40 @@ void *ati28800k_spc4620p_init()
return ati28800;
}
void *ati28800k_spc6033p_init()
{
ati28800_t *ati28800 = malloc(sizeof(ati28800_t));
memset(ati28800, 0, sizeof(ati28800_t));
ati28800->port_03dd_val = 0;
ati28800->get_korean_font_base = 0;
ati28800->get_korean_font_index = 0;
ati28800->get_korean_font_enabled = 0;
ati28800->get_korean_font_kind = 0;
ati28800->in_get_korean_font_kind_set = 0;
ati28800->ksc5601_mode_enabled = 0;
rom_init(&ati28800->bios_rom, "spc6033p/phoenix.bin", 0xc0000, 0x8000, 0x7fff, 0, MEM_MAPPING_EXTERNAL);
loadfont("spc6033p/svb6120a_font.rom", 6);
svga_init(&ati28800->svga, ati28800, 1 << 19, /*512kb*/
ati28800k_recalctimings,
ati28800k_in, ati28800k_out,
NULL,
NULL);
io_sethandler(0x01ce, 0x0002, ati28800k_in, NULL, NULL, ati28800k_out, NULL, NULL, ati28800);
io_sethandler(0x03c0, 0x0020, ati28800k_in, NULL, NULL, ati28800k_out, NULL, NULL, ati28800);
ati28800->svga.miscout = 1;
ati28800->svga.ksc5601_sbyte_mask = 0;
ati_eeprom_load(&ati28800->eeprom, "svb6120a_spc6033p.nvr", 0);
return ati28800;
}
static int ati28800_available()
{
return rom_present("bios.bin");
@ -493,3 +527,15 @@ device_t ati28800k_spc4620p_device =
ati28800_force_redraw,
ati28800k_add_status_info
};
device_t ati28800k_spc6033p_device =
{
"SVB-6120A",
0,
ati28800k_spc6033p_init,
ati28800_close,
NULL,
ati28800_speed_changed,
ati28800_force_redraw,
ati28800k_add_status_info
};