Loading 8/16 bits from ROM
Jeffrey Pfau jeffrey@endrift.com
Mon, 08 Apr 2013 02:13:40 -0700
1 files changed,
4 insertions(+),
0 deletions(-)
jump to
M
src/gba.c
→
src/gba.c
@@ -129,6 +129,7 @@ case BASE_CART1:
case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((int16_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1)) >> 1]; break; case BASE_CART_SRAM: break;@@ -163,6 +164,7 @@ case BASE_CART1:
case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((uint16_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1)) >> 1]; break; case BASE_CART_SRAM: break;@@ -197,6 +199,7 @@ case BASE_CART1:
case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((int8_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1))]; break; case BASE_CART_SRAM: break;@@ -231,6 +234,7 @@ case BASE_CART1:
case BASE_CART1_EX: case BASE_CART2: case BASE_CART2_EX: + return ((uint8_t*) gbaMemory->rom)[(address & (SIZE_CART0 - 1))]; break; case BASE_CART_SRAM: break;