INTRODUCTION

Below should be everything you need to know in order to make a KTRL CD32+ gamepad. It all comes down to these steps: Get the needed parts, prepare the gamepad case, solder the components, program the microprocessor* and finally, put it all together.

*) or get the microprosessor preprogrammed from me.

1. GET ALL THE PARTS

GAMEPAD CASE

I have designed the PCB to fit the cheap SNES style USB gamepads available on eBay and elsewhere. There are a few different models out there but the best ones I have found for this are the iNNEXT branded ones. They look like this:

This gamepad comes in black and gray. Search for "innext snes" on eBay and you should find several sellers selling these, usually in packs of two for about 7€ and up plus shipping.

THE CABLE

I have been using Sega Mega Drive gamepad extension cables for this, those have all 9 pins connected (all 9 are needed for this gamepad). I just cut the male connector off. These can also be found on eBay of course (and other places). Search for "sega genesis extension" on eBay and you should find several. The price can be as low as 2.20€/cable

THE PCB

You can order the PCB from me on Amibay.com.

THE MICROPROCESSOR

The microprocessor used by the KTRL CD32+ is the ATMega328P/ATMega8A (TQFP-32 package). You can buy this from eBay, electronic component retailers or buy them preprogrammed from me on Amibay.com.

OTHER COMPONENTS

I also sell the other electronic components needed in the same Amibay.com thread as a set. Here is the list of other components if you want to get them from somewhere else:

0805 SMD components
220ohm (2200)1
2K2ohm (222,2201)1
10kohm (103,1002)2
18pF (180)2
470pF (102)1 (optional)
100nF (104)1
Other SMD components
16MHz crystal (5*3.2mm 5032 2pin)1
Through hole components
100µF/220µF electrolytic cap 16V1
LED (red, 3mm, flat top)1
Other parts
Wire, red, ~6cm (2 1/3")1
Wire, black, ~6cm (2 1/3")1
Pin headers (2,54mm pitch)6
Shrink tube, dia: 4mm, length: 6mm1

STICKERS

The "KTRL CD32+" logo and cheat sheet stickers are included when you buy the PCB in the Amibay.com thread.

USBASP PROGRAMMER (optional)

To program the Atmega you will a USBAsp programmer. These are very cheap and available readily on eBay. Search for "usbasp" and you should find them for less than 2€. For this you also need Dupont jumper wires (Female-Female). Search on eBay for "dupont male female". Note that if you buy the Atmega preprogrammed from me you don't need this but I might release updates to the firmware later.

2. PREPARE THE GAMEPAD CASE

Unscrew the five screws of the gamepad to open it and remove all the parts. You will need the small shoulder button PCBs connected to the main PCB so don't throw anything away just yet.

Optional but recommended: Drill a 3mm hole for the LED in the top part of the case according to the picture below. You don't need to install the LED but it helps with configuring the controller.

Optional: Remove the face button sticker (with the A,B,X,Y markings). I have found that the best way to do this is to use a hair dryer to heat up the sticker (for about 10-15 seconds, don't overdo it if you have a powerful hair dryer), then the sticker usually peels off without leaving any residue on the gamepad case.

Optional: Apply the stickers. The logo sticker can cover the "iNNEXT" logo entirely. The cheat sheet sticker goes to the back (in the recessed area).

3. SOLDER

THE PCB COMPONENTS

Solder the the PCB components according to the following layout (Click the picture to view a larger version). SMD capacitors are either marked with codes or colours as in the layout image. Note that C5 is optional. Also, you don't need to solder the pin headers, the ATMega can be programmed anyway if you ever need to.

THE LED (optional but recommended)

1. Bend the legs of the LED 90° about 5mm from the actual LED and cut the legs about 5mm after the bend, leaving the longer leg about 1mm longer so you still know which leg is which.

2. Solder a red wire to the longer leg and a black wire to the shorter leg.

3. Use the heat shrink tube to cover the solder joints.

4. Solder the wires to the PCB, red to LED+ and black to LED-. Check the picture above (under the components layout) for reference.

THE CABLE

Remove about 35mm of the sleeve of the cable, and remove a few millimeters of the sleeve of every wire. Use a multimeter to figure out which wire goes to which pin. The table below shows cable colors for cables acquired from eBay with codes 4N40011, AAJ104895001 and VG0006450. It's recommended that you double-check this using a multimeter.

Ensure the correct pin numbers (marked on the main PCB) when soldering the cable. Failing to do so could cause damage to the KTRL gamepad or your Amiga!

Pin4N40011
AAJ104895001
VG0006450
I181054Unmarked
(smaller plug)
1RED BLUE YELLOW
2BLACK ORANGE ORANGE
3GRAY YELLOW RED
4ORANGE WHITE BROWN
5BROWN RED BLACK
6GREEN GREEN GREEN
7WHITE PURPLE BLUE
8BLUE GRAY GRAY
9YELLOW BLACK WHITE

THE SHOULDER BUTTON PCBS

The wires should be on the top side, otherwise they may be hard to install (plastic in the way). wires can be connected any way, the polarisation doesn't matter. Check the picture above (under the components layout) for reference.

CLEAN AND INSPECT

When all components etc. are soldered, give the PCB a proper clean with rubbing alcohol, the flux residue can cause noise in the circuit. Check for any shorts between the legs of the ATMega. Verify the polarization of the electrolytic capacitor a final time.

4. PROGRAM THE ATMEGA (if you didn't get a preprogrammed one from me)

INSTALL DRIVERS FOR USBASP (Windows)

Connect the USBAsp to USB port. Don't try to find a driver, cancel the automatic driver install if possible.

Download and run Zadig for easier driver installation: http://zadig.akeo.ie/

In Zadig, choose USBAsp in the drop-down list. If you can't see the device in the list, go to the Options menu and select List All Devices, be sure to select the correct device.

Select driver "libusbK (v3.0.7.0)" and click Install Driver (or Replace Driver). If you get a security alert, choose to install the driver anyway.

THE ACTUAL PROGRAMMING

Download the latest firmware and necessary files here (for Windows). If you use Mac OS or Linux you need to install AVRDude, there should be tutorials how to do this.

Connect the USBAsp to the KTRL CD32+ pin headers with the dupont wires according to to the pictures below (if you haven't soldered the pin headers you can just keep them in place while programming, pressing them so they make good contact). Then connect the USBAsp to a USB port of your computer.

You then need to run the commands below in a command prompt / shell (from the folder where you extracted the firmware). The LED on the KTRL should blink twice when programming is finished.

ATMega328p

// Erase the chip (only needed if chip is not empty). This is done at a slower speed (-B 3)
avrdude.exe -p m328p -c usbasp -P usb -B 3 -e

// Set the fuses to enable external crystal etc. This is done at a slower speed (-B 3)
avrdude.exe -p m328p -c usbasp -P usb -B 3 -U lfuse:w:255:m -U hfuse:w:223:m -U efuse:w:5:m -U lock:w:63:m

// Write the firmware
avrdude.exe -p m328p -c usbasp -P usb -U flash:w:"KTRL_CD32+_ATMega328p_v100.hex":a

ATMega8

// Erase the chip (only needed if chip is not empty). This is done at a slower speed (-B 3)
avrdude.exe -p atmega8 -c usbasp -P usb -B 3 -e

// Set the fuses to enable external crystal etc. This is done at a slower speed (-B 3)
avrdude.exe -p atmega8 -c usbasp -P usb -B 3 -U lfuse:w:255:m -U hfuse:w:201:m

// Write the firmware
avrdude.exe -p atmega8 -c usbasp -P usb -U flash:w:"KTRL_CD32+_ATMega8_v100.hex":a

5. PUT IT ALL TOGETHER

Add all the face buttons + rubber (according to the CD32 layout, see picture below), dpad + rubber and select/play buttons to the gamepad case and then install the PCB.

The LED goes through the hole in the case and the cable will hold the LED in place. See the picture below.

Position the PCB so it lies as straight as possible, there is some small margin of rotation possible.

Finally add the shoulder buttons and screw the case together.

6. USE IT!

Get the instructions (and cheat sheet) and play your favourite games!

INSTRUCTIONS (PDF FOR VIEWING ON SCREEN)

INSTRUCTIONS (PDF FOR PRINTING)
(Print the two pages on both sides of a sheet of A4 (duplex), then cut off the empty space at the bottom and fold the paper in the middle to get a small four-page booklet.)