VOGONS


ESFM reverse-engineered

Topic actions

First post, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

Hi all,

Haven't visited these forums in a while, but I've been working on something
that I know some of you will find interesting.
You've read the title so you know what it is. I figured out the ESFM register
map. As far as I'm aware, this hasn't been done before.

I published everything I discovered in a github repository, here:

https://github.com/jwt27/esfm

There may still be some small details left to find, but what I have so far
should be enough to write a complete driver and editor.

Just wanted to share that. Happy new year everyone!

Reply 1 of 24, by mkarcher

User metadata
Rank l33t
Rank
l33t

Great documentation! I like it.

Reply 2 of 24, by Gmlb256

User metadata
Rank l33t
Rank
l33t

Excellent! 👍

VIA C3 Nehemiah 1.2A @ 1.46 GHz | ASUS P2-99 | 256 MB PC133 SDRAM | GeForce3 Ti 200 64 MB | Voodoo2 12 MB | SBLive! | AWE64 | SBPro2 | GUS

Reply 3 of 24, by Joseph_Joestar

User metadata
Rank l33t
Rank
l33t
jwt27 wrote on 2023-01-01, 17:19:

I figured out the ESFM register
map. As far as I'm aware, this hasn't been done before.

Thank you very much for documenting this!

BTW, we've been testing some games with native ESFM support in this thread. It can sound really nice when the developers use it properly.

PC#1: Pentium MMX 166 / Soyo SY-5BT / S3 Trio64V+ / Voodoo1 / YMF719 / AWE64 Gold / SC-155
PC#2: AthlonXP 2100+ / ECS K7VTA3 / Voodoo3 / Audigy2 / Vortex2
PC#3: Athlon64 3400+ / Asus K8V-MX / 5900XT / Audigy2
PC#4: i5-3570K / MSI Z77A-G43 / GTX 970 / X-Fi

Reply 4 of 24, by igna78

User metadata
Rank Member
Rank
Member

Truly many compliments and a huge thank you
I am sure that the gift you have given to the whole community will be appreciated by all considering the possibilities it will give 😄

Reply 5 of 24, by Error 0x7CF

User metadata
Rank Member
Rank
Member

18 4-op voices with more flexibility than an OPL3?
Wow, what an underused chip.

Great work!

Old precedes antique.

Reply 6 of 24, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie

Thanks everyone, appreciate the compliments. I just found some more registers and will document these shortly.

Joseph_Joestar wrote on 2023-01-01, 19:05:

Thank you very much for documenting this!

BTW, we've been testing some games with native ESFM support in this thread. It can sound really nice when the developers use it properly.

I think all games mentioned there use the same Miles Sound System driver, so they all use the same preset bank. If there are any games that do use a different driver I would be very interested to know.

Reply 7 of 24, by the3dfxdude

User metadata
Rank Oldbie
Rank
Oldbie

Is there any more reason we know now of why the sound is muffled when using native ESFM? Is this a driver bug?

Reply 8 of 24, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
the3dfxdude wrote on 2023-01-01, 21:09:

Is there any more reason we know now of why the sound is muffled when using native ESFM? Is this a driver bug?

I assume you mean muffled PCM voices? The FM synth has nothing to do with that. The PCM part of these chips is actually well documented, and they have adjustable filters. My guess is that the Miles driver just sets the cutoff frequency too low. So yes, that would be a driver bug, and it should be possible to patch it.

Reply 9 of 24, by Joseph_Joestar

User metadata
Rank l33t
Rank
l33t
the3dfxdude wrote on 2023-01-01, 21:09:

Is there any more reason we know now of why the sound is muffled when using native ESFM? Is this a driver bug?

If you mean the behavior that Phil demonstrates in this video around the 7:08 mark, that's related to digital audio when the card is working in its proprietary AudioDrive mode. This is different from the native ESFM support which refers to FM synth music.

From my observations, the muffled sound issue only occurs with games which use the HMI Sound System, such as Tomb Raider, Red Alert and Daggerfall. It doesn't happen in games which use the Miles Sound System.

PC#1: Pentium MMX 166 / Soyo SY-5BT / S3 Trio64V+ / Voodoo1 / YMF719 / AWE64 Gold / SC-155
PC#2: AthlonXP 2100+ / ECS K7VTA3 / Voodoo3 / Audigy2 / Vortex2
PC#3: Athlon64 3400+ / Asus K8V-MX / 5900XT / Audigy2
PC#4: i5-3570K / MSI Z77A-G43 / GTX 970 / X-Fi

Reply 10 of 24, by Joseph_Joestar

User metadata
Rank l33t
Rank
l33t
jwt27 wrote on 2023-01-01, 21:00:

I think all games mentioned there use the same Miles Sound System driver, so they all use the same preset bank. If there are any games that do use a different driver I would be very interested to know.

I don't know of any non-Miles DOS games that can use native ESFM.

BTW, if you haven't already seen this, the ESS 1869 datasheet (available on Phil's website) has some info on ESFM, starting from page 41.

PC#1: Pentium MMX 166 / Soyo SY-5BT / S3 Trio64V+ / Voodoo1 / YMF719 / AWE64 Gold / SC-155
PC#2: AthlonXP 2100+ / ECS K7VTA3 / Voodoo3 / Audigy2 / Vortex2
PC#3: Athlon64 3400+ / Asus K8V-MX / 5900XT / Audigy2
PC#4: i5-3570K / MSI Z77A-G43 / GTX 970 / X-Fi

Reply 11 of 24, by Stretch

User metadata
Rank Member
Rank
Member

I hope to see ESFM added to libadlmidi so I can listen to the the video game XMI files with the ESFM FM instruments.

Win 11 - Intel i7-1360p - 32 GB - Intel Iris Xe - Sound BlasterX G5

Reply 12 of 24, by the3dfxdude

User metadata
Rank Oldbie
Rank
Oldbie
jwt27 wrote on 2023-01-01, 21:59:
the3dfxdude wrote on 2023-01-01, 21:09:

Is there any more reason we know now of why the sound is muffled when using native ESFM? Is this a driver bug?

I assume you mean muffled PCM voices? The FM synth has nothing to do with that. The PCM part of these chips is actually well documented, and they have adjustable filters. My guess is that the Miles driver just sets the cutoff frequency too low. So yes, that would be a driver bug, and it should be possible to patch it.

Yes. PCM AudioDrive I suppose. But I guess fixing the muffled sound would be for another time for someone who wants to look into the driver.

Reply 13 of 24, by appiah4

User metadata
Rank l33t++
Rank
l33t++

That is amazing.

Retronautics: A digital gallery of my retro computers, hardware and projects.

Reply 14 of 24, by jwt27

User metadata
Rank Oldbie
Rank
Oldbie
Joseph_Joestar wrote on 2023-01-01, 22:38:

BTW, if you haven't already seen this, the ESS 1869 datasheet (available on Phil's website) has some info on ESFM, starting from page 41.

I've seen that. It only mentions that a "native" mode exists - there's no info on how to use it, or even what it's capable of...

Reply 15 of 24, by Joseph_Joestar

User metadata
Rank l33t
Rank
l33t
jwt27 wrote on 2023-01-02, 17:19:

I've seen that. It only mentions that a "native" mode exists - there's no info on how to use it, or even what it's capable of...

My bad, I just noticed that the register descriptions listed there are only applicable for the emulation mode.

PC#1: Pentium MMX 166 / Soyo SY-5BT / S3 Trio64V+ / Voodoo1 / YMF719 / AWE64 Gold / SC-155
PC#2: AthlonXP 2100+ / ECS K7VTA3 / Voodoo3 / Audigy2 / Vortex2
PC#3: Athlon64 3400+ / Asus K8V-MX / 5900XT / Audigy2
PC#4: i5-3570K / MSI Z77A-G43 / GTX 970 / X-Fi

Reply 16 of 24, by Paul_V

User metadata
Rank Newbie
Rank
Newbie

Awesome job there, thanks!
My cherished dream is to see ESS IC's reverse engineered, like genuine Yamaha OPL3.

A real shame it did not see it's full potential used.

Reply 17 of 24, by leecher

User metadata
Rank Newbie
Rank
Newbie

I reverse engineered the WDM ES1969 driver which uses the ESFM registers (see NATV.CPP), and compiled a 64bit driver from it, in case anyone is interested:
https://github.com/leecher1337/es1969/

Reply 18 of 24, by Rawit

User metadata
Rank Oldbie
Rank
Oldbie

I think the muffled audio problem is only occuring when a game uses Human Machine Interface drivers.

YouTube

Reply 19 of 24, by bakemono

User metadata
Rank Oldbie
Rank
Oldbie

It's fantastic that the info is out now, but I have to say it's also a bit disappointing that the ESFM still doesn't have the ability to reproduce algorithms 2,3,4 from the 4-op Yamaha chips. When I saw the thread title I was thinking an ESFM-enhanced VGM player might be in the cards, but it looks like there is still no way to feed two modulators into a single carrier. Detune is missing, which would limit accuracy as well.

again another retro game on itch: https://90soft90.itch.io/shmup-salad