Don't ad-block us - support your favorite websites. We have safe, unobstrusive, robotics related ads that you actually want to see - see here for more.
0 Members and 1 Guest are viewing this topic.
just checking does a global in a seperate .c file still have scope in the main program? If I build a library for the I2C stuff and access those variable in the main program in a main.c file does the scope work?
...My concern is like rgcustodio said is that if I am writing to sensor 2s array and the interrupt steps in it will take a garbage array with who knows what in it because sensor 2 was taking a reading at that time.In any case I will need to make some sort of variable change to indicate when a sensor starts updating its array and when it is not using it....
int *ptr = &someothervariable;
int *ptr = 0x345678;
I was going to use pointers but my concern is how do I stop the program from using that location to store data from something else?
My concern is a standard I2C interrupt sequence in the AVR is at least 4 interrupts in a row and