03-22-2017 03:16 AM
Am trying to get acceleration , velocity and displacement data from Accelerometer ADXL335 .
The picture of code and waveforms are attached ...please correct me if am wrong.
03-22-2017 06:03 AM
Do not use local variables. You are causing race conditions (you might be reading new data or old, no way to tell and it could be changing per iteration and therefore messing up your calculations). Use DATAFLOW (ie wires) to pass your values from one calculation to the next.