stationeers.de Mod workshop · Dominik1199
DE Sign in
  1. Home
  2. Stationeers wiki
  3. Devices
  4. Lever

Devices

Lever

Hebel

PrefabStructureLogicSwitch Hash1220484876in the hash lookup
Power paintable Game 0.2.6428.27798

Overview

Lever (StructureLogicSwitch) in Stationeers: device, hash 1220484876. With build steps, 6 IC10 logic values and connection diagram.

The lever is the simplest way to tell a program or a logic chain something by hand. It has exactly two positions, and they are stored in Open: 1 or 0. Open is readable and writable – so a chip can flip the lever itself, and the lever visibly moves along.

Setting is read only and follows the position: every time the lever is flipped, it copies the new value of Open into Setting. That matters for logic chains, because a Logic Writer always takes the Setting of its source. Lock only locks manual operation – a chip can still flip a locked lever through Open.

It needs no power and has two data ports. It is built from the Kit (Logic Switch). The same kit also builds the switch (Switch), the Button, the Dial and the Important Button.

Most often the lever serves as a master switch for a program. The chip reads it by name, for example with lbn enabled LEVER NLEVER Open 0, and only acts when Open reports 1.

Think about the case where the lever is missing or wrongly named: lbn then returns NaN. Decide beforehand what is safe – for a vent rather “off”, for emergency lighting rather “on”. A complete example with a lever is in Logic without a chip: reader, writer, memory, compare, math.

IC10 and logic

6 logic values, 6 readable and 2 writable.

  • Open RW 2
  • Lock RW 10
  • Setting R 12
  • PrefabHash R 84
  • ReferenceId R 217
  • NameHash R 268

Example: address by name

Reads Setting, shows the value on the IC housing and writes Open. Name the device with the labeller first; devices with the same name are addressed together.

# Lever address by name
define DEVICE 1220484876  # StructureLogicSwitch
define NAME HASH("Lever")  # name in game (labeller)
define TARGET 1  # Open 1 = open
alias value r0

start:
yield
lbn value DEVICE NAME Setting 0  # 0 = average of all with this name
bnan value start  # no device with this name
s db Setting value  # show on the housing
sbn DEVICE NAME Open TARGET  # set value
j start

Connections

12
Schematic: inputs left, outputs right, waste on top, power and data at the bottom. Position and spacing do not match the model.
  1. 1Data
  2. 2Data

Building and deconstruction

Grid: small grid (0.5 m) · mounting: on wall or floor

  1. 1

    Place

    Take back with Hand Drill

Total material

Deconstruction returns

Built with: Kit (Logic Switch)

Material, fire and recycling

Flammable according to game data: flash point 373.2 K (100 °C); Autoignition 573.2 K (300 °C); burn time 5 s

Raw values from the game code (3)

Field names as in the game code, untranslated. Useful for mods and exact limits.

LogicUnitBase.ConnectionTypeFlatExhaustive
LogicUnitBase.Input1Index0
LogicUnitBase.OutputIndex1

See also

Esc
↑ ↓ selectEnter open/ opens search anywhere