
Grove level shifter
STDGrove level shifter
License
:GPL 3.0
Description
It's a level shifter that is ideal for use with M5Stack products which conventionally provide 5V through a "Grove" port, but run 3.3V logic on the two GPIO pins. I've panelized it so you get 18 devices per PCB. The PCB labeled "Y25" is the one you see in the photo.
A Grove connector has four pins: ground, voltage, first GPIO, second GPIO. On the "Y25" PCB, the level shifting is done on the GPIO connections. The Ground and voltage pins are passed through to the opposite side of the board, unmodified. The two GPIO circuits each go through their own level shifter, and correspond to the same position pin on the opposite side. This device requires 5V on the voltage pin to operate (which can be provided from either side)
This level shifter produces its own 3.3V reference using an LDO, taking power from the 5V line. It's compatible with UART and I2C, just like most normal level shifters.
For those who haven't used level shifters before: the basic behavior is that the level shifter will always (but weakly) "pull up" both sides to each side's respective 5V/3.3V level (HIGH) state, except when one side's microcontroller drives its side LOW. Whichever side drives a LOW (0V) strong enough to overcome the pullups will cause the LOW to pass through and appear on the other side. When the low is no longer actively driven, the level shifter pulls both sides high again. If nothing is connected to a pin, the opposite side will still read high. Driving one or both sides HIGH has no net effect (assuming the other side isn't misconfigured and trying to drive LOW at the same time).
This works well for I2C (because all communication is in the form of pulses of LOW, and driving the lines high is never allowed except through pullups), as well as UART (one side's always the sender, the other side is always the receiver, and HIGH is the idle state for UART).
I made these for myself, primarily for interfacing 3.3V logic with 5V AVR Arduinos and other 5V protocols (like Wiegand for RFID readers). These do exactly what I expected, and they work great in a little bit of shrink tubing. I bulked up the conductors for 5V and GND passthroughs so they could sustain a reasonable degree of power-supplying current.
Design Drawing

BOM


Project Members

Comment