Popovk, thanks for clearing that up.

I know this is a bit off-topic but I'm intrigued now.

In your example "btest = NOT 170" is "True". Does this mean that 0=True, anything else=False?