Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
hex numbers in asm blocks
LTee Wrote:I hadn't, no - and that seems to work fine. I'm obviously basing my tests on outdated info. Smile

Many thanks!
The FFh is all letter, and the compiler/assembler think its an identifier.
If you want to ensure it knows it's a hex number, prefix it with 0. So FFh should be 0FFh.
This is common to all assemblers. Any hex number starting with a letter and ending with 'h' must be prefixed with 0. Thus:

A3h => Error (it's an 'identifier'). Use 0A3h
2Bh => Ok (Already starts with a number).

Using the $ prefix is always ok and avoids this problem. Smile

Messages In This Thread

Forum Jump:

Users browsing this thread: 1 Guest(s)