Go Down

Topic: BrendaEM's Interference Experiment Code (Read 2270 times) previous topic - next topic



I did a little experiment, capturing 3D interference form a laser.

Although the Adruino code is older and not my best, I still want to share it.
The Processing Code is included.

There's a video here: https://www.youtube.com/watch?v=ZH40mvSFI-g


Very cool project and nice video too!

In the video when you're talking about your global variables you mention that you don't remember whether you're using error any more. Something I find really useful is to make all the globals that are only used in my sketch static. After doing that when you turn on compiler warnings in File > Preferences you will get a warning message for any global that is not used. So if you change line 51 to:
Code: [Select]
static byte error;
you get the warning:
Code: [Select]
C:\Users\per\AppData\Local\Temp\arduino_modified_sketch_443145\Sled020.ino:51:13: warning: 'error' defined but not used [-Wunused-variable]

 static byte error;



Good technique for finding unused variables.

Thanks for the compliment,

Go Up