Skip to content

Transmitter

Sends data to other planets. Use it to report sensor readings to Earth or submit contract answers. Call connect() to choose a planet, then transmit(key, value) to send data; disconnect() clears the connection. A connection lasts only for the current script run, so each transmitting script must connect first. Save get_component("transmitter") to a variable and reuse it for both calls.

Access: get_component("transmitter") · Like every component, exposes .id and .name.

Every available transmission destination as a list of Planet objects (each with .id, .name, etc.). Call once at script start to see what is available; pass a returned .id to connect(id).

Returns: List of Planet objects

Open a channel to the planet with the given id: result = transmitter.connect("earth"). The id must be lowercase (from list_planets()). Read transmitter.get_info().target after success. Connection lasts only for the current script run; if your script restarts, connect() again before transmit().

Returns: ActionResult · Outcomes: "ok" / "not_found"

Close the current script-run channel. This does not affect contracts or any other script; it only clears this Transmitter object’s active target so later transmit() calls must connect() again.

Returns: ActionResult · Outcomes: "ok"

Current connection status. Returns an object with .connected (boolean) and .target (connected planet id, or "none"). Use as a guard before transmit().

Returns: TransmitterInfo { connected, target }

Send a named value to the connected planet with transmitter.transmit(key, value). Opening sensor telemetry is unavailable until the power and sensor onboarding steps are complete and the uplink step is active. For sensor readings, use the name requested by Earth, such as "current_temperature". For contract answers, use self.contract.id. The data arrives in the same tick.

Returns: ActionResult

StatusKindMeaning
"correct"successThe submitted value is correct
"incorrect"rejectionThe submitted value is incorrect
"already_completed_correct"successThe contract is already completed; the value submitted now is correct
"already_completed_incorrect"rejectionThe contract is already completed; the value submitted now is incorrect
"accepted"successThe submitted value was accepted
"rejected"rejectionThe submitted value or request was rejected
"not_connected"rejectionThe component has no active connection
"wrong_planet"rejectionThe operation targets a different planet
"wrong_contract"rejectionThe supplied contract is not active for this operation
"locked"rejectionThe required feature, recipe, or operation is locked
"unknown_contract"rejectionThe supplied contract identifier does not exist
"key_is_planet"rejectionThe supplied key names a planet rather than a telemetry or contract key
"unknown_key"rejectionThe supplied telemetry or contract key does not exist
  • Contracts: the transmit workflow in context