Some pbasic questions?
jonduncan
Posts: 40
Can i have a nested for loop?
if I create a·
bits var bit(2)
can I do this?
if bits = %01 then·· ....
can i I do math with Nib, what happens when over flow, does it wrap around or does carry out to high bit?
·
if I create a·
bits var bit(2)
can I do this?
if bits = %01 then·· ....
can i I do math with Nib, what happens when over flow, does it wrap around or does carry out to high bit?
·
Comments
2) It won't do what you expect. You've declared a bit array with 2 elements. There's really no way to declare a variable consisting of only 2 bits. A 4 bit nibble is the only size between a single bit and a byte
3) If a variable is declared as a 4-bit nibble, it can only have values 0-15. If you add 1 to 15, you would get 0 (wrap around).
http://ww1.microchip.com/downloads/en/DeviceDoc/21713F.pdf
of the EEPROM so all I would need to do is a byte check