diff --git a/hwTestSuite/tools.c b/hwTestSuite/tools.c index 0c9e7a3..4c0dad3 100644 --- a/hwTestSuite/tools.c +++ b/hwTestSuite/tools.c @@ -377,7 +377,7 @@ var listRomInfo(){ if(getButtonPressed(buttonSelect)){ //ROM must be attached to CSA(chip select a) on Dragonball VZ as it controls the boot up process - //the only 2 restrictions to use this dumper are, you need a Dragonball VZ Palm and internal RAM must be bigger than ROM / 128k rounded up to the nearest power of 2 * 128k + //the only 3 restrictions to use this dumper are, you need a Dragonball VZ Palm, an SD card must be inserted and the SD card must be bigger than ROM / 128k rounded up to the nearest power of 2 * 128k uint16_t csa = readArbitraryMemory16(HW_REG_ADDR(CSA)); uint16_t csgba = readArbitraryMemory16(HW_REG_ADDR(CSGBA)); uint16_t csugba = readArbitraryMemory16(HW_REG_ADDR(CSUGBA)); diff --git a/libretroBuildSystem/libretro.c b/libretroBuildSystem/libretro.c index eaffb42..1da5ded 100644 --- a/libretroBuildSystem/libretro.c +++ b/libretroBuildSystem/libretro.c @@ -243,7 +243,7 @@ void retro_run(void) palmInput.buttonSelect = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_R); //app buttons - palmInput.buttonCalender = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_Y); + palmInput.buttonCalendar = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_Y); palmInput.buttonAddress = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_X); palmInput.buttonTodo = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_B); palmInput.buttonNotes = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_A); diff --git a/qtBuildSystem/Mu/Mu.pro.user b/qtBuildSystem/Mu/Mu.pro.user index a33f4ee..2981348 100644 --- a/qtBuildSystem/Mu/Mu.pro.user +++ b/qtBuildSystem/Mu/Mu.pro.user @@ -1,6 +1,6 @@ - + EnvironmentId diff --git a/src/sed1376.c b/src/sed1376.c index 6506761..3d5105e 100644 --- a/src/sed1376.c +++ b/src/sed1376.c @@ -330,10 +330,10 @@ void sed1376Render(){ //rotation //later, unemulated - //software display inversion + //display inversion if((sed1376Registers[DISP_MODE] & 0x30) == 0x10) MULTITHREAD_LOOP for(uint32_t count = 0; count < 160 * 160; count++) - palmFramebuffer[count] ^= 0xFFFF; + palmFramebuffer[count] = ~palmFramebuffer[count]; //backlight off, half color intensity if(!palmMisc.backlightOn) diff --git a/src/sed1376Accessors.c.h b/src/sed1376Accessors.c.h index 37547c0..38cfc94 100644 --- a/src/sed1376Accessors.c.h +++ b/src/sed1376Accessors.c.h @@ -10,10 +10,13 @@ static inline uint32_t handlePanelDataSwaps(uint32_t address){ } //color conversion +static inline uint16_t swapRedBlue(uint16_t color){ + return color << 11 | (color & 0x07E0) | color >> 11; +} static inline uint16_t makeRgb16FromSed666(uint8_t r, uint8_t g, uint8_t b){ - uint16_t color = r >> 2 << 10 & 0xF800; + uint16_t color = b >> 2 << 10 & 0xF800; color |= g >> 2 << 5 & 0x07E0; - color |= b >> 2 >> 1 & 0x001F; + color |= r >> 2 >> 1 & 0x001F; return color; } static inline uint16_t makeRgb16FromGreenComponent(uint16_t g){ @@ -58,7 +61,7 @@ static uint16_t get8BppColor(uint16_t x, uint16_t y){ return sed1376OutputLut[sed1376Framebuffer[handlePanelDataSwaps(screenStartAddress + y * lineSize + x)]]; } static uint16_t get16BppColor(uint16_t x, uint16_t y){ - return sed1376Framebuffer[handlePanelDataSwaps(screenStartAddress + (y * lineSize + x) * 2)] << 8 | sed1376Framebuffer[handlePanelDataSwaps(screenStartAddress + (y * lineSize + x) * 2 + 1)]; + return swapRedBlue(sed1376Framebuffer[handlePanelDataSwaps(screenStartAddress + (y * lineSize + x) * 2)] << 8 | sed1376Framebuffer[handlePanelDataSwaps(screenStartAddress + (y * lineSize + x) * 2 + 1)]); } static inline void selectRenderer(bool color, uint8_t bpp){