We are going to create a controllable 6×7 LED grid with minimal components.
Charlieplexing is a method to individually control more LEDs than pins used. This method is popular since it doesn’t require any additional components like shift registers.
It mostly works by changing the mode of two pins to an input and an output to light a specific LED. By cycling through and lighting up each LED at a time quick enough it gives the illusion of multiple LEDs being lit at once.
The formula for working out the amount of LEDs you can control from the amount of pins (N) you want to use is:
So 3 pins = 6 LEDs, 4 = 12, 5 = 20, 6 = 30, 7 = 42, 8 = 56, 9 = 72 and so on.
For this tutorial we are going to use 7 pins, so that means we have 42 LEDs that we can control.
The Adafruit Huzzah is an ESP8266 breakout board – I used it for this project its easier to program and power compared to a bare ESP8266, but still is still super cheap. This board is great because it has built in WiFi, so we can add the ability to change the grid over the Internet.
Adafruit HUZZAH ESP8266 Breakout: Add Internet to your next project with an adorable, bite-sized WiFi microcontroller, at a price you like! The ESP8266 processor from Espressif is an 80 MHz microcontroller with a full WiFi front-end (both as client and access point) and TCP/IP stack with DNS support as well. While this chip has been very popular, its also been very difficult to use. Most of the low cost modules are not breadboard friendly, don’t have an onboard 500mA 3.3V regulator or level shifting, and aren’t CE or FCC emitter certified….UNTIL NOW! Read more.
Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, or even use Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for MakeCode, CircuitPython, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.
Python for Microcontrollers — Python snakes its way on the SparkFun SAMD21 Mini, Hackaday.io, 10k thanks, and Tim’s magazine #Python #Adafruit #CircuitPython @circuitpython @micropython @ThePSF @Adafruit
Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !