UnoDOS pc64

Studio: the built-in IDE

Write, compile and run UnoDOS apps on the machine itself - no PC, no toolchain, no command line. Studio is a code editor, a real compiler and an AI assistant in one window, and the app it builds opens right next to it. Apps can be written in UnoC or in Python 3 - both first-class.

Studio: a monospace code editor with syntax highlighting, a project file list, a menu bar (File / Edit / Build / Run / AI / Help), and a build-output pane. It opens on a bundled bouncing-ball sample.

Edit, build, run - all on the machine

Studio compiles your source straight to a runnable app inside UnoDOS. There is nothing to install and no separate computer in the loop:

  1. Open Studio from the programs menu. It greets you with SAMPLE.PY, a small bouncing-ball app in Python (or SAMPLE.C, the UnoC version, if the Python runtime is not installed).
  2. Press Ctrl+B to build. The output pane reports the result - Packed SAMPLE.UNO for a Python file, or Built SAMPLE.UNO code=2303 ... for a UnoC file - and the new .UNO file appears in the project list.
  3. Press Ctrl+R to run it. Your app opens in its own window with its own taskbar button.
After Ctrl+B: the build-output pane reports the packed or compiled SAMPLE.UNO, and it joins the project list on the left.
After Ctrl+R: SAMPLE.PY runs in its own window with its own taskbar button, drawing and moving a block, while Studio stays open behind it.

If a build fails, the output pane lists each error with its line number; press or click a red error line and the caret jumps straight to it.

The editor

The editor is monospace with live syntax highlighting - keywords, types, strings, numbers, comments and preprocessor lines each in their own colour - a line-number gutter, and the usual editing keys: arrows and Home/End/PgUp/PgDn to move, Shift+movement to select, and Ctrl+X/C/V/A to cut, copy, paste and select all. Ctrl+S saves. The Project list on the left shows the source files on your working disk; click one to open it.

Two languages: UnoC and Python

Studio routes by file extension: a .c file is compiled by the built-in UnoC compiler, a .py file is packaged for the Python runtime. The editor, project pane, build output and AI assistant are the same either way. Use File → New and end the name in .c or .py to pick a language.

UnoC

UnoC is a practical subset of C that the built-in compiler accepts: the integer types (with long at 4 bytes, matching the system), pointers, arrays, struct/union, enum, typedef and function pointers, the full C expression and statement set, constant initializers, and a small preprocessor (#include "X.H", object-like #define, #ifdef). Floating point, variadic functions and function-like macros are left out. An app #includes UNO.H (in the SDK folder on the disk) and defines one entry point that returns a vtable the desktop drives:

#include "UNO.H"          /* the whole app SDK in one header */

static short bx = 40, by = 30, vx = 3, vy = 2;   /* a bouncing ball */

static void draw(UnoWin *w) {
    Rect f;
    short x0 = w->bounds.left + 10, y0 = w->bounds.top + TBAR_H + 8;
    SetRect(&f, x0, y0, x0 + 260, y0 + 160);
    fill_rgb(&f, &kField);                        /* true-colour fill    */
    SetRect(&f, x0 + bx - 9, y0 + by - 9, x0 + bx + 9, y0 + by + 9);
    fill_rgb(&f, &kBall);
}
static void tick(void) {                          /* ~60 times a second  */
    bx += vx; by += vy;
    if (bx < 9 || bx > 251) vx = -vx;
    if (by < 9 || by > 151) vy = -vy;
    { UnoWin *w = find_app_window(APP_RUNNER); if (w) draw_window(w); }
}
static const GameRGB kBall  = { 240, 200, 40, C_WHITE };
static const GameRGB kField = {  10,  40, 120, C_BLUE  };

/* the vtable the desktop drives: draw / key / click / tick / opened / closed */
static const AppInterface kIface = {
    draw, 0, 0, tick, 0, 0, "Bouncer", { 30, 30, 330, 260 }
};
const AppInterface *uno_app_main(const KernelApi *k) { gK = k; return &kIface; }

That is the whole shape of a UnoC app: draw into your window, react to keys and ticks, and hand back the vtable. The Writing apps page and the API reference cover the app model and the calls in depth.

Python 3

The same three-key loop works for Python, with real floats, classes and the math module. A Python app subclasses uno.App and reaches the platform through the uno module:

import uno

class Hello(uno.App):
    def draw(self, cv):
        cv.clear(uno.rgb(0, 0, 0))
        cv.text(8, 8, "Hello from Python", uno.rgb(255, 255, 255))

# the runtime looks up `app` and drives its methods for you
app = Hello()

The interpreter is MicroPython, shipped as the optional module APPS\PYRT.UNO; the whole story, the sample, the uno API and the Duum demo are on the Python apps page. The same reference ships inside UnoDOS under Help in Studio's menu bar.

The AI assistant

Studio has a built-in assistant that knows UnoC and the app API, so it can write and fix UnoDOS apps for you. It connects to ChatGPT (OpenAI), Claude (Anthropic) or Gemini (Google) over a secure connection. On a roomy desktop it appears as a column on the right; on the compact default desktop, raise the resolution in the Control Panel to bring it in.

Studio on a larger desktop, with the assistant column on the right beside the editor and project list. The editor's colouring shows keywords, types and numbers each in their own colour.

You supply your own API key from your provider and enter it once in the assistant's input line (each line is a slash command):

/provider anthropic          (or: openai, gemini)
/model claude-sonnet-4-5     (optional - a sensible default is used)
/key sk-ant-...              (your API key)
/save                        (writes AI.CFG so it persists)

The sensible defaults are gpt-4o-mini (OpenAI), claude-sonnet-4-5 (Anthropic) and gemini-2.0-flash (Gemini); /model overrides them, /clear resets the conversation. Then type a question and press Enter. The AI menu's Ask Assistant attaches the file you are editing to your next message, so you can ask "why won't this build?" with the code included.

About your key and privacyYour API key is stored in plain text in AI.CFG on the disk - anyone with the disk can read it, so use a low-value, revocable key rather than your main one. Your questions (and any attached file) are sent to the provider you choose. Secure connections check the site certificate against the built-in trust store and use the machine clock, so a wrong clock will stop them.

Studio is optional

Studio ships as a single loadable file, APPS\STUDIO.UNO, on the UnoDOS disk. A build that does not want the IDE simply leaves the file out - the rest of the system is identical, and Studio just does not appear in the programs menu.