0

Solving the 8-Queens Puzzle with an Adafruit 8×8 Mini LED Matrix

Dennis wrote in to share a project that students at Storming Robots have been working on.

Received an Adafruit Mini 8×8 LED Matrix w/I2C Backpack today.  After soldering and testing I wanted to try something else with it.

Some students here have been programming the classic 8-Queens puzzle where 8 queens must be placed on a chess board such that no two queens can take each other.  I thought the 8×8 matrix would make a good ‘chessboard’.  Each lit LED is a placement for a queen in a particular solution.  I have it hooked up to a large “breadboard Arduino” that I like using for testing things out. Naturally this will work with an Uno/Mega just fine.  For more info on the 8-Queens problem see the Wikipedia article.

Note: It runs through the 92 solutions pretty fast.  I was hand holding the camera and didn’t want to make the video too long.  I might post a video later with a longer delay between solutions.

Be sure to check out Storming Robots.  This looks like an amazing school in New Jersey!

What’s better than a single LED? Lots of LEDs! A fun way to make a small display is to use an 8×8 matrix or a 4-digit 7-segment display. Matrices like these are ‘multiplexed’ – so to control 64 LEDs you need 16 pins. That’s a lot of pins, and there are driver chips like the MAX7219 that can control a matrix for you but there’s a lot of wiring to set up and they take up a ton of space. Here at Adafruit we feel your pain! After all, wouldn’t it be awesome if you could control a matrix without tons of wiring? That’s where these adorable LED matrix backpacks come in. We have them in two flavors – a mini 8×8 and a 4-digit 0.56″ 7-segment. They work perfectly with the matrices we stock in the Adafruit shop and make adding a bright little display trivial.

In Stock and Shipping Now!


Join 7,000+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython in 2018 – Python on Microcontrollers is here!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Follow Adafruit on Instagram for top secret new products, behinds the scenes and more https://www.instagram.com/adafruit/


Maker Business — The many, many manufacturing processes listed on Wikipedia

Wearables — A bevel illusion

Electronics — Blown transistor?

Biohacking — We are Wired to Exercise at a Moderate Pace

Python for Microcontrollers — Make It Move with Crickit!

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !



No Comments

No comments yet.

Sorry, the comment form is closed at this time.