It's about that time to finally start posting about my second attempt at moding a Sega Genesis Version 1 case and sticking a mITX PC into it.
This time it will be greatly different then last for multiple reasons.
I will be using proper tools to cut the backing as well as anything else within the case to ensure the items can proper fit, this is a change from using a handsaw last time which…didn't turn out that professional looking...
Everything will 'work' on the Sega Genesis as if it were a real Genesis:
The volume slider will change the volume in Windows
The power button and reset buttons will be usable, there will be a conversion of the pole switch to push button.
Headphone jack will operate correctly.
The controller ports will convert controllers into USB controllers.
LCD Screen that will show the Sega Genesis Logo on bootup of the PC, also play the SEGA bootup music we all know and love.
LCD Screen that will show/cycle through sponsored images when the PC is on
Probably a few more things too that will be added later on.
The list of the PC parts is still changing, as it will depend on what the sponsoring Real Hardware Reviews gives me to work with. I will update that when it keep changing and I have the parts in my hands.
To accomplish half of the tasks mentioned I will be using an Arduino to do some of the 'heavy' lifting. This is a perfect segway into what I have accomplished so far with the electronics sides of things.
The slider was one of the easier things to start with, as it is just hooked up to the Arduino's power source, ground, and to an analog input port. As it ranges from 0 to 1023 I need to drop this down to the number of 'steps' that the PC can boost the volume at. Turns out a volume increase or decrease command or keyboard event changes it by a value of 2 rather than one. This means going from 0 to 100 in volume I only have 50 steps. Dividing by 10.23 gives me a range of 0 to 100, which is perfect. I can send that value to the PC then have the PC program divide tat by 2 and give me the correct volume levels.
There are a few kinks to work out, the main one being that the Arduino and PC need to be synced to whatever the Arduino volume slider is set to when the PC is turned on. I need to fiddle with a few things, potentially making the slider not as sensitive since really I only need 50 steps, and I'm converting from 1024 steps.
I bought what is called a TFT LCD Module with SD Card Reader. The screen is 1.77" diagonal, with 160 x 128 pixel resolution, which is more than a perfect size to fit up inside of a Genesis cartridge, replacing where the game logo/sticker would be. The benefit of it having an SD Card Reader in it is that I can copy whatever image I want in bitmap form, put it on there, then just push the image from the SD card to the LCD using the magic of an existing Arduino library.
Here is the first working test of the Arduino Uno driving the TFT LCD Module:
Notice how slow it takes for the LCD to load an image, this is due to the speed of the processor and SPI lines.
I was able to borrow an Arduino Mega from a school friend who happens to live in the city to see if the more powerful Mega would allow me to load faster:
It is faster however you can still notice it takes more than a half a second to load the image.
To remedy this I went searching on the internet for solutions. I found out that the Arduino Due (which I have since ordered) is able to load images faster, especially with library someone has made using DMA. In test videos I've seen it load an image almost instantly, perfect for me to do the intro Sega music/animation when the PC turns on. As of right now I am waiting for it to come in the mail, so anything else with the LCD will mainly be adding more pictures to it, and hooking up the power and backlit to a transistor so I can turn the screen off with the Arduino when the PC is off.
With the LCD screen working and well on hold, I moved onto the second part of the Sega Bootup portion. This involves hooking up a speaker to the Arduino and then using a few libraries for it to play back audio. The fortunate part of having that TFT LCD module with SD Card is that I can store wav files on it and access it to push the audio out to the speaker.
After several hours of trying to figure out the library and how to properly hook it up I was rewarded with this:
Notice how quiet it is, this is due in part to the fact the Arduino output port has a rather low maximum current output on it (40 mA). At 5V (though it's PWM so it's never quite at 5V) the maxium wattage I can kick out is 200mW. As the speaker is an 8 Ohm 0.5W speaker, this is only about half the maximum it can receive.
I need to boost the signal, need to amplify it to be exact. Well I grabbed a trust NPN transitor, a resistor and configured it in a way to amplify the current. PLEASE NOTE, LOWER YOUR SPEAKERS ON THIS NEXT VIDEO:
As we can see this is considerably louder, to lower it, which I plan to, I'll need to change around the resistor I'm using, large the resistor, the lower the current being sent to the amplifier and thus quieter the speaker will get.
What I also need to do is throw on a high pass filter into this circuit to filter out any DC coming from the Arduino output as to make the sound a bit more crisp.
So far this is all I have to update, though as I stated I'll be tackling more of the PC volume control section shortly and hope to have that done. After that I plan to look at the Reset and more importantly the power button/switch configuration and how to determine when the PC is on or off (I have a few ideas that I'll need to test out).
Hopefully all will go well with this project and that it explained in a way that both the technical electronic hobbiest knows some of the nitty gritty details and that the average modder will understand too. Either way, let me know what you think, in the end this may end up becoming a contest prize, but we'll see with my sponsor later on.