Uxn - Virtual Computer

Got orca running on the DS version but I still have absolutely no idea how to even begin using that so I will have to try and compile some of the other roms and try those

The difference here is that the operator you’ll want to use to make notes is the = character instead of :.

Playing a note on the DS with Orca

With the DS version, is there any way to load different roms?

Not that I know of, it would be nice to be able to browse the various roms, I agree.

5 Likes

thanks!! Will give that a go and finally start learning Orca :slight_smile:

2 Likes

the way i got around that is creating a folder for each different application and putting in each one a copy of uxnds and a boot.rom (which is that particular application renamed). not ideal but it works! some roms work better than others on NDS though

3 Likes

So I managed to compile UXN and then Orca.tal on my Raspberry Pi Zero W and audio worked great through my cheap DAC hat (respeaker 2.0) For reference I’m using an old apple emac usb keyboard and I’m running raspbian lite without a window manager.

There seems to be no way to exit uxnemu / orca ? This might be intentional?
The delete key also does not work, backspace does though, I should be able to fix this myself though…
For anyone else out there in “keyboard only mode” I just found there are some useful shortcuts in orca.tal for saving and loading.

There seems to be no way to exit uxnemu / orca ?

Depends how you open Uxn, if you don’t have a window manager… I haven’t really considered that situation. Right now it expects the window to be closed, I don’t have any decoration so I do cmd+shift+q on i3.

The delete key also does not work, backspace does though, I should be able to fix this myself though

Let’s write some assembly!

The delete key was not mapped in Orca, I added just now. If you’re interested to know how to add it yourself, it would mean replacing:

DUP #08 ! ,&no-backspace JCN
	CHAR-DOT ;fill-block JSR2 
	;redraw JSR2 POP BRK &no-backspace

With

DUP #08 ! OVR #7f ! #0101 == ,&no-backspace JCN
	CHAR-DOT ;fill-block JSR2 
	;redraw JSR2 POP BRK &no-backspace

It now jumps only if the keycode is both NOT #08 and NOT #7f, with DUP #08 ! OVR #7f ! #0101 ==

5 Likes

@neauoire are you aware of Freeputer? Seems like a less art-focused kindred spirit given the goals and Forth inspiration.

1 Like

It’s the first time I heard of it, it’s kindda neat. Unfortunately, it was left off in a very incomplete state. I can’t seem to find any real usable applications for it. It’s pretty common for these experimental virtual machines to be just abandoned after they are able to spit out hello world and the fibonacci sequence.

Uxn is a sort of cross between CollpaseOS(with graphics and sound), a Famicom(with general computing devices) and Pico-8(with available sources).

3 Likes

You all may find this game that was recently released interesting. It’s an old school RPG that was coded for the Apple II in assembly. You can play it on modern computers through an emulator.

~/uxn

bin/uxnemu bin/orca.rom | bin/uxnemu bin/drum-rack.rom 
9 Likes

@abalone I love it :smiley: It’s nice to hear something pleasant come out of the simple audio chip.

I’ve been super busy these past couple of days figuring out how to implement readable text in Uxn. Here’s a Uxn window loading 3 fonts and displaying some text on the screen!

17 Likes

May I ask how the logic works with the drum kit? Is there a method to how the 2 digit commands line up with each pad?

Also, I wonder how difficult it would be to create a version of WebUxn such that you could upload tal files, and the result would be the output of the created rom. If I understand things correctly, it would make creating roms more accessible as you would only need a web browser and a text editor (to create the tal file). The current process isn’t difficult, but it could lower the barriers to entry for hobbiest programmers who want to explore assembly.

1 Like

Sure, it represents the pitch of the pad. Changing the pitch by pressing a different key changes the note of that pad. Here’s a little video to demonstrate that:

Also, I wonder how difficult it would be to create a version of WebUxn such that you could upload tal files, and the result would be the output of the created rom.

It shouldn’t be too hard, either someone could build the assembler to emscripten, or write an assembler in Javascript. I, personally, do not want to target the web platforms, but maybe someone will build that :slight_smile: I’ve passed your idea along to Bruno who maintains the javascript port.

1 Like

Thank you for the response.

I wasn’t clear regarding my drum rack question. I was playing around with uxn orca and the drum rack and using the “/“ to trigger the drums. But I couldn’t figure out if there was a methodology to determine how the two characters after the slash would line up with the drum rack.

is it a goal at all to ever port uxn to baremetal, perhaps with an init kernel to get things set up properly? that’d be hard with the SDL dependency, but it might be possible

@xxskylar_bleedxx is it a goal at all to ever port uxn to baremetal?

Yeah it is, and we do without SDL entirely. :slight_smile:

https://git.sr.ht/~alderwick/pico-uxn/tree

Typically, Uxn devices are re-implemented to fit the available hardware.

4 Likes

Any more details you can share here? I picked up that screen and want to implement similar on an ARM M0 or M4, maybe even make a PCB layout focused on running these Uxn roms. Are you implementing the VM at the Python or C level?

2 Likes

@kyle Alderwick has put together a couple of repos to get the uxn emulator to run on bare metal and draw on the memory display and pico pi.

https://git.sr.ht/~alderwick/

Wow! I thought this was going to be a lot more complicated than it turned out to be. Here is the SDL2/C version running on iOS with a few tiny tweaks to make it not crash. I look forward to diving into the details and understanding the VM better.

Not sure if there would be a good reason to remove the SDL dependency. Off the top of my head I’d imagine a ROM loader/switcher would be the next step since I’ve hard coded the piano into the startup code.


16 Likes

Idea: Adafruit BlackBerry keyboard and display FeatherWing + their Feather format version of the Pi Pico + bare metal Uxn

:thinking:

20 Likes

insert gif of Bit from Tron saying “yesyesyesyesyesyes”

4 Likes