Sunday 27 April 2008

Assembly language

Machine language is the program representation as the microcontroller
understands it. It is not easy for humans to read and is a common
cause of migraine headaches. Assembly language is a human-readable
form of machine language which makes it much easier for us flesh and
bone types to deal with. Each assembly language statement
corresponds to one machine language statement (not counting macros).


An assembly/machine language program is fast and small. This is
because you are in complete charge of what goes into the program. Of
course, if you write a slow, large, stupid program, then it will run
slowly, be too big, and be stupid. Assembly language (assembler)
can't correct stupidity - although sometimes I wish it could ;-).

If you are starting out learning about microcontrollers, it would be
worth your while first learning assembler. By programming in
assembler, you master the underlying architecture of the chip, which
is important if you intend to do anything significant with your
microcontroller.

No comments: