我不是特别有经验与大会和胳膊,但我能在它写几个程序,我想看看他们的ARM-搭载了Android设备(歌Nexus S)上的运行方式。什么是包括大会code文件到一个Android项目的过程?我只能从本地code调用它,或者从Java也?
I'm not particularly experienced with Assembly and ARM, but I was able to write a few routines in it and I'd like to see how they run on an ARM-equipped Android device (Nexus S). What is the procedure for including an Assembly code file into an Android project? Can I only call it from native code, or from Java also?
您可以从Android的使用Java本地接口和Android NDK调用组件。
You can call assembly from Android using the Java Native Interface and the Android NDK.
塞德里克提到使用 ASM 的关键字,而我preFER包含汇编源$ C $ C。我已经发布了一个教程在我的网站要做到这一点: http://www.eggwall.com/2011/09/android-arm-assembly-calling-assembly.html
Cedric mentions using the asm keyword, while I prefer to include assembly source code. I have posted a tutorial to do this at my site: http://www.eggwall.com/2011/09/android-arm-assembly-calling-assembly.html
您可以下载源$ C $下我的例子,看看它是如何工作的。当你看到一个正常运作的例子,很容易将其修改您的需求。
You can download the source code for my example and see how it works. Once you see a functioning example, it is easy to modify it to your needs.