Hi. I’ve wrote a lot of prog’s in Assambler. There it’s ”WERY” powerful to use the carry funtion. It’s when You are ”multiplexing stuff.
Say, You have a dedicated ”register” in Your prog. In this reg. You want to manipulate them individual bits in the reg.: MSB 7,6,5,4,3,2,1,0 LSBEx. bits 5 & 2 are the bits You want to have ON when You multiplex them ”OUT”, You put them bits ”HIGH” in Your program. OK. Time for the multiplexing.
You feed them out in a cue, starting with the MSB (the most significant bit ”7”), now SHIFT LEFT and check if there’s a ”carry”, if not, set output ”LOW”, else set ”HIGH”…. SHIFT LEFT => ”next bit 6”….. You do this shift for 8 times, say in a ”for/next-loop”.
When the bit 5 becomes the MSB and beeing SHITED to LEFT, there will be a CARRY, of course, (You did put it ”HIGH” in Your program), therefore put ”HIGH” at Output.Got it?
Select as Best AnswerUndo Best Answer
Hmm. What could it do ?
What DOES it do. You put a word in the Accumulator and then what ?