cadet1620 wrote
linuxford wrote
... It seems to be sort of working but I am having trouble setting the MSB of the 16-bit word to 1.
Could you please give me a hint?
What is the signed-integer value of a word that is all 1 bits?
--Mark
2^16 is 65536. 65536/2 is 32768, so signed 16-bit integer represented values range from -32768..0..32767.
If I use the
@-1
it will give me the a 16-bit pattern of all 1's - 1111 1111 1111 1111
However, if I do that, the CPU don't like that. It seems as soon as I make the MSB 1, that it is not an A-instruction but is instead a C-instruction perhaps.