News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

COM Files

Started by herge, May 15, 2006, 11:19:02 AM

Previous topic - Next topic

herge

 Hi All:

I've being trying to use Qeditor to compile some old Assembler
programs. Something is not right or I am missing or forgetting
something. The offset or addresses it trys to load for Data are
totally out to lLunch. I know the logic is okay, but the addresses
are all wrong? Addresses out by over 256 bytes.

REM MTI.BAT 5:19 AM 5/15/2006
ML /c %1.asm
pause
LINK16 /tiny %1.obj;
pause
%1
// Herge born  Brussels, Belgium May 22, 1907
// Died March 3, 1983
// Cartoonist of Tintin and Snowy

MichaelW

The batch file looks OK. For a COM file the program loader allocates a block of memory, writes a 256-byte Program Segment Prefix to the start of the block, and loads the program starting at offset 100h. For this to work with a program that contains jumps, calls, or data, the program must be assembled starting at offset 100h. This is normally done by specifying a tiny memory model, or by placing an ORG 100h at the start of the program code.

eschew obfuscation

herge

 Hi MichaelW:

I am now getting this message:

day.obj : warning LNK4033: converting object format from OMF to COFF
day.obj : fatal error LNK1190: invalid fixup found, type 0x0001
F:\MASM32\BIN>snap

It obviously doesn't like something.

[attachment deleted by admin]
// Herge born  Brussels, Belgium May 22, 1907
// Died March 3, 1983
// Cartoonist of Tintin and Snowy

MichaelW

It looks like you are trying to use a 32-bit linker instead of a 16-bit linker. What version number is the linker reporting?

eschew obfuscation