Well, here it is. What I was able to do on this project in what amounts to three man-weeks of actual work.
build.gradle
: The build.gradle pulled from my Minecraft mod build
infrastructure. It's not enough to build it on its own, but it can be
cut-and-pasted into a monolithic build.gradle
to allow the project to be
built. (I can't release the project with the original build infrastructure
intact because it is entangled with a dozen other mods, some of which have
never been—and never will be—released publicly.)coprocessors.html
: The documentation for the JARM-specific coprocesors,
CP3 and CP7. All interactions with OpenComputers are handled through CP3. This
includes component IO. This documentation is extremely dry... it was written
for my own benefit. I was going to write a more accessible document later. I
believe that everything in this document, including asynchronous IO, is
implemented as described. (The C functions referenced in the document were
to have been implemented in some header as inline functions, but were never
actually written.)Java Code
: Contains the source code for the emulator core, the
OpenComputers architecture module & Minecraft mod, and an out-of-date test
application which probably no longer builds (let alone functions).C Code/jarmrom
: Contains most of the test ROMs I made, and a build system
(in the form of a GNU Makefile) for building those ROMs and others with
similar requirements. In particular, this includes the Tetris ROM.
Previously-released ROMs won't work with the current version of the mod, due to
a change in the way CP3 operates. The versions in this archive have all been
updated.C Code/luajarm
: Contains the source code for the Lua ROM, and enough
hacked-together C runtime to make it run. My malloc implementation has a bug
which causes heap corruption fairly early on; this is what I was working on
fixing when I became unable to work on this project. The first step would
probably be to replace my malloc implementation entirely. After that, the
functionality of machine.lua
and bios.lua
need to be implemented in order
for this ROM to achieve the functionality of the Lua 5.2 architecture module in
standard OpenComputers. (I think there are also a few unimplemented library
routines left over...)Unfinished aspects of the emulator core:
T
bit, but simply refuses to
decode instructions if it is set. A significant amount of Thumb's decoder was
going to share code with the ARM-32 instruction set. (Worth noting, the
current implementation of the CP14/15 registers lies and says that Thumb is
fully supported.)If you wish to work on this project yourself, please coordinate on the OpenComputers forums about it, to allow collaboration with others. And please, obtain "ARM Architecture Reference Manual, ARMv7-A and ARMv7-R Edition" and reference it for any questions of how the architecture should behave. It is available for free from ARM's website after a signup. Many parts of the emulator core are marked up with references to this document, particularly those dealing with instruction decoding or coprocessor registers.
I am releasing this archive and the source code contained therein to the public domain. Bear in mind the following, non-legally-binding, requests:
Note that C Code/luajarm
contains code from other projects, including Lua
itself, LLVM, and widely-used implementations of C's math library and the
strtod function. These are not public domain, even though the rest of the
code is. Consult those files for their license information.
Feel free to contact me with questions, scorn, etc. at solra@bizna.name.