Create: Computing AgesBrass Docs
Getting started

The computers

The six computers of the mod side by side: speed, memory, screens, storage media, networks, and which one to pick.

The mod has six computers, one or two per age from the Vacuum Tube Age on. They all run the same Brass programs with the same shell, so what you learn on the first one stays true on the last. What changes from one to the next is how fast they compute, how much they remember, what their screen looks like, what they store their files on and how they talk to other computers.

Tube Computer
Age III
Transistor Mainframe
Age IV
Minicomputer
Age V
Personal Computer
Age VI
Microcontroller
Age VI
Modern Computer
Age VII

At a glance

Speed and memory. The speed is reached at 256 RPM (see below); the stress is the default of the server configuration.

ComputerAgeInstructions per tickInstructions per second at 256 RPMMemoryStress per RPM
Tube ComputerIII204002,048 cells16 su
Transistor MainframeIV801,6008,192 cells8 su
MinicomputerV3006,00032,768 cells4 su
Personal ComputerVI1,20024,000131,072 cells2 su
MicrocontrollerVI4008,00016,384 cells1 su
Modern ComputerVII5,000100,0001,048,576 cells1 su

Screen, storage and network:

ComputerScreengfx drawingStorageNetworkLibraries it adds
Tube Computerteletype paper, 40 × 14, no colournonePunch Card Deck, 4 KBnonenone
Transistor Mainframegreen phosphor, 51 × 19306 × 171 pixelsMagnetic Tape Reel, 16 KBnonegfx
Minicomputeramber phosphor, 51 × 19306 × 171 pixelsFloppy Disk, 64 KBData Cablegfx, net
Personal Computer16 colours, 51 × 19306 × 171 pixelsFloppy Disk, 64 KBcable, radio, Wi-Figfx, net, vehicle
Microcontroller16 colours, 40 × 12240 × 108 pixelssoldered memory, 16 KBcable, radio, Wi-Figfx, net, vehicle
Modern Computer16 colours, 64 × 24384 × 216 pixelsSolid-State Drive, 1 MBcable, radio, Wi-Figfx, net, vehicle

Every computer has the basic functions (print, read, sleep...) and the libraries math, string, table, os, term, fs, rs, link, display and peripheral. On top of them, gfx draws pixels from the Transistor Mainframe on, net sends messages from the Minicomputer on, and vehicle reads the Create Aeronautics vehicle a computer rides on the Personal Computer, the Microcontroller and the Modern Computer. Type help on a computer to see exactly what it has.

Which one to choose

  • Tube Computer: your first steps and the simple jobs: blinkers, counters, sequencers, a stock alarm, a Traffic Light. It drives redstone on its six sides, Create Redstone Links, Display Links and the blocks touching it, which covers a lot. It is slow and asks a lot of stress, and its paper cannot show drawings.
  • Transistor Mainframe: four times faster, and the first with a real screen: dashboards and gauges drawn with gfx on a wall of CRT Monitors. Still no network.
  • Minicomputer: the first to join a Data Cable network. One computer can then drive dozens of machines, chests and sensors along the cable, and computers exchange messages. Hot air balloon autopilots start here.
  • Personal Computer: the all-rounder. Sixteen colours, 24,000 instructions per second, 128 K cells of memory, radio and Wi-Fi, and the vehicle library. Games, control panels, a factory dashboard.
  • Microcontroller: a small embedded computer, a thin box six pixels tall, driven from below and asking only 1 su per RPM. Its programs live in its soldered memory, so it needs no medium and keeps them when you pick it up. Made for places with no room: on an airship, under a road for a Traffic Light, inside a contraption.
  • Modern Computer: the biggest of everything: 100,000 instructions per second, a million cells, a 1 MB drive and a 64 × 24 screen. The central server of a network, heavy computations, big screens.

Rotation is the clock

A computer is a Create machine: it runs only while it turns. The shaft goes into its back (the face opposite the screen); the Microcontroller takes it from below. The rotation speed sets the speed of the processor:

  • each game tick (20 per second), the computer may run instructions per tick × RPM / 256 instructions. Above 256 RPM it gets nothing more, and the direction of rotation does not matter;
  • fractions are carried to the next tick, so even a very slow computer keeps running: a Tube Computer at 8 RPM gets 0.625 instruction per tick, which makes 5 instructions every 8 ticks;
  • waiting costs nothing: a program in sleep, read or os.pull_event uses no instructions, whatever the speed.
Computerat 32 RPMat 64 RPMat 128 RPMat 256 RPM
Tube Computer50 /s100 /s200 /s400 /s
Transistor Mainframe200 /s400 /s800 /s1,600 /s
Minicomputer750 /s1,500 /s3,000 /s6,000 /s
Personal Computer3,000 /s6,000 /s12,000 /s24,000 /s
Microcontroller1,000 /s2,000 /s4,000 /s8,000 /s
Modern Computer12,500 /s25,000 /s50,000 /s100,000 /s

An instruction is one small step of the program: x = x + 1 takes a few, a call to a library function a few more, and some functions charge extra for big jobs (drawing a large area with gfx, for example). The Performance page shows how to measure and save them.

Because of this budget, a program can never lag the server: an endless loop just spreads over time. If the server runs very many computers (512 by default, set in the server configuration), the ones beyond that number run every other tick.

Speed costs stress. A computer uses its stress per RPM (table above) times its speed: a Tube Computer at 256 RPM asks 4,096 su, a Modern Computer at the same speed 256 su. The values are set in world/serverconfig/computingages-server.toml.

Important

When the shaft stops, or the network is overstressed, the computer freezes: the program stays where it was, its memory and its outputs are kept, and it carries on when the rotation comes back. The terminal shows NO POWER: the computer needs rotation. Engineer's Goggles show the computer's number, its label, its speed right now (3000 instructions/s (24000 at 256 RPM)), its memory, or No power: turn the shaft.

Memory

The memory of a computer is counted in cells. A number in a variable, a table entry or a few characters of text each take a cell or two: a table of 1,000 numbers takes about 2,000 cells. The program, its variables, its tables, its strings and the events waiting for it all count. When a program asks for more than the computer has, it stops with the error out of memory (which pcall can catch).

mem in the shell and os.memory() in a program tell how much is used. When a program ends, its local variables are freed, but the global variables it made stay in memory until the next reboot. That is one more reason to write local.

Screens

  • The Tube Computer prints on the paper of a teletype: dark ink, 40 columns, no colour and no drawing. Clicks on the paper are not sent to programs (a click on a monitor still is).
  • The Transistor Mainframe and the Minicomputer have a phosphor screen, green or amber. Programs can set colours, but everything lights in the one phosphor colour; gfx drawings work, every colour other than black lighting up.
  • The Personal Computer, the Microcontroller and the Modern Computer show the 16 colours.

Text is placed on a grid of characters (51 × 19 on most computers). Under the text lies a layer of pixels, 6 × 9 per character, that gfx draws on. See Screens for both, and term and gfx for the functions.

Storage media

Each computer except the Microcontroller has a drive that holds one storage medium. The medium keeps the files: your programs and the data they save with fs.

MediumCapacityRead by
Punch Card Deck4 KBTube Computer, Transistor Mainframe, Minicomputer, Personal Computer, Modern Computer
Magnetic Tape Reel16 KBTransistor Mainframe, Minicomputer, Personal Computer, Modern Computer
Floppy Disk64 KBMinicomputer, Personal Computer, Modern Computer
Solid-State Drive1 MBModern Computer

Each drive reads its own medium and every older one, so your programs follow you from age to age: a Punch Card Deck written on a Tube Computer works in a Modern Computer. The tooltip of a medium lists the computers that read it.

  • Insert: right-click the computer with the medium in hand. Nothing happens if the drive is full or the medium is too new for this computer.
  • Eject: sneak and right-click the computer with an empty hand. Breaking the computer drops the medium too.
  • A running program sees a disk event when a medium goes in or out (inserted is true or false), see Events.
  • Without a medium, the shell answers No storage medium: right-click the computer with one to the commands that need files.

The files are kept on the server, in <world>/computingages/media/; the item itself only carries a number (shown in the advanced tooltip, F3+H). So the files stay with the item wherever it goes: in a chest, to another computer, to another player.

Note

A medium copied in creative mode (middle-click) carries the same number as the original: both share the same files.

A medium holds at most 1,024 files and folders. File and folder names use letters (no accents), digits, _, . and -, up to 32 characters; a whole path is 128 characters at most. Folders take no room. The limits are listed in Limits.

The Microcontroller has no drive: its 16 KB memory is soldered in. It works like a medium that never leaves the block: when you break the Microcontroller or pick it up with a wrench, the item keeps its memory, and the programs are there again where you place it.

Networks

Data CableRadio Modem (128 blocks)Wi-Fi Router (256 blocks, worldwide backbone)
Tube Computer, Transistor Mainframenonono
Minicomputeryesnono
Personal Computer, Microcontroller, Modern Computeryesyesyes

A Data Cable links computers and the machines along it, which become peripherals named like inventory@120,64,-35. A Radio Modem placed against the computer (or on its cable) reaches the computers within 128 blocks, and Wi-Fi Routers (made in the Digital Age) sharing the same network name carry messages across the world. The Networking page explains all of it.

Power, reboot and the terminal buttons

Right-click a computer to open its terminal. Next to the screen are three buttons:

ButtonKeyWhat it does
Switch off / Switch onOff: the program stops, the screen goes blank, every output is released (redstone, Redstone Links, Display Link lines), and the computer stays off even while it turns. On: it boots, then runs startup.
RebootCtrl+RRestarts: the memory is wiped, the outputs are released, the banner comes back and startup runs.
StopCtrl+TStops the running program, clears the screen and comes back to the prompt. Outputs keep their last value.

The shell commands reboot and shutdown, and the functions os.reboot and os.shutdown, do the same as the Reboot and Switch off buttons. A computer boots at most twice a second, so a program that reboots in a loop cannot flood the server.

A computer also boots on its own when it starts turning, and when its chunk is loaded again (after a server restart, for example): when the chunk unloads, the computer stops and its program and memory are lost. Put your program in a startup file and it comes back every time.

The terminal works for any player within 16 blocks of the computer, and several players can watch the same terminal. The help text and the examples follow the language of the last player who opened it.

Number and label

Each computer gets a number the first time it runs, unique in the world: id in the shell, os.id() in a program, Computer #7 in the goggles. You can also give it a label, a name of up to 32 characters: label Iron furnace in the shell, or os.label("Iron furnace") in a program. The label shows in the goggles, in id, and to the other computers of the network (net.computers()).

When you break a computer or pick it up with a wrench, the item keeps its number and its label: placed again, it is the same computer.

Monitors

A CRT Monitor (age IV) or an LCD Monitor (age VII) placed against a computer shows its terminal in the world, big enough to read from afar.

  • Monitors of the same kind placed side by side, facing the same way, in a flat rectangle, merge into one screen of up to 8 × 6 blocks.
  • The CRT Monitor glows like a phosphor screen (green for a Tube Computer or a Transistor Mainframe, amber for a Minicomputer, in colour for the newer ones); the LCD Monitor is a thin colour screen.
  • Right-click any monitor of the screen to open the computer's terminal. When the running program waits for clicks (it called os.pull_event() or os.pull_event("click")), a right-click presses the screen instead (a light pen on the CRT, a touch on the LCD); sneak to open the terminal anyway.
  • A monitor shows nothing while its computer has no rotation.

The monitor page shows how a program reads the size of its screen.

A Create Display Link whose source is a computer shows the lines the program wrote with display.set() on a Display Board, Nixie Tubes, a sign or anything else a Display Link can fill. It refreshes twice a second. The lines are cleared when the computer reboots or is switched off. See display.

The wrench

With Create's Wrench:

  • right-click turns a computer a quarter turn. Its back turns with it, so move the shaft, and remember that "left" and "right" follow the screen;
  • sneak and right-click picks it up, keeping its number, its label and (for the Microcontroller) its memory. The medium inside drops.

The same goes for the other blocks of the mod: monitors, cables, Radio Modems and Wi-Fi Routers.

See also