Port display to SSD1325 oled
Posted: Tue Aug 30, 2016 4:44 am
Hi.
Thanks for this kewl GB thingy! I like to port the screen from Nokia display to SSD1325 oled. I have a working lib for the ssd and the initialisation is like the one from the Nokia display.
Question: what does
mean? What's behind
Does it draw all the stuff on the screen again? Bitmap bg, sprites etc. p. p.? Or what in detail does it do?
And what's this Nokia display routine doing:
Thank you for information.
Thanks for this kewl GB thingy! I like to port the screen from Nokia display to SSD1325 oled. I have a working lib for the ssd and the initialisation is like the one from the Nokia display.
Question: what does
- Code: Select all
if(gb.update()){ //update everything
mean? What's behind
- Code: Select all
and updates everything (display, sound, batter monitor, etc.) at a fixed frequency (20 times per second by default)
Does it draw all the stuff on the screen again? Bitmap bg, sprites etc. p. p.? Or what in detail does it do?
And what's this Nokia display routine doing:
- Code: Select all
void Display::update(void) {
frameCount ++;
uint8_t col, maxcol, p;
for (p = 0; p < 6; p++) {
command(PCD8544_SETYADDR | p);
// start at the beginning of the row
col = 0;
maxcol = LCDWIDTH_NOROT - 1;
command(PCD8544_SETXADDR | col);
digitalWrite(dc, HIGH);
if (cs > 0)
digitalWrite(cs, LOW);
for (; col <= maxcol; col++) {
SPI.transfer(_displayBuffer[(LCDWIDTH_NOROT * p) + col]);
}
if (cs > 0)
digitalWrite(cs, HIGH);
}
command(PCD8544_SETYADDR); // no idea why this is necessary but it is to finish the last byte?
}
Thank you for information.