Logic Analyzer, for Arduino, AVR, ESP8266 and STM32 with a very nice working processing interface, you could run it also on any Android device.
A few days ago I needed a logic analyzer since I don't have any (and them are quite expensive) I thought to write my own code. It will work on every Arduino board, AVR, STM32 and ESP8266. It could be very helpful to debug ISP, I2C and other serial communication where you think that could be an error.
UNO.ino
, MEGA.ino
, STM32F1.ino
or ESP8266.ino
to your boardprocessing.pde
If you wish you could put a LED to see when the MCU is recording, see the code of your board to know where to wire it. The number of samples is set to 200 but you could increment it until the memory is full.
To have it faster than possible the loop was reduced to the minimum number of statement and I am doing a lot of optimization! All the calculation are made after saving the data, and during the recording there are stored only the values of the pin that changed and when it happened.
I made a processing sketch to visualize it. Using the bar scroll at the bottom of the graph you could move along the captures or alternatively you could use the wheel of the mouse. With the "Start" button you can begin a new recording. Two divider have been added: one to use millisecond instead of microsecond and the other that work like a kind of "zoom" (to change it move the mouse over this button than use the mouse wheel; decreasing it you will zoom in, increasing zoom out). You are also able to save the current window in a .jpg or .tif file with the "Save" button.
It works on Windows and Linux both 32 64 bit and android devices. I added also an Arduino test sketch if you would like to test the logic analyzer. Enjoy!
If you liked this project and wish to donate you can sent to PayPal