Need an executable version of asm80

I need to do a quick patch on an old 8051 program written in assembler for asm80. The assembler was asm80 A Cross Assembler

for the Intel 8080-8085

With CPM[tm] syntax

- by -

David A. Klotzbach

I have the only C source for the program, it's generally available on the web, but I can't compile it. It originally ran on an old Tektronix workstation that is long defunct. What I'd like is a dos/windows executable that I can use to assemble my program, but I'd settle for something that works in linux. I only plan to do this once.

The ASM won't assemble in any other assembler I've found...expect it's because of the "CP/M syntax". The assembler won't compile in any version of C that I've tried. The issues appear to be version-specific directives rather than the actual C-code...but I'm not a C programmer. Is there a way to determine which C-compiler will compile this assembler program so I can run it on a PC?

My options appear to be:

1) port my asm program to an available assembler. 2) port the Assembler to an available C-compiler. 3) edit the hex code by hand.

None of the above is the most likely outcome.

But maybe someone else has had this problem and has an executable version of the assembler. Dos or windows or Linux would work for me. Thanks, mike

Reply to
mike
Loading thread data ...

You already posted this.

-- Some informative links: news:news.announce.newusers

formatting link
formatting link
formatting link
formatting link

Reply to
CBFalconer

On this newsgroup? I thought I saw it elsewhere.

--
Al Balmer
Sun City, AZ
Reply to
Al Balmer

Umm, maybe I'm missing something here, but AFAIK asm80 won't assemble

8051 code. 8051 code is completely different to 8080/5.

Regards,

--
Mark McDougall, Engineer
Virtual Logic Pty Ltd, 
21-25 King St, Rockdale, 2216
Ph: +612-9599-3255 Fax: +612-9599-3266
Reply to
Mark McDougall

You're right. I'm wrong. He got sent here.

--
 Some informative links:
   news:news.announce.newusers
   http://www.geocities.com/nnqweb/
   http://www.catb.org/~esr/faqs/smart-questions.html
   http://www.caliburn.nl/topposting.html
   http://www.netmeister.org/news/learn2quote.html
Reply to
CBFalconer

This might have been a macro assembler, with the Cross-asm in the macros. In that case, you'll need the ASM source, and the MAC file as well.

Another pathway might be to load a CP/M emulator, on your PC, and find an original ASM com file ?

-jg

Reply to
Jim Granville

Still can't see how it would've been done - asm80 is producing 8080/5 opcodes regardless of the macro conversion...

I can see how it *might* have been done the other way - i.e. cross-assemble 8051 into 8080/5...

Regards,

--
Mark McDougall, Engineer
Virtual Logic Pty Ltd, 
21-25 King St, Rockdale, 2216
Ph: +612-9599-3255 Fax: +612-9599-3266
Reply to
Mark McDougall

Well, actually, It's an 8744 RUPI chip. It's been more than a decade, but I think 8080 code will run just fine on it. I think I have to lie to the programmer and program it as a

8751H.

I built a DOS 6.2 system and put Borland TurboC V2.0 and tried to compile asm80. It's giving me erorrs about size of structure unknown. Don't think I'll ever be able figure that out within the limits of my attention span.

Looks like I gotta port the ASM code....sigh... I'm gonna try ASEM51 unless someone has a better idea. Thanks, mike

Reply to
mike

I think you're confused?!? I found this...

...which looks remarkably similar to the blurb from your OP. You're not getting mixed up with this assembler are you?

Regards,

--
Mark McDougall, Engineer
Virtual Logic Pty Ltd, 
21-25 King St, Rockdale, 2216
Ph: +612-9599-3255 Fax: +612-9599-3266
Reply to
Mark McDougall

It can be done - That's how we did our first 8051 project....

-jg

Reply to
Jim Granville

Nope.

Other alternatives :

You do have the HEX file, as well ?

Then, you could DISASM that, assemble (using a new assembler) again to verify equality, then apply your quick patch to the DisAsm code.

That might be less effort, than a full assembler port, and if the patch is at the simple end of the scale, will be workable.

-jg

Reply to
Jim Granville

I'd be interested to see that!

I guess you could define macros for 8051-like mnemonics which resolve to 'nonsense' 8080/5 instructions (with the correct 8051 binary) or perhaps even DB's (define bytes)?!? Was that how it was done?

Can't think how address offsets for jumps etc were calculated???

Regards,

--
Mark McDougall, Engineer
Virtual Logic Pty Ltd, 
21-25 King St, Rockdale, 2216
Ph: +612-9599-3255 Fax: +612-9599-3266
Reply to
Mark McDougall

Generating opcodes for instructions without operands is easy, something like

MACRO NOP DB 00h ENDM

just generate the corresponding bit pattern with a byte/word generating directive. Opcodes with operands require a bit more to parse the operand expression and modify the opcode byte code accordingly and possibly add some extra bytes after the opcode.

The labels must be on the correct addresses so that the opcode macros will get correct addresses from the assembler symbol table and the macros are then capable of calculating branch displacements etc.

Managing different pages etc. can be a bit difficult within the macros.

These tricks work quite well as long as the assembler generates absolute binary code in the same format (S-record etc.) that can used more or less directly by the actual target system.

Paul

Reply to
Paul Keinanen

INTEL 8744 RUPI chip has 8051-core with aditional SIU (Serial Interface Unit ) and 192 bytes of RAM . It is code compatibile with 8051. You can use any assembler for 8051 family.

Regards Jarek Czula Poland

Reply to
Jarek

Ahh, those were the days when spirits were brave, the stakes were high, men were real men, women were real women and documentation was real ASCII :-)

Two hints:

  1. I just located a file named "asm80.tar$z" on

ftp://ftp.encompassus.org/lib/vs0088/languages/assembler/

This is a compressed tar file. Unpacking it yields source code and makefile for what I believe to be the assembler in question. It compiles on my Linux box with one warning:

"asm.h:66: Warning: array `hashtbl' assumed to have one element"

By adding "extern" at the beginning of line 66 in asm.h like this:

struct sym ... -> extern struct sym ...

the warning goes away and the assembler builds with no errors.

I have no idea wether this assembler actually works, but I guess you should give it a try (took me 5 minutes).

  1. Cite from
    formatting link

"All of these tools build under Cygwin/Linux and come with the GNU X-Tools product (on the same CD-ROM distribution).

[...]

asm80 Cross-Assembler An Intel 8080/8085 Cross-Assembler written by David A. Klotzbach. This

2Pass absolute assembler is basically compatible with the original CPM assembler."

So it seems this assembler is also available for purchase.

Cheers

Rob

-- Robert Kaiser email: rkaiser AT sysgo DOT com SYSGO AG

formatting link
Klein-Winternheim / Germany
formatting link

Reply to
Robert Kaiser

...

OK, I'll byte... Email that assembler source code to snipped-for-privacy@rwaltman.com and I'll try to make an executable. No promises of course, and probably I will not get to do it until Sunday.

Roberto Waltman

Reply to
Roberto Waltman

^^^^ Oops! Freudian typo.

Reply to
Roberto Waltman

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.