tags:

views:

169

answers:

1

I'm new to assembly (as you can plainly see) and I'm trying to compile the following:

hex_charmap db '0123456789ABCDE'
mov   al, [hex_charmap + ax]

However I get the following error on line 2:

error: invalid effective address

What does this mean and how can I fix it?

+3  A: 

My assembler's rusty. Can AX really be used as an indexing register?

Update:

Just found what I was looking for. Only BX can be used as an index register!

Source: http://www.xs4all.nl/~smit/asm01001.htm .

Carl Smotricz