INX (short for "INcrease X") is the mnemonic for a machine language instruction which increases the numerical value held in the X index register by one, and "wraps over" when the numerical limits of a byte are exceeded.
- If the X index register is taken as an unsigned integer, INX "counts" from 0 thru 255/$0 thru $FF. If the register already holds value 255/$FF as it is incremented using INX, it "wraps over" to the value 0.
- If the X index register is taken as a signed integer, INX will "count" from −128 thru +127, or −$80 thru +$7F. If the register contains 127/$7F when incremented, it "wraps over" to the value −128/−$80.
Addressing mode[edit | edit source]
CPU flags[edit | edit source]
INX affects 2 of the CPU's status flags: