'MPALC vs. MPASM ??'
crocontroller discussion list
|Harrison Cooper wrote:
>When it ain't broke, don't fix it........
>when did the switch [from MPALC to MPASM] occur and what is the
>benifits/drawbacks of the MPASM compiler - or is the MPASM the Parralax
>I don't want to have to rewrite my code for a new assembler - and it
>ought to be downward compatible anyway.
Unfortunately, MPALC _was_ broke.
MPASM is NOT Parallax's assembler; theirs is called PASM and is a
much... umm... "leaner" product.
If you've followed generally-accepted rules for writing
assembly-language code (labels starting at the leftmost column, opcodes
starting anywhere else, comments preceded by a semicolon), your code
will be compatible with MPASM.
MPASM needs more free memory than MPALC, since it dynamically
allocates heap space. This isn't usually a problem (especially
for relatively-small programs), and there's a protected-mode
version of MPASM that uses extended memory, anyway.
Too numerous to list. The main ones are:
It's supported by Microchip. MPALC support was dropped a year
It works with all existing and future PICs (including the 17Cxx
It doesn't have MPALC's math bugs.
It generates what's called a ".COD" file, which allows true
source-level debugging with Microchip's PIC-Master emulator and
It adds a number of assembly directives, including a "#define"
directive that forever solves the problem of addressing the
correct bit of the wrong byte in bit-oriented instructions. For
With MPALC, you might write:
DATAIN EQU 1 ;"DATAIN" IS BIT 1 OF
BTFSS PORTA,DATAIN ;CORRECT USE.
BTFSS PORTB,DATAIN ;INCORRECT USE... I
;FORGOT TO WHICH PORT
;"DATAIN" WAS ASSIGNED.
With MPASM, you can do this:
#DEFINE DATAIN PORTA,1 ;"DATAIN" IS BIT 1 OF
BTFSS DATAIN ;NO NEED TO REMEMBER
;WHICH PORT, AND NO
;CHANCE OF ERROR.
Also, MPASM can create object-code files for use with the
upcoming linker/librarian. These object files will also be
linkable with code generated by Byte Craft Limited's "MPC" C
Since MPASM is compatible with your existing source code (except for
some minor reserved-word conflicts [HIGH and LOW, for instance,
shouldn't be used as symbols in your source code]), it'd probably be a
good idea to move your development to MPASM as soon as possible.
Andrew Warren - ix.netcom.comfastfwd
Fast Forward Engineering, Vista, California
More... (looser matching)
- Last day of these posts
- In 1995
, 1996 only
- New search...