Page 1 of 3

MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 3:22 pm
by spark2k06

I am pleased to show you the first tests on the upgrade of the MDA module from Graphics Gremlin to Hercules:

There are still some screen adjustments to be made so it doesn't look scrolled to the left, and support for the two Hercules memory pages, but I've attached a first binary for you to try out.


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 4:27 pm
by AmintaMister

THANKS!


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 5:39 pm
by kathleen

Thank you so much @spark2k06,
This is the cherry on the cake that I've been waiting since the core saw the light,


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 6:33 pm
by dmckean

I agree, the only other thing I really want to see is full PC Jr. support at some point but this is more important than that.


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 7:19 pm
by thisisamigaspeaking

Amazing, thanks, look forward to trying this out. Anyone know of a good list of games that support Hercules?


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 8:25 pm
by jordi
thisisamigaspeaking wrote: Mon Jan 16, 2023 7:19 pm

Amazing, thanks, look forward to trying this out. Anyone know of a good list of games that support Hercules?

Mobygames is not allowing filter right now

But there you have a list of games in the thread

https://www.vogons.org/viewtopic.php?t=61035

A vídeo with it
https://m.youtube.com/watch?v=DY2oKR_EtfY


Re: MDA Upgrade to Hercules

Posted: Mon Jan 16, 2023 11:40 pm
by suww37

Very nice. I was the first person to ask the developer if this was possible during this core development. I was somewhat skeptical about the development of the Hercules graphic module and I am so glad it was successful. Thank you very much for the developer's hard work.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 2:04 am
by suww37

I would also like to be supported by the cga emulation program at hercules. I tested your pcxt-hecules-test core. I run the cga emulation program "simcga.com" and run a game that supports cga, but the screen of the game does not appear.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:11 am
by jca

I suppose SimCGA was developed for PC owners having only the Hercules card and wanting to play games. With PCXT we have CGA emulation so there is no obstacle playing such games. But using SimCGA would test the implementation of Hercules, in your case it is not working at this time.
On my side I tested AutoCAD without much success: the attached screenshot is supposed to be the Columbia shuttle.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 5:50 am
by kathleen

@jca,
+1
This is also the 1st test that I did, and on my side, Autocad showed the same screen as what you got. Even the starting screen does not appear (after having selected 'a new dwg")
I tried Checkit to make the video test, only the text test worked, not the graphic one.
I also tried different Bioses and same results.
I think we've to be patient :-) The most important is that this Hercules mode is on the way.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 6:08 am
by suww37
jca wrote: Tue Jan 17, 2023 4:11 am

I suppose SimCGA was developed for PC owners having only the Hercules card and wanting to play games. With PCXT we have CGA emulation so there is no obstacle playing such games. But using SimCGA would test the implementation of Hercules, in your case it is not working at this time.
On my side I tested AutoCAD without much success: the attached screenshot is supposed to be the Columbia shuttle.

I know it well. In fact, pcxt core doesn’t need a cga emulation program like simcga because it supports cga modules. But I used simcga to run games that didn‘t support hercules on hercules xt pc 30 years ago, and the games emulating with simcga have a different unique sensibility from the orginal cga module. I think users who have nostalgia for hercules want simcga to work well in the pcxt hecules core.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 7:06 am
by wark91

Hi,
Thank you to continue to improve the PCXT core.
At the end Hercules will replace MDA or we will have 3 options MDA, Hercules and "CGA & Tandy" ?
Thanks !


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 11:11 am
by jca

The Hercules card is a MDA card with a graphic mode so there is no need to keep MDA.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 11:53 am
by EeDee

When trying Hercules mode all I see is a blinking cursor.
Do I have something set wrong?

Additional: Swapped the BIOS and all is well :roll:


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 1:32 pm
by Newsdee

Nice! I'll try when I have some time... I wanted to try Korean Dungeon Boy in Hercules


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 2:53 pm
by spark2k06

Attached is a new version. This time I have added the second 32Kb page from Hercules, so it seems that SIMCGA is now working (type CLS after execute It):

WIN_20230117_15_39_15_Pro.jpg
WIN_20230117_15_39_15_Pro.jpg (547.18 KiB) Viewed 10753 times

A curious thing happens with AlleyCat running simulated in Hercules, and that is that windows only open if CGA is also running. This has been the case so far, but now I offer the possibility to disable CGA and/or Hercules so that their I/O ports are not accessible, and the video is now also chosen separately, indicating that it is the primary video:

WIN_20230117_15_37_13_Pro.jpg
WIN_20230117_15_37_13_Pro.jpg (163.7 KiB) Viewed 10753 times

The other video is active in the background, and I intend to enable the F11 key to swap the video output between the two available for a future version. If BIOS Tandy is selected, it will force the use of the Tandy video card, without Hercules... but in a future version, choose CGA video as primary video right now to make it work.

I haven't had a chance to try AutoCAD, but it's possible that it now works with the second page of memory... if anyone can confirm this.

Edit:

I think these options will make more sense in the "System" section of the OSD menu. In the same area where the BIOS is selected, to associate them in the mind. For the next version...


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:00 pm
by suww37
spark2k06 wrote: Tue Jan 17, 2023 2:53 pm

Attached is a new version. This time I have added the second 32Kb page from Hercules, so it seems that SIMCGA is now working (type CLS after execute It):

WIN_20230117_15_39_15_Pro.jpg

A curious thing happens with AlleyCat running simulated in Hercules, and that is that windows only open if CGA is also running. This has been the case so far, but now I offer the possibility to disable CGA and/or Hercules so that their I/O ports are not accessible, and the video is now also chosen separately, indicating that it is the primary video:

WIN_20230117_15_37_13_Pro.jpg

The other video is active in the background, and I intend to enable the F11 key to swap the video output between the two available for a future version. If BIOS Tandy is selected, it will force the use of the Tandy video card, without Hercules... but in a future version, choose CGA video as primary video right now to make it work.

I haven't had a chance to try AutoCAD, but it's possible that it now works with the second page of memory... if anyone can confirm this.

Edit:

I think these options will make more sense in the "System" section of the OSD menu. In the same area where the BIOS is selected, to associate them in the mind. For the next version...

Good! Simcga is working. But the graphics are a little weird. A small bar on the left side of the game screen is attached to the right side of the screen. I see a similar phenomenon when I run another program that supports hercules without using simcga.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:22 pm
by spark2k06
suww37 wrote: Tue Jan 17, 2023 4:00 pm

Good! Simcga is working. But the graphics are a little weird. A small bar on the left side of the game screen is attached to the right side of the screen. I see a similar phenomenon when I run another program that supports hercules without using simcga.

Yes, I have identified it... there is a shift of the screen to the left. Apparently there are two resolutions used, 720x348 and 600x300... and the latter is the one that generates the scrolling.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:32 pm
by mapf
spark2k06 wrote: Tue Jan 17, 2023 4:22 pm

Yes, I have identified it... there is a shift of the screen to the left. Apparently there are two resolutions used, 720x348 and 600x300... and the latter is the one that generates the scrolling.

I am surprised by this. I always thought that there is only the 720x348 mode on Hercules. I did some programming on DOS as a teenager, and no graphics library offered any other mode.

Is there any documentation on this? I tried to google that mode, but found nothing.

Edit: I found the original Hercules manual here: https://minuszerodegrees.net/manuals/He ... Manual.pdf

It also makes no mention of any other graphics mode


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:36 pm
by spark2k06
mapf wrote: Tue Jan 17, 2023 4:32 pm

I am surprised by this. I always thought that there is only the 720x348 mode on Hercules. I did some programming on DOS as a teenager, and no graphics library offered any other mode.

Is there any documentation on this? I tried to google that mode, but found nothing.

Yes, I'm surprised too, but that's the output information it gives when you activate the information in MiSTer.ini... you can check it yourself, I have to do some more research to understand why it happens.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:39 pm
by mapf
spark2k06 wrote: Tue Jan 17, 2023 4:36 pm

Yes, I'm surprised too, but that's the output information it gives when you activate the information in MiSTer.ini... you can check it yourself, I have to do some more research to understand why it happens.

Now that you mention it, I see it in your youtube video. Sadly I do not know much about the communication between cores and the framework. Maybe a wrong resolution is indicated to the scaler?

(This would also explain why the patterns in the video feel wrong to me).


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:43 pm
by spark2k06
mapf wrote: Tue Jan 17, 2023 4:39 pm

Now that you mention it, I see it in your youtube video. Sadly I do not know much about the communication between cores and the framework. Maybe a wrong resolution is indicated to the scaler?

(This would also explain why the patterns in the video feel wrong to me).

At the moment I don't know, I only know that the software that makes it display 720x348, the image looks perfect... like Monkey Island, among others.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 4:46 pm
by jca

Thanks, there is a big improvement: a shuttle looking like a shuttle.
There is still something not quite right and I think this 600x300 resolution is wrong, it does not exist. There has to be some kind of bug in the Hercules code.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 5:01 pm
by jca

The problem is not with the scaler. Attached a screenshot before scaling: size 720x348.
I have the bar on the right side and the text is sort of illegible.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 5:11 pm
by jca

I checked the 1st screenshot size, made after scaling: it is 1440x1080. It seems odd: 1440 is 720x2 but 1080 is not 384x2. On the other hand it is closer to what it should be. I guess the saler does a very good job and the snapshot before scaling looks odd due to non square pixels.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 5:12 pm
by mapf

If a 720x348 pixel image is rendered on a 600x300 plane, information is lost. Scaling back will not recover that information.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 5:25 pm
by jca
mapf wrote: Tue Jan 17, 2023 5:12 pm

If a 720x348 pixel image is rendered on a 600x300 plane, information is lost. Scaling back will not recover that information.

I doubt it: pressing WIN + Left Shit + Print Screen produces a snapshot before scaling and the resolution is 720x348.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 7:58 pm
by wark91

Is it normal on hercule mode :
720*350 31.76Khz and 70.7Hz.
70.7Hz will imply some screens will not accept it and lost sync.


Re: MDA Upgrade to Hercules

Posted: Tue Jan 17, 2023 8:43 pm
by Newsdee

I found some discussion of resolution and frequencies here:
https://forum.vcfed.org/index.php?threa ... eth.52966/

Couple of things stand out: the clock ought to be 16Mhz (and not 16.25Mhz like some IBM card had), and there are a couple of undocumented graphics modes that not all cards supported: 720x360 and interlaced 640x400.

original HGC (GB102) - 16 MHz
HGC+ (GB112) - 16MHz
EPSON Q205A (Hercules/CGA "dual") - 16M7C
MGP-6A, based on W86855AF - 16.000
3088D, based on TD 3088 A2 - 16.000
DT-5138, based on TD3088A - 16257
noname based on MS61C88 - 16.000
JET-MGP 3088-A2, based on TD3088A - 16.000
HI RES 4/4WPP, based on PVC4 (Hercules/CGA "dual") - 16.2570


Re: MDA Upgrade to Hercules

Posted: Wed Jan 18, 2023 5:05 pm
by spark2k06

Attached is a new version, this time I have moved the graphics card selection options to the System & BIOS section:

System_And_BIOS.jpg
System_And_BIOS.jpg (173.72 KiB) Viewed 10296 times

Here I will clarify some aspects of the issue:

  • The three new options only work with the IBM PCXT model, if Tandy 1000 is set, Hercules is not available and only works with CGA/Tandy.

  • As these are options for the PCXT model, I do not refer to Tandy, simply CGA.

  • 1st Video refers to the video card that will be used by default when starting the core in the PCXT model (Tandy/CGA will always work with Tandy 1000 model).

  • Only in PCXT model is it possible to swap between video cards for on-screen display with F11 key (Tandy/CGA will always work with Tandy 1000 model).

  • The first two options are to keep the I/O ports of the cards active, it may be interesting to deactivate some of these, but in general it is recommended to keep both cards active. With the Tandy 1000 model, these options are ignored.

It would be interesting to be able to disable these three options in the menu when the Tandy 1000 model is selected, but I don't know if it can be done... I'll see if I can check the information in the wiki:

https://github.com/MiSTer-devel/Wiki_Mi ... ion-string

As can be seen in some other common sections of the cores:

Disable_Options.jpg
Disable_Options.jpg (166.66 KiB) Viewed 10296 times

On the other hand, I have been reviewing the recommended values of the CRTC registers:

https://www.seasip.info/VintagePC/hercplus.html

CRTC_Registers_HGC.png
CRTC_Registers_HGC.png (55.61 KiB) Viewed 10296 times

The default core starts with the register values corresponding to "80 column text", here MiSTer identifies it as 720x350 and works without problems.

Software that MiSTer identifies as 720x348 in graphics mode correctly, use the register values corresponding to the "Graphics" section of this table.

When MiSTer identifies, apparently erroneously, the 640x300 resolution, it uses register values like these (Games CGA with SIMCGA and Prehistorik, for example...):

CRTC_Registers.png
CRTC_Registers.png (10.63 KiB) Viewed 10296 times

I tried forcing the recommended register values for graphic mode, but then the image looks bad (this is the cover of Prehistorik):

720_348_Forced.jpg
720_348_Forced.jpg (691.76 KiB) Viewed 10296 times

At this point I don't know what else to look at to solve it, so I've opted to leave it as it is now. Tomorrow I will prepare and publish the source code of the development carried out so far in case there is someone who can think of a solution... otherwise, we will have to make do with what we have.

Be that as it may, in the next few days I will make all these changes public in the main branch, so that all users can enjoy it, despite this problem.