From fb7816d80a6f10908f5cb55dc8e040bc40944f08 Mon Sep 17 00:00:00 2001 From: Egggggg Date: Wed, 12 Jul 2023 02:17:00 -0400 Subject: [PATCH] Get started --- .gitignore | 1 + .gitmodules | 3 +++ holey-bytes | 1 + run.sh | 11 +++++++++++ src/vfs.hbasm | 13 +++++++++++++ 5 files changed, 29 insertions(+) create mode 100644 .gitignore create mode 100644 .gitmodules create mode 160000 holey-bytes create mode 100755 run.sh create mode 100644 src/vfs.hbasm diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9f97022 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +target/ \ No newline at end of file diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..0023158 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "holey-bytes"] + path = holey-bytes + url = ssh://root@git.ablecorp.us:20/AbleOS/holey-bytes.git diff --git a/holey-bytes b/holey-bytes new file mode 160000 index 0000000..c1b2508 --- /dev/null +++ b/holey-bytes @@ -0,0 +1 @@ +Subproject commit c1b250874f87fab8533c61ac7254e0724cd35781 diff --git a/run.sh b/run.sh new file mode 100755 index 0000000..80a9453 --- /dev/null +++ b/run.sh @@ -0,0 +1,11 @@ +# exit if anything fails +set -e + +INPUT=$(realpath $1) + +mkdir target + +cd holey-bytes/hbasm +cat $INPUT | cargo run > ../../target/out +cd ../hbvm +cat ../../out | cargo run \ No newline at end of file diff --git a/src/vfs.hbasm b/src/vfs.hbasm new file mode 100644 index 0000000..1399834 --- /dev/null +++ b/src/vfs.hbasm @@ -0,0 +1,13 @@ +jmp r0, write + +write: + li r8, 64 + li r9, 32 + li r10, 16 + li r11, 8 + li r12, 4 + li r13, 2 + li r14, 1 + st r8, r0, fsdata, 6 + +fsdata: \ No newline at end of file