mike_p
Posts: 30
Joined: Fri Aug 01, 2014 2:35 pm
Location: Surrey, UK

Interface GPIO using CMOS 4066 quad switch

Mon Jan 05, 2015 10:53 am

I have a few 4066 chips lying around and was wandering if anyone has considered using them as a cheap/simple method of level shifting when interfacing the Pi GPIO pins to external devices?

User avatar
Burngate
Posts: 6302
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: Interface GPIO using CMOS 4066 quad switch

Wed Jan 07, 2015 12:43 pm

4066.jpg
4066.jpg (10.88 KiB) Viewed 749 times
It's quite amazing what you can do with bilateral switches.
Power it from 5v, attach one side to 3v3 and the other through a pull-down resistor to ground, and you've got a buffer or level translator - the control is at 5v, the output at 3v3.
Attach one side to ground and a pull-up resistor to 3v3 on the other, and you've got an inverter.
Parallel two of them, you've got a NOR gate. From there, you can do almost anything (you'd need quite a few to build an ARM processor, and it would be rather slow)

Return to “General discussion”