Play around with electronics long enough, and eventually you’ll run into I2C devices. These chips – everything from sensors and memory to DACs and ADCs – use a standardized interface that consists of only two wires. Interacting with these devices is usually done with a microcontroller and an I2C library, but [Kevin] wanted to take that one step further. He’s bitbanging I2C devices by hand and getting a great education in the I2C protocol in the process.
Every I2C device is controlled by two connections to a microcontroller, a data line and a clock line. [Kevin] connected these lines to tact switches through a pair of transistors, allowing him to manually key in I2C commands one bit at a time.
[Kevin] is using a 24LC256 EEPROM for this demonstration, and by entering a control byte and two address bytes, he can enter a single byte of data by hand that will be saved for many, many years in this tiny chip.
Of course getting data into a chip is only half of the problem. By altering the control byte at the beginning of an I2C message by one bit, [Kevin] can also read data out of the chip.
This isn’t [Kevin]‘s first experimentation in controlling chips solely with buttons. Earlier, we saw him play around with a 595 shift register using five push buttons. It’s a great way to intuit how these chips actually work, and would be an exceptional learning exercise for tinkerers young and old,
Continue reading “Bitbanging I2C by hand”
[Paul] knew that he could get an oscilloscope that would measure the microamp signals with the kind of resolution he was after, but it would cost him a bundle. But he has some idea of how that high-end equipment does things, and so he just built this circuit to feed precision data to his own bench equipment.
He’s trying to visualize what’s going on with the current draw of a microcontroller at various points in its operation. He figures 5 mA at 2.5 mV is in the ballpark of what he’s probing. Measurements this small have problems with noise. The solution is the chip on the green breakout board. It’s not exactly priced to move, costing about $20 in single quantity. But when paired with a quality power supply it gets the job done. The AD8428 is an ultra-low-noise amplifier which has way more than the accuracy he needs and outputs a bandwidth of 3.5 MHz. Now the cost seems worth it.
The oscilloscope screenshot in [Paul's] post is really impressive. Using two 1 Ohm resistors in parallel on the microcontroller’s power line he’s able to monitor the chip in slow startup mode. It begins at 120 microamps and the graph captures the point at which the oscillator starts running and when the system clock is connected to it.
Etching and populating a board is childs play compared to finding connectors which link several components. But Hackaday alum [Ian Lesnet] and his crew over at Dangerous Prototypes have come up with a solution that makes us wonder why we haven’t seen this long ago? They’re prepping an any-size ribbon cable kit.
So lets say you do find the type of connector you want. You need to cut the ribbon cable to length, crimp on the connectors, then seat those connectors in the housing. We’ve done this many times, and being cheapskates we use needle-nose pliers instead of buying a proper crimper. This solution does away with that grunt work. The kit will ship several different lengths of ribbon wire with the connectors already placed by machine. This way you peel off the number of connectors you need, select the proper house size and plunk it in place. Also in the kit are several lengths of male, female, and male/female jumper cables you can peel off in the same way.
Now what are we going to do with the rest of the spool of ribbon cable sitting in the workshop?
And here we’ve been complaining about Flat Pack No-Lead chips when this guy is prototyping with Ball Grid Array in a Wafer-Level Chip Scale Package (WLCSP). Haven’t heard that acronym before? Neither had we. It means you get the silicon wafer without a plastic housing in order to save space in your design. Want to use that on a breadboard. You’re crazy!
Eh, that’s just a knee jerk reaction. The wafer-level isn’t that unorthodox as far as manufacturing goes. It’s something like chip on board electronics which have that black blob of epoxy sealing them after the connections are made. This image shows those connections which use magnet wire on a DIP breakout board. [Jason] used epoxy to glue the wafer down before grabbing his iron. It took 90 minutes to solder the nine connections, but his second attempt cut that process down to just 20. After a round of testing he used more epoxy to completely encase the chip and wires.
It works for parts with low pin-counts. But add one row/column and you’re talking about making sixteen perfect connections instead of just nine.
Lithium cells outperform Nickel Cadmium and Nickel Metal Hydride in almost every way. But they also need a little bit more babysitting to get the most out of them. That comes in the form of control circuitry that charges them correctly and won’t let them get below a certain voltage threshold during discharge. We enjoyed reading about [Carlos'] Lithium cell salvage efforts as it discusses these concerns.
He wanted to salvage a Lithium power source for his projects. He had the three cell pack from a dead Macbook Pro seen in the upper left, as well as the single blown cell from a digital picture frame shown on the right. The three-pack didn’t monitor each cell individually, so the death of one borked the entire battery. He desoldered them and probed their voltage level to find one that was still usable. To prevent his project from draining the source below the 2.7V mark he scavenged that circuit board from the digital picture frame. A bit of testing and the system is up and running in a different piece of hardware.
Don’t be afraid of this stuff. If you learn the basics it’ll be easy to use these powerful batteries in your projects. For more background check out this charging tutorial.
[Dr. Iguana's] experience moving from projects powered by disposable Alkaline cells and linear regulators to recycled Lithium Ion cells using the buck regulators seen above might serve as an inspiration to make the transition in your own projects.
The recycled cells he’s talking about are pulled out of larger battery packs. As we’ve seen in the past, dead battery packs for rechargeable tools, laptops, etc., are often plagued by a few bad apples. A small number of dead cells can bork the entire battery even though many perfectly usable cells remain. Once he decided to make the switch it was time to consider power regulation. He first looked at whether to use the cells in parallel or series. Parallel are easier to charge, but boosting the voltage to the desired level ends up costing more. He decided to go with cells in series, which can be regulated with the a less expensive buck converter. In this case he made a board for the RT8289 chip. The drawback of this method requires that you monitor each cell individually during charging to ensure you don’t have the same problem that killed the battery from which you pulled these good cells.
We’re used to thinking of limit switches as a mechanical device that cuts the motor connection before physical damage can occur. [Anthony] decided to try a different route with this project. He built this set of no-contact limit switches using a hall effect sensor. The small black package sticking out past the end of the protoboard is the sensor. It is used to detect a magnetic field.
[Anthony] chose to use an Allegro A3144 sensor. Apparently it is no longer in production but was easy to find for a song and dance on eBay. When thinking about the design he decided to add two LED indicators, one lights when the switch is open and the other when it has been tripped. This would have been easy to do with just one LED, but he needed to add more parts to get both working. In the lower left corner of the protoboard you can see the configurable gate device (74LVC1G58) he added to monitor the hall effect sensor and switch the output and LEDs accordingly.