I am wondering if I can pull multiple values from an array at once. For example if I want to do bitWrite could I pull multiple values from the array at once like array[bitnumber =>] so any value equal or less than the number. If not how could I have the register have 1 pin set high and all the others lower than it set high.
Sorry if I am not very clear.
I was able to figure it out I just multiplied the byte by 2 then subtracted one.
For example if I want to do bitWrite could I pull multiple values from the array at once like array[bitnumber =>] so any value equal or less than the number.
Not without writing code to do it.
If not how could I have the register have 1 pin set high and all the others lower than it set high.
Well you could write to them using the direct register addressing mode.
You should be able to use the template class std::bitset to access individual bits as an array http://en.cppreference.com/w/cpp/utility/bitset
This implement I on seems significantly easier than a Union.
There were some caveats with the way the compiler handles memory alignment, I understand, but for an 8-bit uController like the AVR things should be straight forward and should not be complex such as with advanced microprocessors.
[urlhttp://www.ibm.com/developerworks/library/pa-dalign/][/url]