[quote:971d7a9e08="Evert :-)"]I don't like the name of the variables [b:971d7a9e08]Bit_1 & Bit_2[/b:971d7a9e08].
Bit is an reserved word and the underscore is used to continue break up a long line.
Maybe the compiler is confused about that.
Edit: Try, Force the compiler to save the Bit_1&2 in an other byte then Tick.
[code:1:971d7a9e08]
'Global variables
Dim Tick As Bit
Dim Dummie1 As Bit
Dim Dummie2 As Bit
Dim Dummie3 As Bit
Dim Dummie4 As Bit
Dim Dummie5 As Bit
Dim Dummie6 As Bit
Dim Dummie7 As Bit
Dim Bit_1 As Bit
Dim Bit_2 As Bit
[/code:1:971d7a9e08][/quote:971d7a9e08]
Hi again Evert,
*Now* I realize what you mean. The tick bit is stored within a byte, I should stuff the rest of that byte with dummy bits so that my other bits are stored in a second byte.
And the result is...
That fixes it!
So my bit is getting corrupted by the other bit operations. Something to watch out for!
So is anyone surprised by this?
Is it a bug? Or am I using BASCOM incorrectly, I didn't think so. Perhaps I should email support.
↧