What can you do to connect many I2C devices with the same device address to an MCU? Most often, the advice is to use hardware solutions. Here, we will look at how to solve the problem with software employing the FlexWire library.
Continue readingTag: I2C
Replacing the Wire Library—Sometimes
The Wire library is the one that connects your Arduino to sensors and actuators that communicate using the I2C protocol. Unfortunately, this library has a lot of shortcomings, and often you want to replace it with a different I2C library. Replacing the Wire library on a per-sketch basis turns out to be more complicated than one would expect. In this blog post, I describe an easy way to accomplish that.
Continue reading
Everything You Wanted to Know About Real-Time Clocks but Were Afraid to Ask
What is a real-time clock? Why do you need one? What are the use cases? How accurate can a real-time clock be? Which features can a real-time clock have? Which models are around? And which one should you buy?
Continue reading
Real Programmers Write Assembly Code
Although the typical Arduino programmer is probably not interested in writing assembly code, in some situations assembly programming is essential. Let’s have a look at these situations and see what one can do.
Continue reading
Doing it the Logical Way
When things go wrong, although your program logic appears to be correct, it is time to look at the signals going into the MCU and coming out of the MCU. The best tool for that is a logic analyzer.
Continue reading
Debugging(2): It’s the Hardware, Stupid!
When something goes south, it is not always the programmer who is to blame. It could also be the hardware (resp. the electrical engineer) that might be responsible. Note, however, when you are developing your system as a hobbyist, you are both: the electrical engineer and the programmer (so you always can blame yourself). In this blog post, we will take a look at some of the things that can go wrong on the hardware side.