Basic GBC Question

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
Basic GBC Question
by on (#151649)
Hello, I'm quite new to the dev scene, but i'm enjoying it quite a lot.

Anyway, I wrote a simple program that will print out the hardware type it's running on. It runs properly on GBC hardware when $0143 is set to $00, but when in GBC/DMG compatibility mode ($80 @ $0143) and the program is running on GBC hardware, BGB shows a white screen.

Do i need to enable anything to be able to access CGB functionality?

The program loads an 8x8 font into VRAM and simply writes them to the display. I used [rBGP] for the palette settings, but maybe i need to do more on a CGB.

I plan to develop mainly for CGB, but most sample code is for DMG, so i'm working my way up.

I've read some mention of a document called abc409 about CGB dev. Does anyone know where i could find it?
Re: Basic GBC Question
by on (#151655)
You need to use color palettes on the GBC. The GBC will completely ignore the BGP register for its palette. It has specificc registers for color. You may need to mess around with VRAM banks to get the BG showing up.

See this page about video display stuff on the GBC: http://gbdev.gg8.se/wiki/articles/Video_Display
Re: Basic GBC Question
by on (#151805)
Thanks for the help! Do you know if i can make a color in the background palette transparent? (To make part of my window transparent)
Re: Basic GBC Question
by on (#151807)
No, unfortunately, if you want BG transparency, you either have to build something using OBJs (sprites) or graduate to the GBA.
Re: Basic GBC Question
by on (#151814)
Thanks for answering my question. I'll deal with that then.
I'm actually much more fluent in ARM assembly, since i learned it in school, but i'd rather develop for the GBC.
Re: Basic GBC Question
by on (#151820)
famiac wrote:
Thanks for the help! Do you know if i can make a color in the background palette transparent? (To make part of my window transparent)

Post a screenshot of what you want to happen, possibly using a wigglegram GIF to indicate what should be scrollable, and someone might help you find a workaround that combines the background, the window, and sprites to create an effect similar to what you depict.