Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

EDR-DOS development (Announce)

posted by ecm Homepage E-mail, Düsseldorf, Germany, 16.08.2023, 18:19

You didn't reply about the int 71h function error codes. Apart from the compression support and the colour signature removal, this is the only patch of yours I didn't add to my repo yet.

> In fix-bio.asm I add a small procedure at the end of dosbio.sys.
> In the virtual block, I set a new jump instruction for this procedure and
> then copy the previous compressed jump instruction to drbio.sys (4 bytes)
> to be able to recreate it and run the unpacking procedure to the address
> CS-10h:IP+100h

Yes, I do think 3 bytes would suffice though. A near jump instruction is 3 bytes.

> The "file" directive works exactly like the "incbin" in nasm, but you can
> also specify the start and size of the loaded file block.

Actually, NASM's incbin does have that too: https://www.nasm.us/xdoc/2.16.01/html/nasmdoc3.html#section-3.2.3 It might be a little known feature however, as I didn't know about it when I originally wrote my bootimg FATFS format script.

Unlike this, NASM really does not have fasm's load and store directives. Those are more powerful, even though 3 of your fix files' uses of them can be replaced by using incbin with various parameters. (The replacement of the last byte of the compressed drdos.com by a pop ax can only be done with incbin by knowing the size of the file beforehand. NASM has no way of detecting the size without including the file data up to and including the last byte.)

Writing of which, how does the far address of the DOS kernel file end up on the stack so that by modifying the last byte of the compressed drdos.com to a pop ax and retf you have it branch where you want?

Oh, I just noticed that your DOS compression is exactly copied from pack101. Except that shipped with upx 1.25d. I was about to write, I would implement this with an lDebug script. (The pack100/pack101 debug scripts do work with lDebug, though I assume they were written for DR-DOS Debug.)

I found out how the address gets on the stack: https://hg.pushbx.org/ecm/edrdos/rev/c2e9bc4c642b#l27.50

> The memory at address 4F0h (16-bytes) is for the user and I took advantage
> of that.

Oh, yes, you're correct. The interrupt list calls it "intra-application communication area": http://fd.lod.bz/rbil/memory/other/m004000f0.html
I didn't know that and assumed it may be used by the ROM-BIOS.

> The first 8 bytes of compressed drdos.com should be:
>
> CMP SP,constant
> JA Above
> INT 20h
> Above:

>
> "vasm" is my replacement for "fasm" run by the D3X dos extender.

Is there a need for that here? Why did you use one once and the other once, rather than twice the same?

> I use aPACK v1.0 and UPX v3.96.

Thanks!

---
l

 

Complete thread:

Back to the forum
Board view  Mix view
22049 Postings in 2034 Threads, 396 registered users, 251 users online (0 registered, 251 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum