Close

Polarity Sucks

A project log for Joy Boy

Jump into the action with this awesome joystick for your Game Boy®. Now you're playing with power. Stick power.

sven-dahlstrandSven Dahlstrand 08/15/2019 at 10:060 Comments

Do you remember me telling you about both the Zinger (or any NES controller for that matter) and the Game Boy communicates using not quite SPI, but close enough. That's still true. However, I was naive thinking the two could have a conversation without an interpreter.

The problem resolves around clock polarity and the fact that the NES controller expects the clock signal to be idle low while the Game Boy thinks it should be idle high. Polarity 0 in one end, 1 in the other. That's no good.

There's no way for me to change the polarity from firmware, so additional hardware is probably needed. In the best-case scenario throwing an inverter (NOT gate) on the clock signal should suffice.

If you need to brush up your SPI skills, as I did, What Could Go Wrong: SPI by Elliot Williams is a great read.

Discussions