Updating readme.
Working on lab3.
Seems to be working now.
Got carry flag working correctly. Now have to figure out overflow, zero, and negative.
Still working out ccr flags.
Ok. So Branching doesn't actually put a return address on the stack. It just updates PC. Good to know.
Still trying to get overflow flag working. Ugh.
Fascinating. Looks like I've found a bug in the PUTS_SCI0 routine! It seems to mess up the CCR in certain cases. Namely, the overflow case.
I think I might have this nailed now. Still need to investigate potential problems with PUTS_SCI0, but all of the tests I'm throwing at it now are sending back the expected flags.
Adding -4 + 4 results in expected zero flag and carry flag. adding 7FFFFFFF + 7FFFFFFF throws appropriate negative flag and overflow flag. Adding FFFFFFFF + 00000001 results in carry flag and zero flag as expected.
Ugh. Flags right. Actual answers wrong. One step forward and two steps back.
Ho-Kay. I fixeded it.
Theoretically, 0,X should always be zero once we've gotten here. But changing anyway.
I have the fibonacci sequence working for 32 bit unsigned numbers. Granted, it's displayed in hex, because we don't have a LTOA macro, but the numbers are correct.
Forgot to add ALU32.INC. You'll need that to get fib.s working.
Renaming some stuff. Gonna merge this and move on to labs four and five for now. I've got add32 and fib working and that's the core of the lab.
Merging in incomplete lab3 for now. Has add32 and fib working. ALU32.INC is where
the add32 code is defined as a macro. Merge branch 'lab3'