Quote:
Originally Posted by Singletree5990
As a side note: I did encounter what I suspect was an issue
with Arduino-0011 properly handling statements to modify
bits within the ADCSRA register.
I was trying to write "00000101b" by using
different permutations of
"ADCSRA|=((1<<ADPS2|1<<ADPS0)&!(1<<ADPS1));"
but had to resort to
"ADCSRA=5;"
to achieve the desired value in the register.
|
Very old thread, I know, but just for the benefit of anyone coming across this bit: "!" is a "boolean not", and will return 0 (false) if the operand is non-zero (true), and 1 (true) if the operand is zero (false). You were probably thinking of the operator "~", which is binary inverse.