Mercurial > vba-clojure
diff src/clojure/clojure.cpp @ 61:dc8b383ecefa
added code to retrieve other RAM areas and ROM
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Wed, 07 Mar 2012 19:53:39 -0600 |
parents | ef59aee6d715 |
children | 4699c7bab77d |
line wrap: on
line diff
1.1 --- a/src/clojure/clojure.cpp Wed Mar 07 19:29:51 2012 -0600 1.2 +++ b/src/clojure/clojure.cpp Wed Mar 07 19:53:39 2012 -0600 1.3 @@ -121,8 +121,6 @@ 1.4 return getRamSize(); 1.5 } 1.6 1.7 - 1.8 - 1.9 /* 1.10 * Class: com_aurellem_gb_Gb 1.11 * Method: getRAM 1.12 @@ -136,4 +134,43 @@ 1.13 } 1.14 1.15 1.16 +/* 1.17 + * Class: com_aurellem_gb_Gb 1.18 + * Method: getROM 1.19 + * Signature: ([I)V 1.20 + */ 1.21 +JNIEXPORT void JNICALL Java_com_aurellem_gb_Gb_getROM 1.22 +(JNIEnv *env, jclass clazz, jintArray arr){ 1.23 + jint *ram_store = env->GetIntArrayElements(arr, 0); 1.24 + storeRom(ram_store); 1.25 + env->ReleaseIntArrayElements(arr, ram_store, 0); 1.26 +} 1.27 1.28 + 1.29 +/* 1.30 + * Class: com_aurellem_gb_Gb 1.31 + * Method: getWRAM 1.32 + * Signature: ([I)V 1.33 + */ 1.34 +JNIEXPORT void JNICALL Java_com_aurellem_gb_Gb_getWRAM 1.35 +(JNIEnv *env, jclass clazz, jintArray arr){ 1.36 + jint *ram_store = env->GetIntArrayElements(arr, 0); 1.37 + storeWRam(ram_store); 1.38 + env->ReleaseIntArrayElements(arr, ram_store, 0); 1.39 +} 1.40 + 1.41 + 1.42 +/* 1.43 + * Class: com_aurellem_gb_Gb 1.44 + * Method: getVRAM 1.45 + * Signature: ([I)V 1.46 + */ 1.47 +JNIEXPORT void JNICALL Java_com_aurellem_gb_Gb_getVRAM 1.48 +(JNIEnv *env, jclass clazz, jintArray arr){ 1.49 + jint *ram_store = env->GetIntArrayElements(arr, 0); 1.50 + storeVRam(ram_store); 1.51 + env->ReleaseIntArrayElements(arr, ram_store, 0); 1.52 +} 1.53 + 1.54 + 1.55 +