tdlabac / MSX1_MiSTer

GNU General Public License v2.0
21 stars 4 forks source link

[ENHANCEMENT] Select a MSX 1 machine #15

Open GuerreroNinja opened 1 year ago

GuerreroNinja commented 1 year ago

I know this is an ambitious and difficult request, but I think you may consider it...

MSX 1 machines differences are mainly defined by:

So, in fact, I think it may be possible to add an OSD option to select the MSX machine to run (like OpenMSX emulator does). That way, we may preserve a lot of MSX 1 machines with a single Mister core (we just need the BIOS, memory mapping and VDP version). This information is already present in "machines" folder of OpenMSX and BlueMSX if I remember well.

As I know nothing about FPGA development, this may be an impossible request, so please feel free to close it if that is the case.

Thank you!!

nonochus commented 1 year ago

I support this suggestion, I'm even happy with just being able to switch from ntsc to pal, but for an msx1 core it would be some great extras.

I don't want to open an issue, would it also be possible to add an option to eject disk and leave the disk drive empty as in real hardware?

Very thanks, really love this core.

tdlabac commented 1 year ago

I support this suggestion, I'm even happy with just being able to switch from ntsc to pal, but for an msx1 core it would be some great extras.

In new release 221106

I don't want to open an issue, would it also be possible to add an option to eject disk and leave the disk drive empty as in real hardware?

In the dsk image selection menu in the OSD, pressing the backspace button will remove the current image.

GuerreroNinja commented 1 year ago

Wow!!!! This is just FAAAST! Well, we now have a PAL/NTSC switch, I am testing it and seems to work ok (further tests will be done along the week). Thank you!!

nonochus commented 1 year ago

Testing here too.

Very very very very thanks!!!!!

GuerreroNinja commented 1 year ago

@tdlabac would be possible to change memory mapping and BIOS from OSD?

tdlabac commented 1 year ago

@tdlabac would be possible to change memory mapping and BIOS from OSD?

I don't quite understand what the goal is. What mapping is supposed to be going on. Now 64kB of RAM is connected to slot 3.

GuerreroNinja commented 1 year ago

In a few words, in VG-8020 the memory mapping is as follows:

Slot 0 : Main ROM (from 4000h - 3fffh) Slot 1: Cartridge 1 Slot 2: Cartridge 2 Slot 3: Main 64Kb RAM

In SVI-728 MSX 1 PAL model:

Slot 0: Main ROM (4000h- 3fffh) mirrored in C000h-bfffh Slot 1: Main RAM 64Kb Slot 2: Cartridge Slot 3: Cartridge (in this model this is called expansion bus but it just a regular slot for cartridges)

So, as you can see, main RAM slot changes from MSX to MSX. Some programs are hardcoded and don't check were the RAM is, so they just fail.

This is not really mandatory, but opens the door to a MSX2 implementation via multimachine selector adding a VDP9938, as the rest of the hardware remains as is.

nonochus commented 1 year ago

In my humble experience with msx and I've had a few, the truth is that the 64k of ram in slot 3 is a good option, make a very compatible msx1.

If it is not in that slot, you have to use pokes, I remember a philips vg8020/40 that had it in slot 3-2.I think the problem in msx1 is ram in subslots,but not sure

Being the vg8020/00 and the sony hb75 (ram in slot 2 i think) the most compatible that I have tried.

Well, it would be nice if it were possible to be able to use other models that have other configurations as well as being able to choose the bios.

nonochus commented 1 year ago

Anyway, right now the core works very well, it is true that the SCC sounds strange, it is the only downside that I find and if as an extra, it were more configurable at the bios level and being able to select the ram slot, they would be some good extras .

I just want to thank yours efforts, I'm like when I was a child testing the core.

wwark commented 1 year ago

Thank you very much for the NTSC mode.

GuerreroNinja commented 1 year ago

Yes, changing the memory mapping is really not needed right now, RAM in slot 3 with no subslot gives the best compatibility. I was thinking about how to preserve other MSX models in an easy way, as the differences are minimal. Also, it may open the door to a MSX2 implementation for a future release. I don't know, I am not a FGPA dev, just an idea.

Anyway, the core now is VERY mature and should be in the official channel, as for me it is better than the actual MSX one, which lacks disk drive support and the ability to attach cartridges to slots from OSD. THIS should be the official MSX and the OCM based should be a MSX "extended" or "upgraded" or something like that. Anyway, I don't want to open a debate in a Github issue :)

nonochus commented 1 year ago

Without wanting to enter into a debate, for me this core is also better than the OCM without the intention of despising it.

It seems to me a core that is closer to what a real msx is at the hardware level, tapes, disks and roms can be loaded from the OSD without using software.

I don't know anything about FPGA DEV either, they are just suggestions so that a core that works very well, still has more extras. Just as a suggestion, if these requests were viable, it would be to put an "Advanced" section or something similar in the OSD, entering this section that would make it possible to change bios and ram slot, always leaving a default option for those who do not know what they are doing can return to the original configuration intended for this core.

In itself they are only extras, but it would be very good.

Excuse my English .... I hope you understand me.

An really, very thanks for the core.

tdlabac commented 1 year ago

One of the first reasons I don't really want to load the ROM BIOS is the different key layout. For each BIOS you would have to deal with how the keys are hardware connected. I base this on the differences between the VG8010 and VG8020 that my core is based on, and I have a wiring diagram for them. The keys are completely different hardware wise.

I also apologize for the translator. I couldn't have done it without it.

nonochus commented 1 year ago

You are well understood, it is true, it is not so easy to change the bios, the keyboard mapping can be a big problem and that without taking into account that Japanese keyboard support would have to be added for certain Japanese bios ...... there was not take into account the keyboard.

For me the bios is fine, if you see the possibility of changing the slots, great, otherwise the core works fine, they are just extras.

I've been testing it for a couple of hours and only the scc that doesn't sound like it should, everything else has worked perfectly for me.

Please, look at the SCC when you can, without hurry, take the time you need. It is the only thing that I have been able to see that is not 100%

Thank you very much for attending us.

P.D: what is your native language? Spanish here...

GuerreroNinja commented 1 year ago

I see, the BIOS keyboard layout may be a problem. So far, as @nonochus said, the current implementation is the best in order to provide the best compatibility and the core, as it is now, is really flexible and accurate, so no need to complicate it further.

I close this [ENHANCEMENT] petition, it may not be feasible in a practical way.

wwark commented 1 year ago

Is the HB 501 could be compatible on Rom Side with VG-8020 ?

for VG-8020 image

https://www.msx.org/wiki/Category:Sony_HB-501

image

Edit : or https://www.msx.org/wiki/Canon_V-20 this one is japanese one. image

GuerreroNinja commented 1 year ago

ROM may show differences (keyboard layout?), but in a practical way, the 3 are the same machine.

wwark commented 1 year ago

I tried Canon V-20 (japanese bios) on Mame but the hiragana of some games Jagur 5 are not ok ... like below 20221107_170720-Jagur 5 (1987)(Hudson Soft)(Japan)(MSX1)(ASCII16)

The only MSX1 with good hiragana are flag msxjp on Mame but check on them and all have different slot map in comparison of VG-8020 .

COMP(1983, fmx,        0,        0,     fmx,        msxjp,    msx_state, empty_init, "Fujitsu", "FM-X (MSX1)", 0)
COMP(1984, mbh2,       0,        0,     mbh2,       msxjp,    msx_state, empty_init, "Hitachi", "MB-H2 (MSX1)", 0)
COMP(1984, mbh25,      0,        0,     mbh25,      msxjp,    msx_state, empty_init, "Hitachi", "MB-H25 (MSX1)", 0)
COMP(1983, mbh50,      0,        0,     mbh50,      msxjp,    msx_state, empty_init, "Hitachi", "MB-H50 (MSX1)", 0)
COMP(1984, mlf110,     0,        0,     mlf110,     msxjp,    msx_state, empty_init, "Mitsubishi", "ML-F110 (MSX1)", 0)
COMP(1984, mlf120,     0,        0,     mlf120,     msxjp,    msx_state, empty_init, "Mitsubishi", "ML-F120 (MSX1)", 0)
COMP(1984, cf1200,     0,        0,     cf1200,     msxjp,    msx_state, empty_init, "National / Matsushita", "CF-1200 (Japan) (MSX1)", 0)
COMP(1983, cf2000,     0,        0,     cf2000,     msxjp,    msx_state, empty_init, "National / Matsushita", "CF-2000 (Japan) (MSX1)", 0)
COMP(1984, cf2700,     0,        0,     cf2700,     msxjp,    msx_state, empty_init, "National / Matsushita", "CF-2700 (Japan) (MSX1)", 0)
COMP(1984, cf3000,     0,        0,     cf3000,     msxjp,    msx_state, empty_init, "National / Matsushita", "CF-3000 (Japan) (MSX1)", 0)
COMP(1985, cf3300,     0,        0,     cf3300,     msxjp,    msx_state, empty_init, "National / Matsushita", "CF-3300 (Japan) (MSX1)", 0)
COMP(1985, fs1300,     0,        0,     fs1300,     msxjp,    msx_state, empty_init, "National / Matsushita", "FS-1300 (Japan) (MSX1)", 0)
COMP(1985, fs4000,     0,        0,     fs4000,     msxjp,    msx_state, empty_init, "National / Matsushita", "FS-4000 (Japan) (MSX1)", 0)
COMP(1985, fs4000a,    fs4000,   0,     fs4000a,    msxjp,    msx_state, empty_init, "National / Matsushita", "FS-4000 (alt) (Japan) (MSX1)", 0)
COMP(1984, piopxv60,   piopx7,   0,     piopxv60,   msxjp,    msx_state, empty_init, "Pioneer", "PX-V60 (MSX1)", 0)
COMP(1985, mpc64,      0,        0,     mpc64,      msxjp,    msx_state, empty_init, "Sanyo", "MPC-64 (MSX1)", 0)
COMP(198?, hb10,       hb10p,    0,     hb10,       msxjp,    msx_state, empty_init, "Sony", "HB-10 (MSX1)", 0)
COMP(1985, hb201,      hb201p,   0,     hb201,      msxjp,    msx_state, empty_init, "Sony", "HB-201 (Japan) (MSX1)", 0)
COMP(1983, hb55,       hb55p,    0,     hb55,       msxjp,    msx_state, empty_init, "Sony", "HB-55 (MSX1)", 0)
COMP(1984, hb701fd,    0,        0,     hb701fd,    msxjp,    msx_state, empty_init, "Sony", "HB-701FD (MSX1)", 0)
COMP(1984, hx10d,      hx10,     0,     hx10d,      msxjp,    msx_state, empty_init, "Toshiba", "HX-10D (MSX1)", 0)
COMP(1984, hx10dp,     hx10,     0,     hx10dp,     msxjp,    msx_state, empty_init, "Toshiba", "HX-10DP (MSX1)", 0)
COMP(1984, hx10sa,     hx10,     0,     hx10sa,     msxjp,    msx_state, empty_init, "Toshiba", "HX-10SA (MSX1)", 0)
COMP(1984, hx21,       0,        0,     hx21,       msxjp,    msx_state, empty_init, "Toshiba", "HX-21 (MSX1)", MACHINE_NOT_WORKING) // Does not go into firmware
COMP(1984, hx22,       0,        0,     hx22,       msxjp,    msx_state, empty_init, "Toshiba", "HX-22 (MSX1)", MACHINE_NOT_WORKING) // Does not go into firmware
COMP(198?, hc5,        hc7,      0,     hc5,        msxjp,    msx_state, empty_init, "Victor", "HC-5 (MSX1)", 0)
COMP(198?, hc6,        hc7,      0,     hc6,        msxjp,    msx_state, empty_init, "Victor", "HC-6 (MSX1)", 0)
COMP(198?, hc7,        0,        0,     hc7,        msxjp,    msx_state, empty_init, "Victor", "HC-7 (MSX1)", 0)
COMP(1984, cx5f1,      cx5f,     0,     cx5f1,      msxjp,    msx_state, empty_init, "Yamaha", "CX5F (w/SFG01) (MSX1)", 0)
COMP(1984, cx5f,       0,        0,     cx5f,       msxjp,    msx_state, empty_init, "Yamaha", "CX5F (w/SFG05) (MSX1)", 0)
COMP(198?, victhc90,   victhc95, 0,     victhc90,   msxjp,    msx2_state, empty_init, "Victor", "HC-90 (MSX2)", MACHINE_NOT_WORKING) // 2nd cpu/turbo not emulated, firmware won't start
COMP(1986, victhc95,   0,        0,     victhc95,   msxjp,    msx2_state, empty_init, "Victor", "HC-95 (MSX2)", MACHINE_NOT_WORKING) // 2nd cpu/turbo not emulated, firmware won't start
COMP(1986, victhc95a,  victhc95, 0,     victhc95a,  msxjp,    msx2_state, empty_init, "Victor", "HC-95A (MSX2)", MACHINE_NOT_WORKING) // 2nd cpu/turbo not emulated, firmware won't start
tdlabac commented 1 year ago

For experimenters, I have added an advanced menu.

nonochus commented 1 year ago

1667849967038 with japanese bios (see bluemsx resource section) game Jagur hiragana are OK!!!!

nonochus commented 1 year ago

Tested:

MSX Arabic.ROM MSX Brazilian.rom MSX Japanese.rom MSX Spanish.rom

Keyboard mapping seens to work as expected, for example, "ñ" in spanish right to letter "l" where must be.":" are SHIFT plus º left of number "1" and " is right letter Ñ Japanese the " is SHIFT + 2

the core remaps the keyboard ok all letters as long I test are, maybe in other keys but are working.More test needed, but seens ok

nonochus commented 1 year ago

Is nice to see japanes or brasilian boot!

nonochus commented 1 year ago

1667851437434 1667851437417

The only thing I see is that when the Brazilian bios is loaded, the image goes too far to the left, while in the other bios, it is centered. Perhaps real hardware Brazilian msx is like this and looks like this, I have never had a msx from brazil.

It should be warned that if another BIOS is loaded the keyboard remapping/layout may change and seems to change to how the original bios keyboards were intended, the keys are maybe somewhere else but generally they are where they should be on real hardware until where I have tried.

About the slots, the advanced device could be like this if this feature is possible:

Load bios *.rom slot 1: Cartridge Slot 1 / Cartridge Slot 2 / 64k RAM slot 2: Cartridge Slot 1 / Cartridge Slot 2 / 64k RAM slot 3: Cartridge Slot 1 / Cartridge Slot 2 / 64k RAM

Then for an example, a Canon V-20 japanese. Load bios *.rom Load Japanese MSX bios OR canon vc-20 bios slot 1: Cartridge Slot 1 slot 2: Cartridge Slot 2 slot 3: 64k RAM

Sony HB-75 Load bios *.rom Load HB-75 bios slot 1: Cartridge Slot 1 slot 2: 64k RAM slot 3: Cartridge Slot 2

Experimental MSX1: Load bios *.rom Load Japanese MSX bios slot 1: Cartridge Slot 1 slot 2: 64k RAM slot 3: 64k RAM

In this experimental model a cartridge slot is lost but the ram is increased by 64k more, perhaps in this way it will be possible to load the .CAS of the SWIV game that asks for 128k?????

Thank you very much, the core improves more and more every day!

GuerreroNinja commented 1 year ago

Wow this is just FANTASTIC! Thank you Tomas, I am going to do some experiments on this once I dinner :D.

I reopen this so we can track the changes easier.

wwark commented 1 year ago

Thanks a lot !!!!

wwark commented 1 year ago

Confirmed with JP Bios my japanese keyboard print " with SHIFT + 2 and the hiragana with Jaguar 5 are ok now :+1:

nonochus commented 1 year ago

V20g Keyboarb layout/mapping is working well as far as I test, there are a lot of diferrents msx models, but in general, the bios maps the keyboard as is in real hardware, I attached a photo of japanese canon v20 and " is shift + 2 for example.Bios loading is working well.

tdlabac commented 1 year ago

P.D: what is your native language? Spanish here...

My native language is Czech

nonochus commented 1 year ago

I'm not talking about Czech at all, what you put is well understood and we're starting to understand each other.

I am very grateful for the core, the msx was my first computer and I have great love and nostalgia for it.

Thank you very much for making this core better and better.

nonochus commented 1 year ago

do you have paypal or patreon to make a small donation for your efforts??

I would be happy to make a donation.

GuerreroNinja commented 1 year ago

I would be willing to contribute also

wwark commented 1 year ago

For the change of the bios, it could be great to persist it like the gameboy bioses or C64 kernals. On C64 or Gameboy, the bios/kernal selected is stored in /media/fat/config and the core used it if present. Thanks !!

tdlabac commented 1 year ago

For the change of the bios, it could be great to persist it like the gameboy bioses or C64 kernals. On C64 or Gameboy, the bios/kernal selected is stored in /media/fat/config and the core used it if present. Thanks !!

That's easy. But the repository is /media/fat/games/MSX1 Core requires the ROM name as mentioned boot.rom Feature present in next release.

wwark commented 1 year ago

Thank you will test it on next version !

wwark commented 1 year ago

Testing after compiled the last commit. It is working great with boot.rom ! Thanks

juntaesu commented 1 year ago

First of all, many thanks for this great MSX1 core ever.

Now I'd like to talk about Korean MSX1. There is additional bios for Korean input system. Screenshot_20221125_210740

If we increase the rom size from 32kB to 64kB, the system can access the hangul ROM in 0x8000-0xBFFF.

I modified the code like below. image0 image

Then I could successfully launch the Korean MSX. 20221122_013847

Is there any chance to support loading Korean Bios rom?

tdlabac commented 1 year ago

Is there any chance to support loading Korean Bios rom?

I think it's possible.