Jump to content

Recommended Posts

Posted (edited)

Tutorial, how to compile a working csmwrap.efi

dietmar.stoelting@t-online.de   June 2025

 

1.) Install Ubuntu 24.04.2 LTS

2.) Type this at the command line from Ubuntu

sudo apt update
sudo apt install -y build-essential nasm git curl xxd
git clone https://github.com/FlyGoat/CSMWrap.git --recursive
cd CSMWrap
make seabios
make

 

Edited by Dietmar

Posted

@reboot12

For me, this old version 1.1.0-12 is crazy.

I do not understand, why they dont update their Sources

Dietmar

 

PS: We can make a try, with copy and paste the updated files into the install folders in Ubuntu, under CSMWrap.

This should give a version, that is better than 1.2.1.

Important is, also to compile SeaBios each time new.

Posted (edited)

@Dietmar

No, I tried like this but errors:

wget https://github.com/FlyGoat/CSMWrap/archive/refs/tags/1.2.1.tar.gz
tar -xvf 1.2.1.tar.gz
mv CSMWrap-1.2.1 csmwrap
cd csmwrap
root@ubuntu:~/csmwrap# make seabios
make -C seabios distclean
make[1]: Entering directory '/root/csmwrap/seabios'
make[1]: *** No rule to make target 'distclean'.  Stop.
make[1]: Leaving directory '/root/csmwrap/seabios'
make: *** [GNUmakefile:271: seabios] Error 2
root@ubuntu:~/csmwrap# make
make: *** No rule to make target 'nyu-efi/src/elf_x86_64_efi.lds', needed by 'bin-x86_64/csmwrap'.  Stop.

F..k, but a mess :crazy:

Edited by reboot12
Posted (edited)

OK, git corrected and now downloads the current version :D

This is full tutorial how compile CSMWrap:

Download and install Ubuntu: https://releases.ubuntu.com/noble/ubuntu-24.04.2-live-server-amd64.iso
During installation, select Install OpenSSH server - this makes it easy to copy files from Ubuntu to Windows using WinSCP and use Ubuntu over SSH e.g. in Putty
SSH-server.png

sudo passwd root (enter password for user)
sudo passwd root (make new password for root)
sudo login root or reboot and login using root
nano /etc/ssh/sshd_config

    PermitRootLogin yes
    PasswordAuthentication yes

Ctrl+o to save and Ctrl+x to exit
service ssh restart

ssh.png

apt update
apt install -y build-essential nasm curl xxd net-tools

git clone https://github.com/FlyGoat/CSMWrap.git --recursive
cd CSMWrap
make seabios
make

ifconfig - to check IP
using WinSCP make connection and connect to Ubuntu:

New Site, File protocol: SCP, Host name: IP, root User name and Password, Save
ssh-win.png WinSCP.png works-121.png

Edited by reboot12
Posted
4 minutes ago, Dietmar said:

I still do not understand,

why now you get the latest Source files from csmwrap.efi .

Is it, because you connect now to another server via

No, they probably already corrected the repository and now git clones the latest version :-)

Posted (edited)

I compile CSMWrap replacing SeaVGABIOS to ValleyView Legacy video BIOS extracted from Jetway HPC070SC industrial computer:
https://github.com/FlyGoat/CSMWrap/issues/37#issuecomment-2921265627
Risky to use on other Laptops but this is Mobile/Desktop version so should work on desktop computers:
Bay-Trail-Mobile-Desktop.png
https://files.catbox.moe/6xj4hm.zip

User win98se on github test this version, "But the graphics are glitched, and after spinning for a while" but not damaged:
https://github.com/FlyGoat/CSMWrap/issues/39#issuecomment-2977152878

bt.png

Edited by reboot12
Posted (edited)

@Dietmar

I spent a bigger half day today testing XP32 with iGPU and I have good news. XP runs best with iGPU (Haswell) on vbemp.sys (PNP) 2015 driver in co-op with my UefiSeven (u7nwbm.efi + UefiSeven.ini with set native resolution of monitor) and Longhorn 5472 bootmgr+BCD+winload.exe loader - iGPU need be set as Primary Display in bios

  • XP can be run in the native resolution of the monitor - it depends on the monitor connected and the cable used (probably also on the EDID), the aurora boot screen is badly displayed when the resolution is native but the XP desktop works fine :P
  • you can change the available resolutions - if the resolution is lower than the native one, the desktop is displayed from the top right corner without cleaning the screen - the previous content remains on the screen
  • original XP vga.sys driver works badly with UefiSeven, there are some resolutions to choose from display settings but trying to change it restarts XP

I boot XP in this way: in bios CSM Disabled (pure UEFI) > PC boot UEFI Shell from FAT32 100MB from EFI\Boot\bootx64.efi > startup.nsh starts UefiSeven and CSMWrap 1.2.1 (in UefiSeven.ini file native resolution monitor is set)

NOTE: During installation of the vbemp driver, the system reboots but after the reboot it already starts on the vbemp driver at 640x480 and you can change the resolution to another e.g. native (if UefiSeven was previously running at this resolution)

My monitor native resolution is 1360x768 but I test also other monitors native 1920x1080 and native 2560x1440 - see screenshots at bottom.

UefiSeven.ini

; UefiSeven configuration file
; 0 = false, 1 = true

[config]
skiperrors=0      ; skip warnings and prompts
force_fakevesa=0  ; overwrite Int10h handler with fakevesa even when the native handler is present
verbose=1         ; enable verbose mode
logfile=0         ; log to UefiSeven.log file
resheight=1360    ; preferred height
reswidth=768    ; preferred width

EFI\Boot\startup.nsh

@echo -off

if exist fs0:\121.efi then
set base "fs0:"
endif
if exist fs1:\121.efi then
set base "fs1:"
endif
if exist fs2:\121.efi then
set base "fs2:"
endif
if exist fs3:\121.efi then
set base "fs3:"
endif
if exist fs4:\121.efi then
set base "fs4:"
endif
if exist fs5:\121.efi then
set base "fs5:"
endif
if exist fs6:\121.efi then
set base "fs6:"
endif
if exist fs7:\121.efi then
set base "fs7:"
endif
if exist fs8:\121.efi then
set base "fs8:"
endif
if exist fs9:\121.efi then
set base "fs9:"
endif
if exist fsa:\121.efi then
set base "fsa:"
endif
if exist fsb:\121.efi then
set base "fsb:"
endif

%base%
u7nwbm.efi
121.efi

u7-csmwrap121-vbemp-monitor-1360x768.png u7-csmwrap121-vbemp-monitor-1920x1080.pn u7-csmwrap121-vbemp-monitor-2560x1440.pn

If we run the XP without UefiSeven then OS boot in 1024x768 and there are only 3 resolutions available (no native):
no-Uefi-Seven.png

Edited by reboot12
  • 2 weeks later...
Posted

@Dietmar

 

What about N100? Did you test CSMwrap there?

 

I tested it briefly but all I got is CSMwrap complaining about the above 4G address, no matter how I set the related setting in the UEFI setting page.

Posted (edited)

@Dietmar

A CSMWrap version has been released, which allows you to use the BIOS video from the disk from EFI\Boot\vgabios.bin
https://github.com/FlyGoat/CSMWrap/issues/37#issuecomment-3030297746

Compiled bins: https://github.com/FlyGoat/CSMWrap/actions/runs/16040013218

Thanks to this, WinXP boot OK on iGPU using ntldr as on a normal Legacy machine :cheerleader: - I tested CoffeeLake, Haswell, SandyBridge: CSM Disabled, iGPU VBIOS extracted from motherboard bios.

Now - I don't have to use SeaVGABIOS and Longhorn bootmgr 5472 loader.

Edited by reboot12
Posted

Hi, please could someone help with proper configuration of $VBT of CherryView VBIOS for built in LCD?

My problem is that I have some old netbook TrekStor SurfTab twin 11.6 with Intel Atom x5-Z8350 CPU @ 1.44GHz. It has AMI Aptio UEFI 32-bit without CSM and without legacy VBIOS at all. Recently I got know about CSMWrap project and tried it on this machine hoping I could run at least DOS and some DOS apps/games. But there's a catch that if no VBIOS present CSMWrap use fallback SeaBIOS VBE that is very limited and cannot draw properly even most of DOS TUI programs like EDIT or file managers... CSMWrap was now extended to allow to load VBIOS images.

So I downloaded the package from winraid thread [ http://winraid.level1techs.com/t/guide-transfer-of-specific-intel-orom-vbios-and-gop-vbt-settings-by-using-intel-bmp-tool/30930/288 ] and used the latest Cherry View VBIOS chv_1014.dat but it works only with attached ext. LCD via microHDMI - I got black screen on build in LCD. So I decided I need to update $VBT structure according to one that is present in UEFI GOP (I currently have dump of SurfTab UEFI image from flashROM via AMI tool). I extracted it easily but there are multiple $VBT instances under various GUIDs and I don’t know which one is really used. Next problem is that GOP’s $VBT is version 195 while all chv_101x.dat VBIOSes I found use older $VBT version 190 so I cannot easily transfer the settings from newer to older.

I tried it manually with opened 2 windows of intel BMP tool and I tried to match the settings close as possible. I got partial success with modified VBIOS (manually updated $VBT 190) but still several problems:

1) I have to ext.LCD connected via microHDMI to boot on it and then when VBIOS initialize it swaps screen to built in LCD and I can disconnect the ext LCD on microHDMI until reboot. But if I boot without ext. LCD I still got black screen on built in LCD after VBIOS init so it’s not much practical.

2) The image on built in LCD after VBIOS init is rotated 180 deg upside down and I cannot see any option in intel BMP to rotate it back - any idea?

3) Tere are other issues of rendering text mode both on ext. and built in LCD that makes real usability quite low. e.g. when under DOS the text on screen reaches the bottom line, instead of scrolling up the sceen becomes entire light gray and all further text is displayed only at single bottom line - unreadable output if more lines printed. Also any program that use VESA graphics cause hang. VGA programs like Doom can run with some visual artifacts (e.g. translucent demons are white http://rayer.g6.cz/1tmp/csmwdoom.jpg ) and keyboard is not responding during the game (become responsive after Doom quits if I run it with -timedemo demo1).

So I’d like to know if there’s a chance to get some newer VBIOS or configure it properly to get usable DOS machine working with built in LCD without need to connect ext. LCD…

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...