How it works:

Each 1/2" (13mm) sphere is made from two 3D printed halves that have small magnets pressed in with each side having opposite polarity. These two halves are then glued together on a small rod with enough clearance to spin freely. Underneath each sphere is an electromagnet. The proximity of the sphere to the steel core of the electromagnet is just close enough to keep the sphere from being between 2 states or moving around. It also provides a nice "indexed" feel when you flip a sphere with your fingers. Very satisfying.

Writing:

A L9110S based DC motor drive motor controller board is used to drive a small electromagnet coil using 2 IO pins. Thank you to my brother Andy for this suggestion!

The controller sends 400 mA at 3.3 vdc for 200 ms to flip the sphere to whichever side has the opposite polarity by pushing the same polarity away and pulling the opposite. To flip it back, this is reversed in polarity. Surprisingly it works well with the first iteration of parts I was able to source on Amazon. (Blind dog concept in full effect)

I tried analogWrite(PWM) vs digitalWrite when driving the coils. I was not able to get it to work at anything less than 100% duty cycle. I did get the benefit of a neat whine from the coil though. I suspect that the digital write will be simpler to scale up using a multiplexer due to the limited outputs on most microcontrollers that I'd consider using. Each bit needs 2 IO pins to write and potentially an additional IO for the read. I think I might be able to reuse one of the write IO pins for a read though.

Example Code for the WRITE Operation:

void Ball_1_BLACK() 
{
  digitalWrite(2, HIGH);
  delay(200);
  digitalWrite(2, LOW);

}
void Ball_1_WHITE()
{
  digitalWrite(1, HIGH);
  delay(200);
  digitalWrite(1, LOW);

}

Reading: [PENDING IMPLEMENTATION]

My current thought on the READ functionality is to use an optical sensor of some sort that can sense the difference in color from the bottom side. This would be easy to hide under the grid and should be easy enough to detect a difference in the black vs white side of the sphere.

I am open to suggestions! Please comment if you have some ideas.

End Goal:

A 64 (8x8) bit grid with READ/WRITE capabilities. Why 64? My brother's Core64 Interactive Core Memory project uses 64 bits and it seems just right for usability but not too many that it won't be possible to build for a reasonable cost.

Building this in 2 bit modules is likely going to be my approach. The DC motor driver boards can drive 2 coils each. This also makes replacing faulty or worn out parts easier. Additionally it allows for expansion if I wanted to get really crazy. Imagine an entire wall filled with these like a traditional flip dot display?

The final version will have a laser cut wood front panel. Don't worry, there won't be hot glue visible everywhere like in the proof of concept here.

Here is a video of the concept with a version of the sphere where the magnets are visible and just sitting in my hand over the electromagnet.

Video of all 4 bits flipping:

Close Up: