Author Topic: Where to start?  (Read 9673 times)

Adam Christensen

  • Guest
Where to start?
« on: February 27, 2005, 04:21:34 PM »
I have a ASM file that I am trying to compile. It is a touch screen driver for DOS. The default driver only works with COM1 or 2. I have a computer where it is wired on COM6. IO base 338 and IRQ 11. I tried using the ASM code from ASM.ZIP on:

After modifying the lines I believe enable the TSR to load using 338/11 it won't compile, even the original ASM file won't work. I am probably using the wrong type of assembling program as I have no idea what I am doing. Any suggestions?

Adam Christensen

  • Guest
Re: Where to start?
« Reply #1 on: February 27, 2005, 04:27:58 PM »
Just to fill in some potental questions:

I modified line 82 and 86 to point to my hardware configuration.

BASEPORT   equ      338h      ; COM1
BAUDH      equ      BAUD9600H   ; 9600 baud
BAUDL      equ      BAUD9600L
OTHERPARAMS   equ      3      ; 8/1/N
IRQ      equ      11      ; IRQ4 = COM1

This is what MASM spits out:

C:\elosix.asm(101) : error A2070: invalid instruction operands
C:\elosix.asm(118) : error A2070: invalid instruction operands
C:\elosix.asm(239) : error A2006: undefined symbol : nullproc
C:\elosix.asm(415) : warning A4023: with /coff switch, leading underscore required for start address : Start

Offline Frank Kotler

  • NASM Developer
  • Hero Member
  • *****
  • Posts: 2639
  • Country: us
Re: Where to start?
« Reply #2 on: February 27, 2005, 05:43:18 PM »
You'd probably get better answers to your Masm questions on a Masm forum. If you wanna "translate" it to Nasm syntax, maybe we can help (PITA - looks like it uses a lot of "Masmisms")

Lines 101 and 118 wouldn't assemble with Nasm (without modification), but they look okay to me for Masm - maybe a different version(?). There's some kind of command line switch or directive to make newer versions behave like older versions, I think. If you can find that, it might help.

Line 239 may be because Masm differentiates between labels and variable names - try it without the "offset".

The reference to "coff" is a sign of trouble. You don't want this assembled to coff format! Find out what switch you need for OMF output. One advantage of translating the whole mess to Nasm is that we could spit out a .com file directly, without messing with a linker and "exe2bin"...



  • Guest
Re: Where to start?
« Reply #3 on: February 28, 2005, 10:49:17 AM »
the offset you can remove in all lines with just do

%define offset

so its define offset as nothing... :P