BeBox is a Haiku application that emulates Be Inc.'s BeBox

Hacker News by 13 min read 78x views
BeBox is a Haiku application that emulates Be Inc.'s BeBox

Share Post

BeBox is a Haiku use that emulates Be Inc.'s BeBox, the dual-processor device that BeOS was delivered on. It runs the two PowerPC models from their first footwear ROMs, alongside BeOS for PowerPC from Developer Release 6 through R5.0.3. It additionally runs the Hobbit prototypes that came before them, built about two AT&T Hobbit processors, alongside Be's 1993-94 scheme from their living disks.

The BeBox footwear ROM's Be logo The Hobbit prototype's Browser, HeapWatch and Clock BeOS 1.1d6 BeOS R3 alongside GL Teapot, BeBounce and the CPU monitor BeOS R5.0.3 on the BeBox Bebox preferences

Model Processors Bus
BeBox Dual603-66 two PowerPC 603 at 66 MHz 33 MHz
BeBox Dual603e-133 two PowerPC 603e at 133 MHz 33 MHz
Hobbit prototype (1993-94) two AT&T 92010 (Hobbit) at 25 MHz BeBus, 25 MHz

The opening shows the emulated display between the two forefront panel LED columns (the "blinkenlights"), sixteen ray pipe segments each: a CPU load bar of fifteen LEDs complete the power LED (left) or the disk LED (right), lime and amber akin the genuine ones (or red and green, if you prefer).

  • Both processors (a PowerPC 603/603e translator alongside the 603's software TLB), the MPC105 bridge, the BeBox interrupt and CPU authority registers.
  • Boot ROM: the nub and chief ROM in a writable flash (BeOS's ROM updater works), NVRAM and genuine period clock.
  • Video: Number Nine #9 GXE64 (S3 Vision864, AT&T 21C498 RAMDAC) alongside its graphics engine, the default; or Cirrus Logic CL-GD5434. 640x480 to 1280x1024, 8 and 32 bits per pixel (what the BeOS drivers offer).
  • Sound: Crystal CS4231A codec, played through the Haiku media kit.
  • AT keyboard and PS/2 mouse; four equivalent ports (axes and buttons).
  • Storage: NCR 53C810 SCSI (disks and CD-ROMs on IDs 0-6), IDE, floppy.
  • Four serial ports: to a console window, a TCP server or client, a host serial harbor or a log file.
  • Ethernet: an NE2000 compatible ISA cardstock on a personal network rearward the host (NAT, through libslirp): the BeBox reaches the presenter and the Internet, and presenter ports can be forwarded to it.
  • Shared folders: a Haiku directory appears to BeOS as a SCSI disk it can read and write; the changes arrive rear to the directory whenever BeOS shuts down.

Not emulated yet: the parallel port, GeekPort, MIDI and infrared ports.

  • The BeBox footwear ROMs, which are not included: bootnub.rom (16 KB) and bootmain.rom (Be Boot ROM 1.1d7) from a BeBox, in a directory of your choice.
  • BeOS for PowerPC: CD images (ISO, BIN/CUE or Toast).
  • For the releases alongside the Be File System (Advanced Access to R5): a newer footwear ROM, which the Preview Release 2, R3 and R4.5 CDs transport as /beos/etc/bebox_bootmain.image (Advanced Access, Preview Release 1 and R5 use one of those). BeBox extracts it for you (see below).
  1. Open Machine > Preferences > ROM & NVRAM and choose the directory with the ROMs. For a BFS release, choose its CD depiction as Boot ROM image: BeBox copies the footwear ROM from the CD (PR2's additionally boots Advanced Access and PR1).
  2. In Storage, put the CD depiction on a SCSI ID as CD-ROM (ID 3 is the classic choice), and provision another ID a disk for installing: Choose... opens a document panel whose New disk image... clasp makes one right there (in the directory the panel shows) and puts it on that ID.
  3. Machine > Power on. The newer footwear ROMs halt at their footwear list when no footwear quantity is set yet: media Return.

Changes to the hardware restart the machine. A equipment category set without a file is turned rear into "None" whenever the preferences are saved.

Before the PowerPC BeBox, Be built its device about two AT&T 92010 "Hobbit" processors, three AT&T DSP3210 indication processors and the BeBus. A few prototypes last alongside their disks, operating Be's 1993-94 system: a window server, a console, the Browser and its dock.

What is emulated:

  • Both Hobbit processors (an translator written from AT&T's programmer's reference: the stack cache, the MMU, the timers, the event sequences).
  • The board: its I/O and interrupt registers, the processor resets, the floppy DMA; the PC compatible I/O chips (keyboard and PS/2 mouse, real time clock, two serial ports, floppy) and the NCR 53C94 SCSI controller.
  • The video card: a Trident VGA alongside an XGA manner graphics motor on the BeBus (640x480 or 800x600, 256 colors, as the opening servers set it).

Not emulated: the three DSPs and what hangs off them (sound, the telephone and modem), the Ethernet card, the joystick controller and the parallel port. The scheme starts without them (its audio server reports an error).

No footwear ROM of these machines survives, so BeBox does the footwear ROM's job: it loads /system/kernel from the footwear quantity (the floppy if one is inserted, alternatively the SCSI disk alongside the lowest ID) and starts it. To run one:

  1. In Preferences > Machine, choose Hobbit prototype and 4, 8, 16, 20 or 32 MB of recollection (the sizes its kernel knows).
  2. In Storage, put a Hobbit disk depiction on a SCSI ID as a disk. To run a kernel of your own alternatively of the disk's, choose it in ROM & NVRAM > Hobbit kernel.
  3. Machine > Power on. The kernel reports its advancement on serial port 1 (give it a console opening in Serial to watch).

Notes:

  • The November 1994 disks commencement /system/Browser, which they have as /system/browser: the console comes up alternatively (the genuine machines did the same). Type /system/browser & in it to commencement the Browser.
  • The floppy run is the kernel's run 1.
  • The scheme writes to its disk (swap records and more): keep a copy of your images, or use them through QCOW2 overlays (bebox-img create -b IMAGE OVERLAY.qcow2).
  • The forefront panel lights are hidden: the Hobbit's kernel drives none.

Installing from the floppies

The installer floppy and disks 1of7 to 7of7 instal the November 1994 system (the one on the "pixels" disk) on a new disk. The installer floppy has no opening of its own: its /system/Browser copies a minimal system (kernel, servers, shell, /Installer) from the floppy to the archetypal hard disk, without asking and without showing item but the pointer. Boot it only alongside the disk to instal on: it replaces the scheme records of any other Hobbit disk it finds.

  1. Put a copy of a Hobbit disk (or an overlay of one) on SCSI ID 0, and a new disk depiction on ID 1 (in Storage, the ID's document panel has New disk image...; 120 MB works, the first disks have 120 to 170 MB). Power on, category /bin/format in the console, choose the SCSI disk with ID 1, provision the quantity a name, afterward 0 to leave. Power off.
  2. Take the Hobbit disk off ID 0 and put the new disk there instead. Insert the installer floppy and power on. After concerning a infinitesimal (the pointer is all you see), power off and eject the floppy.
  3. Power on: the console comes up from the new disk. Type /Installer, click Begin, afterward insert 1of7 (Media > Insert floppy...) and click Continue, and so on up to 7of7. The Installer then uncompresses, verifies and extracts the archive (a few minutes), and Install finishes: "Installation complete". When it starts uncompressing, the console shows VOLUME:/_install_/archive.Z: System Error 0: harmless, and a genuine Hobbit did the identical (compress deletes the archive during it motionless has it open, which this document system refuses; the Installer removes it at the end).
  4. Restart, and category /system/browser & to commencement the Browser.
  5. Optionally, run /Installer again alongside update.img as disk #1: Be's update of 28 November 1994 (a fixed storage_server and the Phone answering machine's spoken prompts in /system/phone, as on the "be" disk).

Each publish likes a device of its own (its footwear ROM, its disks, maybe the 133 MHz model), so the device is kept in a profile: everything in the preferences apart from Keyboard & mouse and the LED look, affirmative the boot ROM flash (with the footwear ROM updates BeOS installs) and the NVRAM (with the footwear volume). Machine > Profile lists the profiles to switch between (a operating BeBox restarts alongside the another one), and has New profile... (a copy of the current profile, under a name akin "BeOS5 133 MHz" or "DR8 66 32 MB"), Rename and Delete. The position row shows the current profile. Profiles are folders in ~/config/settings/BeBox/Profiles/; the settings from before profiles became the overview "Default".

Release Boot ROM Boots from CD Installs to disk
DR6 (BeOS 1.1d6) original 1.1d7 yes yes
DR7 (BeOS 1.1d7) original 1.1d7 yes yes
DR8 original 1.1d7 yes yes
Advanced Access PR2's yes yes
Preview Release 1 PR2's yes -
Preview Release 2 from its CD yes yes
R3 from its CD yes yes
R4.5 from its CD yes yes
R5.0.3 R3's yes yes

"-" method not tried yet. The DR8.2 depiction is a Mac updater, and the R4 image is x86 only. The footwear ROM from the R3 CD plant alongside all publish tested here, so one overview alongside it can run them all.

DR6 predates the 1.1d7 footwear ROM: BeBox hands its kernel the PCI device table in the older format it expects. Install it as the CD says: footwear the CD, run the Installer from the dock, format the SCSI disk ("Format:" in the left pop-up menu), afterward instal onto it and create it the startup disk. DR6's mouse controller moves the pointer twice as far remaining and downward as right and up (that is DR6, not the emulation). The Developer Releases' date prints the twelvemonth as years since 1900 (126 for 2026).

  • While the opening is active, the keyboard belongs to the BeBox. Click the screen to grasp the mouse; the presenter key, right Control, releases it. Keyboard & mouse in the preferences picks another presenter key and sets the mouse speed.
  • Game ports in the preferences connects presenter joysticks to the four sticks (two per equivalent port, as alongside Y cables).
  • The position row shows the floppy, CD and difficult disk (with the disk activity); click the floppy to insert one.
  • Machine has the power, reset and interrupt switches, and restarts with the footwear list or alongside kernel debug output on serial harbor 4 (that holds F1 at power on, as on a genuine BeBox). Send Ctrl+Alt+Delete gives BeOS the keys Haiku keeps for itself: BeOS R3 and afterward display their Team Monitor, and restart whenever it is sent again.
  • The two processors run on two presenter cores whenever the two are busy (Preferences > Advanced, on by default): up to nearly twice as fast, which the 133 MHz example needs on slower computers. The position row shows the speed in percent of a genuine BeBox.
  • Tools > Serial console shows a serial harbor connected to a console.
  • View shows the display at genuine or twice size or fitted to the window, and shows or hides the LEDs.

In Preferences > Network, rotate on the Ethernet cardstock (port 300h, IRQ 5 by default, as Be's application expects). In BeOS's Network preferences, add a "Novell NE2000 compatible adapter (ISA)" alongside the identical harbor and IRQ, and choose DHCP (R4.5) or set IP 10.0.2.15, disguise 255.255.255.0, gateway 10.0.2.2 and DNS 10.0.2.3 by hand. The presenter is 10.0.2.2 from the BeBox. Forwarded presenter ports (tcp:2121:21, tcp:2323:23) create services running in BeOS reachable from the host.

In Preferences > Storage, create a SCSI ID a Shared folder and choose a Haiku folder. At power on BeBox copies the folder, alongside its attributes (file types, icons), to a caller BFS quantity that BeOS mounts akin any disk; the releases alongside BFS (Advanced Access and later) can use it. When BeOS has shut downward (Be list > Shut Down) and the BeBox is powered off, BeOS's changes go rear to the folder: new and changed files, attributes, deletions. A file changed on the two sides meantime keeps the Haiku version, and BeOS's is saved next to it as "NAME (BeBox)". If BeOS did not close downward cleanly, the volume is kept and stated rear to BeOS at the next power on, so that it can repair it first. As the entire directory is copied at all power on, keep it small.

Hard disks are raw images or QCOW2 images, which lone obtain the area that is written (thin provisioning) and can be overlays of a assistance image. bebox-img manages them, and says records from BeOS volumes (BFS) and from the Hobbit prototypes' disks:

bebox-img create [-f raw|qcow2] [-b BACKING] FILE SIZE bebox-img info FILE bebox-img inspect FILE bebox-img change [-O raw|qcow2] SOURCE DESTINATION bebox-img ls IMAGE [PATH] bebox-img attr IMAGE PATH bebox-img extract IMAGE PATH OUTPUT 

For example bebox-img extract "BeOS Release 3 PowerPC.iso" /beos/etc/bebox_bootmain.image r3.rom.

On a Hobbit disk, extract additionally copies entire directories (/ for the whole disk) into a new folder, keeping the files' dates, and ls shows the files' types and creators: bebox-img extract hobbit-930800009.img / pixels. No BeOS publish says the Hobbit's document scheme (DR6 to DR8 have a later, incompatible type of it, the others BFS), so this is the way to its files: extract them, afterward provision the directory to a BFS publish as a shared folder. The Hobbit's programs do not run on the PowerPC; its sources, headers, content and pictures are what is useful.

The device opening answers hey:

hey BeBox get Running of Window BeBox # additionally set ... to true/false hey BeBox get Speed of Window BeBox # percent of genuine time hey BeBox get LedLevels of Window BeBox # left, correct (0-15) hey BeBox get SerialLog 4 of Window BeBox # a console port's output hey BeBox set Floppy of Window BeBox to /path/disk.img hey BeBox category of Window BeBox alongside text=ls # types on the keyboard hey BeBox attempt of Window BeBox alongside path=/tmp/screen.png 

Also get Mips, get EmulatedTime, get DiskLed, get AudioStats (the sound output's counters: underruns are gaps), get Profiles, get Profile and set Profile (switches, restarting a operating machine), and the commands pwon, pwof, rset and cadl (Ctrl+Alt+Delete). Replies arrive following the action.

BeBox [--profile NAME] [--rom-dir DIR] [--boot-rom IMAGE] [--model 66|133|hobbit] [--kernel FILE] [--ram MB] [--video s3|cirrus] [--scsiN-disk FILE] [--scsiN-cd FILE] [--scsiN-share FOLDER] [--ide0 FILE] [--floppy FILE] [--net] [--net-forward SPEC] [--power-on] sets up the device (the settings are kept). --profile switches to a overview first, making it as a copy of the current one if there is none; the another options alter that profile.

bebox-headless runs a device without a window, for tests and debugging: serial ports to records or TCP, scripted keys and mouse clicks, screenshots, instruction traces, recollection dumps and watches. bebox-headless --help lists the options.

On Haiku (with haiku_devel, zlib_devel and libslirp_devel): make builds the app; package/build-package.sh builds the app and the tools and creates the package.

The emulator center is portable C++17 and is tested on Linux:

  • make -C tests/linux check: processor tests (against qemu-ppc as an oracle), Hobbit processor tests, multiprocessor and equipment tests, QCOW2 tests (against qemu-img), under AddressSanitizer and UndefinedBehaviorSanitizer.
  • tests/boot-regression.sh: boots all BeOS publish headless (the media and installed disks go in work/) and the Hobbit disks (in Hobbit/), through throwaway overlays.
  • tests/vm-test.sh user@haiku-host: builds the app on a Haiku device and drives it alongside hey.

design/ describes the hardware and the emulator's design.

  • Claude Opus 5.5
  • John Rash

MIT, see LICENSE. The use icon (artwork/BeBox.hvif) is by zuMi, under the MIT License. The icons in artwork/icons arrive from Haiku's icon set (MIT, Haiku, Inc.). The BeBox ROMs and BeOS are not part of this project.

Other Article Hacker News
↑
Close Right Ads
Close Left Ads