Hello, using GCC on an xmega, I need to have an array of about 240 bit variables (to indicate on/off states)...while I certainly can just set up a normal array, it will quickly & wastefully gobble up all sorts of RAM space. I've seen several discussions on setting up 8 completely unrelated bit variables to squeeze down into a single byte, but here I'm looking to do something like:
MyBitArray[233]=1;
MyBitArray[sensornum]=0;
if (MyBitArray[abcxyz]==1) motorfwd=1;
this need not be super speedy; I'm looking for a clean and simple method of setting this up, with whatever GCC offers as a reasonable implementation. Any thoughts on what has worked?