Reply 140 of 147, by Tiido
- Rank
- l33t
These are such great results ~
T-04YBSC, a new YMF71x based sound card & Official VOGONS thread about it
Newly made 4MB 60ns 30pin SIMMs ~
mida sa loed ? nagunii aru ei saa 😜
These are such great results ~
T-04YBSC, a new YMF71x based sound card & Official VOGONS thread about it
Newly made 4MB 60ns 30pin SIMMs ~
mida sa loed ? nagunii aru ei saa 😜
@Tiido Thanks!
Some more updates/fixes/etc:
Audio related:
-laptop headphone jack now works (and mutes internal speakers when something is plugged in)
-docking station jack (had horrible screeching, fixed from coreboot) now works (and mutes internal speakers when something is plugged in)
-hotplugging the laptop in the docking station, audio behaves as one would expect
-mute (internal speakers & headphone jacks) now works
-laptop multimedia keys (Mute, Volume Up/Down) now work even in Windows98
Video related:
-the previously fixed 1280x1024 VESA mode that worked with regular HDMI monitors did not work with the scaler used on the MXM card. Patched the VBIOS to adjust timings, fixed now.
-320x200 mode did not work with any monitor even on reference DVI V4 with reference BIOS. Only equipment that accepted that signal was a HDMI analyzer. Patched the VBIOS and now that is fixed.
Everything from 320x200 up to 1920x1080 now works.
-when changing resolution, sometimes the scaler would not re-lock on the new signal. Now, when there is a pixel clock change and the MMCM relocks, the FPGA gates the TMDS signal that is fed into the scaler for 200ms. No more issues with the scaler not relocking.
-fixed a bug in the scaler firmware (was using a GPIO to indicate when it has a valid lock, which was fed into the SMC). Now that behaves properly and the SMC gates its backlight PWM output accordingly. When there is no valid signal (eg. during resolution change) the panel backlight is off. Also, when the "monitor" is turned off, now the backlight is actually off. Mostly did this for power saving reasons when system is in idle and on battery.
-during the EC bruteforcing (where the system powered off suddenly for hundreds of times) I noticed that the scaler firmware got corrupted twice. Previously, I had connected the flash WP# pin to GND to prevent these exact issues. Turns out (if one bothers to read the datasheet) that the WP# pin of the flash does not actually protect the array. It only protects the status register. From that status register one can protect the actual array to write protected. WP# connected to 3V3, so that the scaler firmware can program the status register and protect the array. Issue should be fixed now and it could allow for a nice to have feature (more on that later).
-scaler was configured to scale 16:9 resolutions full screen on the 16:9 panel. 4:3 resolutions were upscaled to 1440x1080 and black pillarboxes were added to preserve aspect ratio.
This is nice and worked just fine, but DOS resolutions, like 720x400, are widescreen, and were stretched to fill the whole panel. This is not correct, as even if those are 16:10, they were meant to be viewed on 4:3 displays. Reworked scaler firmware so now it detects those modes and forces 4:3 aspect ratio.
720x400, 640x400, 640x350, 720x350 are now upscaled and 4:3 aspect ratio is preserved.
16:9 content:
4:3 content:
16:10 DOS modes:
This is all handled automatically, no need to configure anything.
One thing that bothered me is that now the BIOS setup screen (720x400) was not fullscreen anymore (stretched looked fine to me, screenshots on the previous page). Since I didn't want to figure how to render in 16:9 graphics mode, I added an override for that. Made BIOS/SMC firmware/scaler firmware changes, so now, when the system either cold boots or is reset (the SMC monitors the PCI reset signal), the default setting is that the force DOS resolutions to 4:3 is disabled. Just before SeaBIOS starts booting from an actual device (HDD/SSD/USB etc), the override is lifted. Thus, only when in SeaBIOS, the DOS 16:10 content is actually fullscreen (and if it fails to boot from a device and goes back to the boot menu, the override is restored).
It took some doing, but I finally got the scaler's UART and I2C3 working (that devboard I made a while ago sure was useful for iterating fast as the firmware could be updated via HDMI with an Intel or Nvidia card).
I2C3 is routed to the VSA-100. Switched the VSA's I2C from the dedicated EDID EEPROM to the scaler's I2C3 (the hardware already allowed for that). Baked the EDID into the scaler firmware.
And, to the feature that actually matters, now the scaler's firmware can be updated via the VSA's DDC I2C (Linux only). Really nice not having to tear the laptop down, remove the flash IC, program it externally and put it all back together for flashing a new firmware.
The UART is connected to the SMC (which talks to the host via the PCIe to PCI bridge GPIOs), which means that the host can now control the scaler's functionality. Now, from either the BIOS setup or the DOS application or the win32 application, the following can be changed (all non-volatile, saved into the SMC's FRAM and applied automatically):
-contrast
-white balance
-edge enhancement
-and ,most importantly, selectable upscaling filters with programmable parameters. This is really a nice feature and allows one to really tune how the upscaled image looks like.
All these setting apply live, with 0 screen downtime.
Really hard to take good photos of how the screen actually looks, just a small sample:
Worth mentioning that the whole chain (VSA-100 -> FPGA -> Scaler -> LVDS panel) does 70Hz, there is no frame skipping. For example DOS 720x400@70Hz is upscaled while forcing 4:3 aspect ratio to fit 1080 vertically, centered, black bars added on each side. The signal fed into the panel is 1920x1080@70Hz.
One could make a pretty decent retro monitor with the scaler IC + current firmware and a good quality LVDS panel.
A few other fixes/updates worth mentioning:
-added BIOS setup option to set how USB disks are mapped to fixed disks (auto: only the boot device (if USB) is mapped as a fixed disk, all: all USB disks are mapped as fixed disks. Latter useful in DOS, not so much under 98 where one USB disk would appear at the same time as a fixed disk and remove storage (thus auto option)).
-downgraded SMBIOS to 2.4, Sisoft Sandra no longer blue screens when reading MB info
-investigated suspend S3. Under XP it does work, but waking from S3 results in the wrong color format on the digital video output. Because the card is powered off in S3, VSA's vidInFormat[8] and vidInFormat[22] lose the values programmed during option ROM execution and the wrong color format is set. Same thing happens on OEM V4 in a regular PC. Windows98 would also wake from S3, but go to a blue screen quite quickly. Since 98 is really not happy about S3, and there is nothing I can do about the power loss (there is no power at the MXM connector while in S3), I axed S3 support. The system no longer advertises those capabilities, so standby no longer appears as an option under 98/XP/etc. Not a huge deal, the system boots fast enough anyway.
-adding this here as it's relevant VSA100-modefix
I am yet again expressing how great these efforts are, the results are awesome ~
T-04YBSC, a new YMF71x based sound card & Official VOGONS thread about it
Newly made 4MB 60ns 30pin SIMMs ~
mida sa loed ? nagunii aru ei saa 😜
Thank you Tiido!
A few more updates:
-eventually connected a logic analyzer to the primary LPC bus (on yet another M4800, running OEM firmware), and managed to sniff what the system and EC chips were doing during dock init, docking and undocking. Got a bit lucky and enabling the LPC bridge took a lot less than I expected. After that it was only a matter of configuring the SuperIO.
Added COM/LPT setup options to the Setup page.
One can select between COM1 3F8h IRQ4 / COM2 2F8h IRQ3 / COM3 3E8h IRQ4 / COM4 2E8h IRQ3 and LPT1 378h (polled) / LPT2 278h IRQ5 (with the option to select AT / PS/2 / ECP).
IRQ7 is not available for LPT1, as it is used by the HDA. Can't really move it to another IRQ. It would work under W98, but under DOS, when using SBEMU, JEMMEX crashes if HDA is not on IRQ7. At the moment I have no idea why this happens, and already investigated this before.
COM port tested under DOS/Win98/WinXP/Linux, LPT tested with internal loopback under Linux and by probing some pins (I don't have any LPT device to test with).
Undocking on the other hand (without freezing the system while doing so), that was a huge can of worms. It works now, but it is a bit of a hack at the moment. Will address it at some point in the future.
Besides the dock SuperIO working, there is now a working LPC bus in the docking station. One could connect there rasteri's dISAppointment, or, with a little glue logic (eg. small FPGA), a real OPL3 IC.
-finished the rest of the CPU related setup options. Besides CPU turbo, now a clock cap can be selected (no cap/800MHz/ 1.2GHz/1.6GHz/2GHz/2.4GHz), hyperthreading can be enabled/disabled, CPU cores can be enabled or disabled (1/2/4) and the CPU caches can be enabled or disabled.
Also made some other fixes, with no cap and turbo enabled, the CPU (in this case i7-4800MQ) does 3.7GHz under 98/XP/Linux (before, under 98 and XP it would only do 3.2GHz, still above the base clock of 2.7GHz, but far from 3.7GHz).
With these, one can really tune performance (eg. Outlive (Windows game) isn't really playable on a fast CPU, but with the CPU capped at 800MHz, there are no issues).
Or cripple the system, eg:
DOOM, max details, FreeDOS, i7-4800MQ (2.7GHz Base clock, 3.7GHz boost clock), without MTRRLFBE or FASTVID
no cap, caches on -> 83.92FPS
no cap, caches off -> 3.65FPS
800MHz, caches on -> 62.71FPS
800MHz, caches off -> 1.33FPS
I think I'm mostly done with the coreboot/SeaBIOS part for now. Next step is designing some hardware.
sdz wrote on 2026-07-27, 11:24:I think I'm mostly done with the coreboot/SeaBIOS part for now. Next step is designing some hardware.
Yeah... about that.
-I noticed that if I booted into Linux and then did a reboot, SeaBIOS would list the SD card reader (O2 OZ777) as a bootable option. Which meant that SeaBIOS could boot from it if it's properly initialized and that the controller does not reset its internal registers during reboot (it's a PCIe device, PERST# is routed to it, which is asserted during a system reboot). Took a look at the relevant Linux bits, added that in coreboot, and now SeaBIOS can boot from SD card, even when doing a cold boot.
-finally got an eSATA to SATA cable, enabled the laptop and dock eSATA ports. Those work, both as a bootable device and as a device in the OS (W98, XP, Linux). No hotplug support for obvious reasons.
SeaBIOS can now boot from:
-internal 2.5" SATA HDD/SSD
-internal mSATA
-internal SATA ODD
-internal PCIe SD card reader
-external eSATA drive (@ dock or laptop)
-external USB device (flash drive, HDD, ODD, card reader)
-made a basic W98 driver for the PCIe card reader (no interrupt support at the moment, it does ~20MB/s read/write). It currently does up to High Speed (50MHz) @4 bit. UHS modes will fallback to that.
Supports hotplug, ejecting the card, inserting a different card etc.
-Windows98 can now be installed and runs in AHCI mode (it worked fine in IDE mode, it's just that I wanted to have XP in AHCI instead of IDE, and going to the BIOS setup and changing the SATA controller between AHCI/IDE native is a bit annoying). There's still some work to be done here, as it sometimes freezes during installation for some reason (it would help if Windows98 wouldn't wedge itself during setup if SeaBIOS is using the COM port for sending debug info). However, once the AHCI driver (R. Loew's) takes over, there are absolutely no issues. In synthetic benchmarks it performs about the same as IDE native mode (under 98), around 400MB/s. Of course, this opened a whole new can of worms (bugs). Fixed those.
Also dropped IDE legacy mode from the BIOS setup (the functionality is still there, it's just not exposed anymore), as there isn't really a good reason to choose IDE legacy mode instead of IDE native mode.
-added BIOS setup enable/disable options for the internal radios (WLAN/WWAN/Bluetooth). The laptop also has a wireless kill switch. Updated the undock SMM handler to probe the EC for the radio kill switch status. If that is asserted, it sends back to the EC the command to disable all radios. If it's flipped back on, it enables only the radios that were previously enabled in the BIOS setup.
It is very pleasant looking at this Windows98 Device Manager screen on an I7 4th gen system.
For now, I really think I'm done with the firmware part. Time for that hardware...
An important part of a laptop is wireless connectivity. Now, porting modern WiFi drivers to windows98, while not impossible, is very difficult due to multiple reasons. Sourcing an era apropiate WiFi card is an option, but one would need to use an open network or very deprecated security. So, third option, make a custom WiFi card that works under 98 (but not limited to), supports modern security standards (and does that by itself and not rely on the OS for that). Also, the OS doesn't need to understand WiFi at all, it basically sees it as a copper ethernet card.
1. AetherPHY (initial name was AetherNET, which was way better, but that is already taken and I don't feel like getting a C&D for an open source project).
This is a very simple card, based on an ESP32-S3 MCU. It supports 802.11 b/g/n, 2.4GHz only and WPA2-Personal / WPA3-Personal / WPA2-Enterprise / WPA3-Enterprise (128-bit). WEP and WPA can be supported but are currently disabled in the firmware.
Actual W98 host to another machine transfer rate (TCP) is around 7Mbps RX/TX. Since this MCU only has an USB 2.0 Full-Speed (12 Mbps), this is expected and quite decent.
2. AetherPHY PRO
A more complex card, this is based on an iMX6ULL SOC (Cortex A7 CPU running at 900MHz), 512MB DDR3L, 4GB eMMC and an SDIO WiFi module. It's basically a small computer, running Linux. It supports 802.11 a/b/g/n/ac, 2.4GHz/5GHz and WPA2-Personal / WPA3-Personal / WPA2-Enterprise / WPA3-Enterprise (128-bit). WEP and WPA can be supported but are currently disabled in the firmware.
I made the design a bit too compact so I decided to add a display as well for debug info/bling since there was room for it.
Actual W98 host to another machine transfer rate (TCP) is around 55Mbps RX/TX. Under a Linux host it does around 70Mbps.
A few things to mention:
-both these cards fit and work in the mSATA slot, so the laptop's miniPCIe slot can retain the original WiFi card
- both cards (ESP32 and IMX6) use the same driver and work with the same config application
-both cards turn off their radios if one switches on the laptop's wireless kill switch and they both assert the laptop's WiFi LED indicator (and work alongside the miniPCIe card if it's installed).
Regarding audio, VOPL3 now (besides OPL3 emulation) supports MPU401 UART and intelligent mode bridge. A DOS game running under W98 is no longer limited to Microsoft GS Wavetable software synth, any MIDI device can be selected.
I had this working for quite some time, but just recently made a proper PCB for it.
It's an USB to MIDI adapter, that works under Windows98. Based on an ESP32-S3 MCU. With VOPL3 and this (currently named MIDI98 until I can think of something better) I can run DOS games under Windows98 and use an actual Roland MT-32/SC-55/SC-88 etc.
If on the go, there is also this, based on nukeykt's Nuked-SC55, and VOPL3 can redirect to it as well:
An MT-32 version is also in the works.
Regarding the above projects (WiFi cards and USB MIDI adapters), I'll open source and publish them when I have some free time. Not sure about the AetherPHY PRO, as that one is quite expensive to make (via in pad, 10 layers etc) and not everyone can assemble one (BGAs and LGAs). Also, RAM is quite expensive these days, even DDR3. The P/N I used there (didn't really need 512MB for this application, just had them in stock), is around 100$ at Mouser, which is quite crazy.
I might make a V2, based on the Rockchip RV1106G2 or RV1106G3, which are still ARM SOCs, Cortex-A7, running at 1.2GHz, with either 128MB or 256MB of integrated DDR3 and come in a QFN package instead of BGA. Pair that with an easier to solder SDIO WiFi module and an SPI FLASH for the bootloader/kernel/rootfs, some PMICs and that's pretty much it. That will require a way cheaper PCB (4 layers, no via in pad) and assembly is easier since there are no BGA parts involved.
As for the laptop, I think that's pretty much it for now and I can finally assemble it and start enjoying some games. Here's what currently works:
+---------------------------------+--------------+--------------+--------------+| Hardware / function | Win98 | WinXP | Linux |+---------------------------------+--------------+--------------+--------------+| USB 2.0 | Confirmed | Confirmed | Confirmed || USB 3.0 | X | Confirmed | Confirmed || SATA HDD/SSD in AHCI mode | Confirmed | Confirmed | Confirmed || SATA HDD/SSD in IDE native mode | Confirmed | Confirmed | Confirmed || SATA HDD/SSD in IDE legacy mode | Confirmed | Confirmed | Confirmed || SATA ODD | Confirmed | Confirmed | Confirmed || mSATA | Confirmed | Confirmed | Confirmed || HDA audio | Confirmed | Confirmed | Confirmed || Ethernet | Confirmed | Confirmed | Confirmed || Wi-Fi and Bluetooth | Confirmed | Confirmed | Confirmed || SD card reader | Confirmed | Confirmed | Confirmed || ExpressCard slot | Confirmed | Confirmed | Confirmed || Internal keyboard and touchpad | Confirmed | Confirmed | Confirmed || Keyboard lock LEDs | Confirmed | Confirmed | Confirmed || RTC date and time | Confirmed | Confirmed | Confirmed || ACPI | Confirmed | Confirmed | Confirmed || AC adapter and battery state | Confirmed | Confirmed | Confirmed || Voodoo3 M3800 variants | Confirmed | Confirmed | Confirmed || Voodoo4 M4800 variants | Confirmed | Confirmed | Confirmed || Laptop VGA output | Confirmed | Confirmed | Confirmed || Laptop eSATA port | Confirmed | Confirmed | Confirmed || Docking-station VGA output | Confirmed | Confirmed | Confirmed || Docking-station USB 2.0 | Confirmed | Confirmed | Confirmed || Docking-station USB 3.0 | X | Confirmed | Confirmed || Docking-station PS/2 mouse | Confirmed | Confirmed | Confirmed || Docking-station PS/2 keyboard | Confirmed | Confirmed | Confirmed || Docking-station Ethernet | Confirmed | Confirmed | Confirmed || Docking-station power button | Confirmed | Confirmed | Confirmed || Docking-station DVI/DP | X | X | X || Docking-station COM port | Confirmed | Confirmed | Confirmed || Docking-station parallel port | Confirmed | Confirmed | Confirmed || Docking-station audio jacks | Confirmed | Confirmed | Confirmed || Docking-station eSATA | Confirmed | Confirmed | Confirmed || DisplayPort and HDMI output | X | X | X || Internal panel | Confirmed | Confirmed | Confirmed[3] || 1920x1080 internal panel | Confirmed[2] | Confirmed[2] | Confirmed[3] || S3 suspend/standby | X | X | X |+---------------------------------+--------------+--------------+--------------+X = unavailable in this configuration or unsupported by that OS
USB3.0 might also work yeokm1's XHCI driver xHCI Host Controller driver for Windows 98 to 7 . I tried it a while ago but couldn't get it working. Didn't feel like reinstalling/reimaging 98, so I stopped there. I will give it another try.
As for future work on this laptop, and less off topic than what I just posted, mwdmeyer made the Velocity9x driver that also supports Haswell iGPUs Velocity9x - Open Source Win9x VGA 3D Driver S3/Intel/ATi/Matrox/NVIDIA/SiS . Might be interesting re-enabling the iGPU, keeping the V4 as the primary card (since the display is connected to that) and do something like a reverse Nvidia Optimus, where the iGPU can render and feed the output to the VSA-100.