Tumblelog by Soup.io
Newer posts are loading.
You are at the newest post.
Click here to check if anything new just came in.

July 14 2011

16:12

April 30 2011

07:29
07:28

April 18 2011

04:09

April 16 2011

01:11

January 21 2011

19:07
19:06

January 06 2011

08:27
08:26
07:53
07:51

January 26 2010

18:02

New track: Nitrojazz

Time for some NES-eque and short but sweet Gameboy jazz. Listen at chipmusic.org.

http://chipmusic.org/nitro2k01/music/nitrojazz

January 08 2010

05:15

Sparkfun Free Day

Sparkfun Free Day

Sparkfun Free Day

Sparkfun Free Day

For those of you who missed it, yesterday was Sparkfun free day, when Sparkfun would give away $100 to all customers, up to a grand total of $100,000. I didn’t really expect to be one of the winners in the noble battle. As one might imagine the demand for the offer was high, and I expected that the pot would be used up within minutes. The problem however turned out to be quite the opposite. The server was so overloaded that nobody could get through. When submitting a form, the page would load for 5 minutes just to tell me the connection was aborted. I heard a rumour that someone had managed to place the first order order after 30 minutes. So I kept pressing F5 persistently as soon as a page returned an error, and I managed to place my order just in time. At that point things were working relatively well, given the circumstances, (Only had to refresh three times before getting a connection) And as you can see from the remaining time and money counters, $9000 (~90 users) were served over the course of three minutes. I’m guessing people started to give up by then.
My persistence paid off, and unless they mess up the shipping somehow, I’ll soon be the owner of a Spartan 3E FPGA.

December 05 2009

09:35
09:34
09:33
09:33

November 23 2009

07:10

How to patch your DMG to use an inverted palette

Normal:

Inverted:

(Please excuse the shabby look, but that is my guinea pig Gameboy that I use for experimentation.)
I’ve already explained how you can invert the monochrome palette in LSDj which is useful if you have a DMG backlight with an inverted polarizer film on your DMG. But what if you want to use a normal palette for other software or games?
Modding the ROM of the game or program you want to invert the palette for is an option, but it may not be practical. Fear not however, the protocol that the DMG is using to transfer data from its all-in-one chip to the LCD is strikingly simple, and can easily be inverted with a 74hc logic circuit of your choice.

First let’s have a look at how the protocol works.

Gameboy DMG vido protocol
For the sake of this tutorial there are three important pins to keep track of. Data bit 0, data bit 1 and clock. At every rising edge clock edge (when the clock line changes from 0V to +5V) the current state of the data lines is recorded, and the corresponding pixel value is drawn to the currently active pixel on the LCD. This keeps goes until the whole screen is filled with an image. And then again and again. (Ok, there are more aspects to it, like so called “blanking” but that’s not relevant for this discussion)

So what you need to do is change the values of the data lines in such a way that black becomes white, light gray becomes dark gray and so on. The way to do this is by simply inverting the two data bits. There are (at least) two possible ways to do this.

74hc04 pinout
One way is to use a simple inverter like 74hc04, where you connect the data bits to the appropriate input and outputs. Also note two things abut the schematic:
1) I have connected all unused input to ground. (Unused outputs should remain unconnected)
2) I’ve added a bypass capacitor between Gnd and +5V
Neither one of these things are strictly necessary but they are good practice, and may help reduce interference to the signal if that would be a problem.

And obviously you can use any pair of inputs and outputs on the chip.

74hc86 pinout
The other way of doing it, which is what I did for my prototype, is to use xor gates. (74hc86) The advantage of that method is that you can switch between the modes easily with a switch. If you xor a bit value with 0, you get back the same bit value. If you instead xor the bit value with 1, you get back the inverted value. So in this configuration, I’ve connected a weak pullup resistor, which sets one of the inputs to 1 by default, meaning the image is inverted by default. However, if those inputs are shorted to ground, the xor operation returns the original data and the picture is again unaffected.


So, how does one actually connect the inverter? You need to cut the copper trace where the data and solder the input and outputs on each side of the cut.
This is what my prototype circuit looks like. I’ve connected the inputs of the inverter to the appropriate holes that are already available in the motherboard, but filled with solder.

A sidenote on these holes: They were most probably placed there to enable connection to the WideBoy unit, which was an official Nintendo development kit that allowed the screen image of a Gameboy to be displayed on a TV with the help of a NES.


At any rate they come in handy now. The above diagram show you where to tap the input signals, where to cut the traces, and where to solder the output wires. When cutting the traces make sure you cut them properly, or you’ll have a conflict. Do not cut the Clk trace.
All three holes shown to the right in the diagram are connected to Gnd.

Last but not least, a video of the thing in action:

So… Tell me what you think. Is this information useful? Anything unclear? Is my English to quirky and corny? Anyone nterested in buying kits for this thing?

05:17
05:16
Invert the monochrome palette on your DMG Gameboy
Schematic for use with a button
Older posts are this way If this message doesn't go away, click anywhere on the page to continue loading posts.
Could not load more posts
Maybe Soup is currently being updated? I'll try again automatically in a few seconds...
Just a second, loading more posts...
You've reached the end.