Made SH4 compatible

Actually not tested but doesn't break SH3
This commit is contained in:
Geoffrey Frogeye 2014-04-08 18:46:29 +02:00
parent 4d1bc3fc4e
commit 69e8bafec1
2 changed files with 6 additions and 7 deletions

View file

@ -1,7 +1,7 @@
@echo off @echo off
rem Do not edit! This batch file is created by CASIO fx-9860G SDK. rem Do not edit! This batch file is created by CASIO fx-9860G SDK.
if exist debug\*.obj del debug\*.obj
if exist 2048.G1A del 2048.G1A if exist 2048.G1A del 2048.G1A
cd debug cd debug

View file

@ -1,6 +1,7 @@
/*************************************************************/ /*************************************************************/
/** MonochromeLib - monochrome graphic library for fx-9860G **/ /** MonochromeLib - monochrome graphic library for fx-9860G **/
/** MonochromeLib is free software **/ /** MonochromeLib is free software **/
/** MonochromeLib is now SH4 compatible ! **/
/** **/ /** **/
/** @author Pierre "PierrotLL" Le Gall **/ /** @author Pierre "PierrotLL" Le Gall **/
/** @contact legallpierre89@gmail.com **/ /** @contact legallpierre89@gmail.com **/
@ -116,12 +117,10 @@
#define rnd(x) ((int)(x+0.5)) #define rnd(x) ((int)(x+0.5))
//Thanks to Simon Lothar for this function //Thanks to Simon Lothar for this function
static int SysCallCode[] = {0xD201422B,0x60F20000,0x80010070}; typedef char*(*sc_cpv)(void);
static int (*SysCall)( int R4, int R5, int R6, int R7, int FNo ) = (void*)&SysCallCode; const unsigned int sc0135[] = { 0xD201D002, 0x422B0009, 0x80010070, 0x0135 };
char* ML_vram_adress() #define ML_vram_adress (*(sc_cpv)sc0135)
{
return (char*)((*SysCall)(0, 0, 0, 0, 309));
}
#ifdef ML_CLEAR_VRAM #ifdef ML_CLEAR_VRAM
void ML_clear_vram() void ML_clear_vram()