Re:Show HN: I'm building a game for the Nintendo GameBoy
by BonsaiDen on Thursday August 14, 2014 @02:50PM
(#8179133)
Yes, it's all written in z80 assembly, although the GameBoy CPU really uses a mix of i8080 and z80 instructions, the mnemonics are all z80. I've also written my own assembler just recently, to have more control over the output and more easily generate debugging information: https://github.com/BonsaiDen/gbasm
[ Parent
| on HN ]
Re:Show HN: I'm building a game for the Nintendo GameBoy
by harwoodr on Thursday August 14, 2014 @02:54PM
(#8179156)
"my own assembler" - now you're just showing off. :)
Re:Show HN: I'm building a game for the Nintendo GameBoy
by BonsaiDen on Thursday August 14, 2014 @03:02PM
(#8179210)
Nah' I would only be showing off if I were to put it onto a real cartrdige and GameBoy, wouldn't I? ;)
- https://dl.dropboxusercontent.com/u/2332843/tuff.cartridge.j... - https://www.youtube.com/watch?v=yXNEeld8Lq8
Re:Show HN: I'm building a game for the Nintendo GameBoy
by stevelosh on Thursday August 14, 2014 @03:16PM
(#8179290)
If folks want to try it on a real Gameboy without all the wires, the Drag'n'Derp works pretty well. It's a Gameboy cart with a USB port for easy writing: http://derpcart.com/
Re:Show HN: I'm building a game for the Nintendo GameBoy
by BonsaiDen on Thursday August 14, 2014 @03:40PM
(#8179424)
I was looking at these option initially too, but ended up going for the challenge since, both I read some not-so-good reviews and shipping the thing to germany would probably ended up being at least as expensive as buying the soldering equipment :) Building one of those custom GamePaks takes about ~4 hours once you have all the materials prepared (you really need very, very thin wires!) and putting it together for the first time is one of those finger crossing moments which you'll remember for a really long time :)
Re:Show HN: I'm building a game for the Nintendo GameBoy
by DanBC on Thursday August 14, 2014 @03:48PM
(#8179464)
I took a cart, removed the game IC, and soldered in a ZIF socket for eproms. And I'm a klutz so it's easy enough.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by voltagex_ on Thursday August 14, 2014 @08:53PM
(#8180557)
Am I right in thinking that GameBoy carts are now a precious resource? We'll run out one day?
Re:Show HN: I'm building a game for the Nintendo GameBoy
by JonnieCache on Friday August 15, 2014 @08:01AM
(#8181768)
Pretty sure you could make your own with a 3d printer and one of those kitchen PCB-etching setups you see people using. There's no magic in there AFAIK.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by ant512 on Friday August 15, 2014 @12:12AM
(#8180993)
The Everdrive GB takes micro SD cards, so it has more space:
http://krikzz.com/index.php?route=product/product&product_id...
Re:Show HN: I'm building a game for the Nintendo GameBoy
by phaer on Thursday August 14, 2014 @03:03PM
(#8179216)
It sounds very advanced but an assembler for a rather simple architecture like z80 is much easier to write like most (other) compilers for example.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by ams6110 on Friday August 15, 2014 @11:30AM
(#8182610)
Used to be a standard 2nd or 3rd year assignment in a comp. sci. curriculum. Not sure if it is anymore.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by jldugger on Thursday August 14, 2014 @05:10PM
(#8179882)
When I was tinkering with gbdev 15 years ago, we had lcc targetting z80. It seems far less painful to write in C than asm.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by vegedor on Thursday August 14, 2014 @08:05PM
(#8180448)
C is just an advanced macro-assembler anyway.
Would seem painful enough as soon as speed or size became limited. C then was not as optimized as today. Old games used to be written in assembler, now the eeproms are bigger, the compilers are faster and portable.
Re:Show HN: I'm building a game for the Nintendo GameBoy
by glhaynes on Thursday August 14, 2014 @05:47PM
(#8180036)
although the GameBoy CPU really uses a mix of i8080 and z80 instructions, the mnemonics are all z80.
I'd love to hear more about this if anybody knows and feels like telling about it...
Re:Show HN: I'm building a game for the Nintendo GameBoy
by userbinator on Thursday August 14, 2014 @10:14PM
(#8180763)
It's a Z80-like core with some modifications; not all the Z80 instructions and registers are present and some instructions are completely different. Most instructions are the same as the 8080, but all 3 CPUs are not completely binary-compatible. It's neither truly an 8080 with added instructions, nor a Z80 with omitted ones.
For comparison: http://pastraiser.com/cpu/gameboy/gameboy_opcodes.html http://pastraiser.com/cpu/i8080/i8080_opcodes.html