Gameboy Development Forum

Discussion about software development for the old-school Gameboys, ranging from the "Gray brick" to Gameboy Color
(Launched in 2008)

You are not logged in.


#1 2015-01-06 10:29:40

New member
Registered: 2015-01-06
Posts: 1

controlling LEDs with gameboy

Hi, this is my first post here.
i don't know is it fits here.. I think about controlling two sets of LEDs with gameboy. I mean two rows of LEDs, 4 LEDs each. for example set "A" and "B". when I press "a" button - all four LEDs of set "A" are on, when "b" button is pressed, all "B" LEDs are on. when buttons are released - LEDs are off. combination of direction buttons and "a" or "b" runs single led of each set - for example "up"+"a" = 1st LED of "A" set is on, "right"+"b" = 2nd LED of "B" is on....
is it possible to do it with with simple eprom cart? i would like to do it with output from cart, not with external connector.
sorry for my bad english and thanks in advance!



#2 2015-01-06 13:34:30

From: Wisconsin
Registered: 2014-09-23
Posts: 58

Re: controlling LEDs with gameboy

You could probably do that using the upper address pins for power and in your code tell it to look at an upper adress to turn it on. Not totally sure if that would work though.



#3 2015-01-09 12:20:06

Registered: 2010-10-23
Posts: 160

Re: controlling LEDs with gameboy

You can do what you want to do easily with a custom EEPROM/flash cartridge and a 8 bit D-Flip Flop plus a NAND gate.

Basically, instead of writing to SRAM, you would be able to write to an octal DFF and use it to drive the LEDs.

You can use an octal DFF with reset instead of enable so the LEDs don't end up in an unknown state before your program initially resets them. To do that, you will have to use additional logic to create a clock pulse when A15 and A13 are both high, CS is low and WE goes from low to high, i.e. #(A15 * A13) + #CS + #WE.

R1 and R2 are supposed to be specific series resistance values for your LEDs. LED logic is inverted, so a reset bit will make the LED light up, a set bit will turn the LED off.





Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson