Skip to content

saturnus 0.1.0

Choose a tag to compare

@ractive ractive released this 09 Oct 02:11
· 979 commits to main since this release
dcd6edc

saturnus is a headless, clean-room emulator of the HP Saturn calculators,
written in Rust: a library first, with a command-line tool, a web page
and a desktop app on top. This is its first public release.

The calculators

Model State
HP 48SX boots, screens match the saturnng emulator, Kermit, real-hardware speed
HP 48GX boots, screens match, Kermit, real-hardware speed
HP 49G boots, screens match, Kermit, real-hardware speed (ROM 2.10 benchmark)
HP 38G boots to HOME, takes keys
HP 39G boots to HOME, takes keys, reset chords
HP 40G as the 39G (same ROM), with its CAS key
HP 42S boots, takes keys, runs its self-test

Get it

  • Web page, nothing to install: https://ractive.ch/saturnus/.
    The ROM you pick stays in your browser; nothing is uploaded. On a
    phone it can be added to the home screen and then works offline. The
    calculator keeps its state across reloads ("Start fresh" in the palette
    for an empty one).
  • Command line saturnus: cargo install saturnus-cli, or
    brew install ractive/tap/saturnus (macOS, Linux; Homebrew 6+ first
    brew trust --formula ractive/tap/saturnus), or
    scoop bucket add ractive https://github.com/ractive/scoop-bucket
    then scoop install saturnus (Windows), or an archive below
    (saturnus-v0.1.0-<target>; checksums in SHA256SUMS).
  • Desktop app: the installers below, .dmg (macOS, Apple silicon),
    .msi or -setup.exe (Windows x86_64), .deb, .rpm or .AppImage
    (Linux x86_64). The same page, with the core running natively; an
    empty ROM slot offers to download the image from hpcalc.org (not for
    the 42S, whose ROM was never released).
  • Libraries on crates.io: saturnus (the core: no dependencies,
    builds for wasm32), saturnus-objects, saturnus-host,
    saturnus-drive.

What you can do with it

  • Type and edit (48SX, 48GX, 49G): paste text, or pick a command in
    the palette (Cmd/Ctrl+K), and it is typed into the calculator's
    command line. The palette's editor opens a variable, a stack level or
    the command line as RPL text; Cmd/Ctrl+S sends it back, and the
    calculator compiles it. Cmd/Ctrl+E opens the selected object.
  • Memory view (48SX, 48GX, 49G): variables, directories, stack and
    flags, read live. Store a file by dropping it on the view, save a
    variable as a file, rename, purge, create a directory, change the
    current one, set flags. This goes through the calculator's own Kermit
    server and leaves the stack and the screen as they were.
  • Keyboard shortcuts (Alt+K): ON, α, the shifts and the app's
    actions can be bound to other keys.
  • Scripting: saturnus run --serve serves the serial port for
    Kermit clients and a control API on 127.0.0.1; saturnus ctl drives
    it (keys, screen, stack, type, text, store, fetch, …).
    saturnus ref is a command reference with examples run on the
    emulator.

The installers are not signed

They are built by this repository's desktop.yml workflow and not yet
signed with a developer certificate, so the operating system warns:

  • macOS: open the .dmg and drag saturnus to Applications. On the
    first start macOS says the app "is damaged" or "cannot be opened".
    Run once, in Terminal:
    xattr -dr com.apple.quarantine /Applications/saturnus.app.
    (If the message offers it instead: System Settings, Privacy &
    Security, "Open Anyway".)
  • Windows: SmartScreen says "Windows protected your PC". Click
    "More info", then "Run anyway".
  • Linux: packages are unsigned as usual.

ROMs are not included

saturnus ships no ROM and never will. saturnus rom fetch --model <m>
downloads the images hpcalc.org offers for use with emulators (48SX ROM J,
48GX ROM R, 38G A1.67, 49G 2.15, 39G/40G) after asking, and checks size
and SHA-256; the web page and the app take the same files. The HP 42S ROM
was never released: dump your own calculator (see the README).

Known limits

  • The 38G, 39G, 40G and 42S have no reference emulator to compare
    screens against; the 42S runs at a flat, uncalibrated 1 MHz and its IR
    printer is not modelled.
  • The memory view, the editor and the command reference cover the 48SX,
    48GX and 49G. On the 49G, writes other than flags need RPN mode (flag
    -95 clear).
  • The speed calibration is fitted to one benchmark per model (48SX, 48GX,
    49G); the reason for the fitted factor is not known.
  • The desktop app is built for Apple silicon Macs only (Intel Macs: use
    the web page or cargo install saturnus-cli) and has no auto-update.
  • The control API listens on 127.0.0.1 only, behind a token.

Clean room and AI notice

saturnus is written from public hardware documentation and the observed
behaviour of the calculators' own ROMs, not from the source code of other
emulators, and contains no HP logos or wordmarks. Parts of the code were
generated by AI systems under human supervision; see AI_NOTICE. MIT
licence.

See CHANGELOG.md for the full list.