9
« on: March 09, 2020, 11:35:58 AM »
I was reading the tbasic manual and came across the LSHIFT & the RSHIFT. The explanation shows and example of LSHIFT as being LSHIFT ,n The i is a DM[n] or RELAY[n] etc then you can add a , and a number equal to the number of channels that you want to shift. So if you want to shift Relay channels 2 to four you would LSHIFT RELAY[2] , 3 so far so good. However if I want to shift just RELAY[2] by one bit I would use LSHIFT RELAY[2]. My question is what is the simplest way to shift left by 2 bits. Do you have to do LSHIFT RELAY[2] then again LSHIFT RELAY[2]
example LSHIFT RELAY[2]
LTSHIFT RELAY[2]
OUTPUT[1] = RELAY[2]
I would have thought that there would be a way to enter the number of shifts such as LSHIFT RELAY[2] ,1 for number of channels and a second , and the number of shifts.