| ... | ... |
@@ -6,13 +6,26 @@ An assembler and emulator for the [Uxn stack-machine](https://wiki.xxiivv.com/si |
| 6 | 6 |
|
| 7 | 7 |
### Linux |
| 8 | 8 |
|
| 9 |
-To build the Uxn emulator, you must have [SDL2](https://wiki.libsdl.org/). |
|
| 9 |
+To build the Uxn emulator, you must install [SDL2](https://wiki.libsdl.org/) for your distro. For example: |
|
| 10 |
+ |
|
| 11 |
+```sh |
|
| 12 |
+sudo pacman -Sy sdl2 # Arch |
|
| 13 |
+sudo apt install libsdl2-dev # Ubuntu |
|
| 14 |
+``` |
|
| 15 |
+ |
|
| 16 |
+Build the assembler and emulator by running the `build.sh` script. The assembler(`uxnasm`) and emulator(`uxnemu`) are created in the `/bin` folder. |
|
| 10 | 17 |
|
| 11 | 18 |
```sh |
| 12 | 19 |
./build.sh |
| 13 | 20 |
--debug # Add debug flags to compiler |
| 14 | 21 |
``` |
| 15 | 22 |
|
| 23 |
+If you only wish to simply build the `uxncli` cli tool: |
|
| 24 |
+ |
|
| 25 |
+```sh |
|
| 26 |
+cc src/uxn.c -DNDEBUG -Os -g0 -s src/uxncli.c -o bin/uxncli |
|
| 27 |
+``` |
|
| 28 |
+ |
|
| 16 | 29 |
### Plan 9 |
| 17 | 30 |
|
| 18 | 31 |
To build the Uxn emulator on [9front](http://9front.org/), via [npe](https://git.sr.ht/~ft/npe): |
| ... | ... |
@@ -37,39 +50,29 @@ cd uxn |
| 37 | 50 |
|
| 38 | 51 |
## Getting Started |
| 39 | 52 |
|
| 40 |
-Begin by building the assembler and emulator by running the build script. The assembler(`uxnasm`) and emulator(`uxnemu`) are created in the `/bin` folder. |
|
| 41 |
- |
|
| 42 |
-``` |
|
| 43 |
-./build.sh |
|
| 44 |
-``` |
|
| 45 |
- |
|
| 46 |
-### Assembler |
|
| 53 |
+### Emulator |
|
| 47 | 54 |
|
| 48 |
-The following command will create an Uxn-compatible rom from an [uxntal file](https://wiki.xxiivv.com/site/uxntal.html). Point the assembler to a .tal file in `/projects` to assemble a rom. |
|
| 55 |
+To launch a `.rom` in the emulator, point the emulator to the target rom file: |
|
| 49 | 56 |
|
| 50 |
-``` |
|
| 51 |
-bin/uxnasm projects/examples/demos/life.tal bin/life.rom |
|
| 57 |
+```sh |
|
| 58 |
+bin/uxnemu bin/piano.rom |
|
| 52 | 59 |
``` |
| 53 | 60 |
|
| 54 |
-### Emulator |
|
| 55 |
- |
|
| 56 |
-To start the rom, point the emulator to the newly created rom: |
|
| 61 |
+You can also use the emulator without graphics by using `uxncli`. You can find additional roms [here](https://sr.ht/~rabbits/uxn/sources), you can find prebuilt rom files [here](https://itch.io/c/248074/uxn-roms). |
|
| 57 | 62 |
|
| 58 |
-``` |
|
| 59 |
-bin/uxnemu bin/life.rom |
|
| 60 |
-``` |
|
| 63 |
+### Assembler |
|
| 61 | 64 |
|
| 62 |
-You can also use the emulator without graphics by using `uxncli`. You can find additional roms [here](https://sr.ht/~rabbits/uxn/sources). If you only wish to build `uxncli` |
|
| 65 |
+The following command will create an Uxn-compatible rom from an [uxntal file](https://wiki.xxiivv.com/site/uxntal.html). Point the assembler to a `.tal` file, followed by and the rom name: |
|
| 63 | 66 |
|
| 64 |
-``` |
|
| 65 |
-cc src/uxn.c -DNDEBUG -Os -g0 -s src/uxncli.c -o bin/uxncli |
|
| 67 |
+```sh |
|
| 68 |
+bin/uxnasm projects/examples/demos/life.tal bin/life.rom |
|
| 66 | 69 |
``` |
| 67 | 70 |
|
| 68 | 71 |
### I/O |
| 69 | 72 |
|
| 70 | 73 |
You can send events from Uxn to another application, or another instance of uxn, with the Unix pipe. For a companion application that translates notes data into midi, see the [shim](https://git.sr.ht/~rabbits/shim). |
| 71 | 74 |
|
| 72 |
-``` |
|
| 75 |
+```sh |
|
| 73 | 76 |
uxnemu orca.rom | shim |
| 74 | 77 |
``` |
| 75 | 78 |
|
| ... | ... |
@@ -58,7 +58,7 @@ BRK |
| 58 | 58 |
[ #01 ] NEQk NIP ,&no-up JCN |
| 59 | 59 |
.selection LDZ STHk |
| 60 | 60 |
#00 ;draw-note JSR2 |
| 61 |
- [ STHkr GET-NOTE #01 ADD ] #00 STHkr ;melody ADD2 STA |
|
| 61 |
+ [ STHkr GET-NOTE INC ] #00 STHkr ;melody ADD2 STA |
|
| 62 | 62 |
STHr #01 ;draw-note JSR2 |
| 63 | 63 |
#02 ;draw-selector JSR2 |
| 64 | 64 |
&no-up |