This firmware provides an interactive way to test, scan, and diagnose I²C devices using an Arduino Nano or similar boards. It turns the microcontroller into a flexible I²C diagnostic tool that can analyze bus behavior, detect devices, monitor voltages, adjust clock speeds, and sweep frequencies to evaluate communication performance. The project includes the schematic, source code, and Gerber files. Communication is done through the terminal in the Arduino IDE, where commands are entered and executed with the Enter key. I keep a dedicated unit for testing, so I simply connect the USB cable and open the terminal rather than recompiling each time.
The firmware also provides measurement and monitoring features useful for troubleshooting hardware. It can measure voltages on the SDA and SCL lines, monitor DUT (Device Under Test) power, and report internal processor temperature. Pull-up resistors can be enabled or disabled directly from the menu, allowing quick experimentation with different bus configurations. If the target device is already powered, do not connect the +5 V from the tester. If the circuit contains a processor, it can usually be held in reset while testing the bus.
Additional diagnostic modes include I²C frequency sweeping and bus health analysis to help reveal problems such as weak pull-ups, excessive capacitance, or unstable timing. The project has evolved over several years as new capabilities were added when needed. It can also be used to test I²C LCD modules that use the PCF8574 with the HD44780. If a desired device is not included in the code, it can easily be added. The code reflects my personal coding style, feel free to modify it to suit your own needs.
Code etc is available at: GitHub - gilshultz/i2c-hardware-probe: I²C hardware probe using an Arduino Nano to detect and test I²C devices on a bus. It’s designed for quickly identifying device addresses and verifying communication without needing a full setup. · GitHub
Nice project!
GitHub repo is however not complete yet.
Filed an issue to improve the readme.md a bit.
That sounds great! I'm looking forward to the repository updates.
Thanks, I just looked an it was there. I looked again and your update is now there, a great big thanks:-).
I have a non-hardware-based version of this that I will clean up and post in a week or so. These tools simply evolved while I was working on my home automation system. There is still plenty of room for improvement, but the Nano is almost out of program memory, so at some point features have to give way to available space.
I use it purely as a tool. The picture shows the finished version; when I need it, I just connect it. It can also be connected to an existing bus, but if you do that, do not use the "turn on power" command, or simply leave the +5V line disconnected. The system processor needs to be held in reset to avoid conflict.
welcome to GitHub..
I'm not that great on it either..
To add files click on the little arrow on the Add File button and choose upload files..
Then you can just drag and drop the file to upload..
good luck.. ~q
Big Thanks. I followed your advice and it appears to have worked. I expect it will take a bit of time before it shows.
Should show straight away..
After your drag the file(s), then there's a spot to add a comment, can leave blank, then you need to commit it, pretty sure it's a commit button you need to click to finish the uploads..
~q
Thanks! After I upload it, does it eventually show up?
it should show up instantly..
I'm thinking you dragged the files in, which starts a little progress bar but maybe you didn't click the commit button to finish it..
~q
I had no idea about that. Do I upload the zip or individual files? So far I just tried the zip
best to just upload the source files unzipped..
can drop the *.ino right in there..
can also setup a folder with all the source files and drag the folder to upload the folder and all it's contents..
can also upload same file, it over writes the old keeping track of changes..
~q
I should add..
Even if you don't zip anything up..
When I click on the code button and download a zip, github zips everything up in the git and send that as a download..
it would also zip your zip file..
~q
I got the files there, A real Big Thank you:-)