What I need to do it implement both a bitwise left shift, and a bitwise right shift using LC-3 Assembly. Basically, every bit has to be moved over one space in the directio
You need two masks. Both of them are a single "1" with the rest of them "0"s. Both are initialized to 0000 0000 0000 0001, but one of them is left-shifted by an amount that you want the original number to be right-shifted. We'll call that Mask1. The un-shifted number will be Mask2.
Compare Mask1 with the original number. If (Mask1 "and" input) > or < 0, "or" Mask2 with output and then left-shift both Masks.
In either case, left-shift both Masks and try again until there are no more bits in the input to test.
LC-3 does not have a bitwise "or." You will have to "not" both operands, "and" them, then "not" the result for a bitwise "or."
The reason you are testing whether or not Mask1 "and" input is > or < 0 is because if it is zero, we want to do nothing. If the result of "and"ing these operands is > 0, then that means that the position tested found a "1" and it needs to be printed to the result. If the mask has been left-shifted to become 1000 0000 0000 0000, that is technically a negative number. The "and" of that and any number with a "1" in that position will also be a negative number.