- Primary keyword: code terraform first level send temperature to earth requires one connected script run.
- Read live data: Use the thermometer component instead of entering a remembered temperature.
- Connect first: Call
connect("earth")before transmitting the temperature value. - Use the correct key: Send
"current_temperature"as a quoted string. - Check power: A weak grid can make a correct script appear to fail.
code terraform first level send temperature to earth
The opening objective in Code: Terraform is a short programming test with three linked requirements: read the current thermometer value, connect the transmitter to earth, and transmit that live value under the "current_temperature" key. The keyword phrase code terraform first level send temperature to earth describes this exact progression.
The important detail is timing. The connection must be established during the same script run as the transmission. A previous connection does not remain armed for a later execution, so splitting the work across separate runs can leave the objective unchanged.
Treat the first transmission as one chain: read the sensor, connect the transmitter, then send the value without replacing the reading with a fixed number.
Read
Retrieve the current value from the thermometer with get_value(). This prevents the script from relying on an outdated screenshot or guessed temperature.
Connect
Link the transmitter to earth before attempting the transmission. The destination must be available in the same run.
Transmit
Send the live reading with the exact string key "current_temperature". The key should not be written as an unquoted variable.
| Requirement | Correct approach | Common mistake |
|---|---|---|
| Temperature source | thermo.get_value() | Hardcoding a number |
| Destination | transmitter.connect("earth") | Connecting during an earlier run |
| Data key | "current_temperature" | Writing current_temperature without quotes |
| Success check | Objective message and credit change | Expecting a special return value |
The recorded starter path also makes this objective a progression gate. Completing it opens the shop and biology lab in the tested starter build, but the objective itself is confirmed by the game’s message and credit change rather than a special return from transmit().
For the component names and method behavior, consult the Code: Terraform Beginner Guide, especially if your Early Access build presents a slightly different documentation label.
Step-by-Step Temperature Uplink
Use the following order when working through the first terminal objective. The sequence is intentionally compact because the game checks the relationship between the live reading, the destination, and the transmitted key.
Running connect("earth") in one script and transmit() in another can fail even when both lines are individually correct. Keep them together.
Open the Main Console
Boot the terminal and enter the main console used for component scripting. Before editing the algorithm, confirm that you are working on the machine assigned to the opening objective.
Read the Thermometer
Create the thermometer component and call get_value(). Store the returned value in a variable such as value, so the exact live reading can be passed to the transmitter.
Connect to Earth
Create the transmitter component and call transmitter.connect("earth"). The destination is a quoted string, and this line must execute before the transmission line.
Send the Temperature
Call transmitter.transmit("current_temperature", value). The first argument is the string key, while the second argument is the live thermometer value.
Verify Progress
Look for the objective message and credit change. If neither appears, check the machine, power supply, component names, and whether the connection occurred during this run.
A compact starter script is:
thermo = get_component("thermometer")
value = thermo.get_value()
transmitter = get_component("transmitter")
transmitter.connect("earth")
transmitter.transmit("current_temperature", value)
| Script line | Function | Validation |
|---|---|---|
get_component("thermometer") | Finds the temperature sensor | Name must match the in-game docs |
thermo.get_value() | Reads current temperature | Use the returned value |
get_component("transmitter") | Finds the uplink hardware | Check the edited machine |
connect("earth") | Sets the destination | Run before transmit() |
transmit("current_temperature", value) | Sends the reading | Quote the key and pass the live value |
The useful confirmation is the objective message together with the credit change. Do not wait for transmit() to return a special success object.
Power, Hardware, and First Base Setup
A correct script still depends on the machine being powered. After the first contact objective, the opening shop provides the hardware needed to stabilize the early grid. The most useful initial pairing is a solar generator with a small battery.
If the script looks correct but the objective does not move, inspect generation, storage, and the machine being edited before rewriting the logic.
The early base benefits from a simple order:
- Establish generation before adding several new machines.
- Add storage so short production gaps do not interrupt sensors.
- Keep the transmitter and terminal on a powered machine.
- Test the objective before expanding into biology or contracts.
- Treat stalled hardware as a possible power problem, not automatic proof of a code error.
| Hardware | Early purpose | Why it matters |
|---|---|---|
| Solar generator | Produces opening power | Keeps the first grid active |
| Small battery | Stores generated power | Reduces interruptions during low generation |
| Thermometer | Supplies live temperature data | Provides the value sent to earth |
| Transmitter | Sends environmental data | Completes the first contact objective |
| Terminal | Runs the script | Connects the code to the machine network |
The solar system also introduces a recurring automation pattern. The opening rule is sun elevation plus panel tilt equals 90 degrees. If the sun elevation is 60, the target tilt is 30. Because the sun moves, a one-time adjustment eventually becomes outdated.
clock = get_component("clock")
while True:
sun = clock.get_elevation()
self.set_tilt_degrees(90 - sun)
This loop is separate from the first temperature transmission, but it supports the same principle: read a live value, calculate from the current state, and keep the hardware aligned with changing conditions.
Generation
Add a solar generator early enough to keep the terminal, thermometer, and transmitter operational.
Storage
Use a small battery to reduce false failures caused by an empty or unstable grid.
Automation
Recalculate solar tilt while the sun changes instead of relying on a single setup value.
Do not wait for a perfect sensor network. Put generation and storage online, complete the temperature uplink, then expand the base.
Troubleshooting Errors and Related Scripts
Most first-level failures come from a small set of syntax, naming, connection, or power issues. Correct the earliest matching problem rather than changing several lines at once.
Start with the error message, then inspect indentation, component names, connection timing, and power. Changing the algorithm first can hide the original problem.
| Message or symptom | Likely cause | First correction |
|---|---|---|
expected string for key | The transmission key is not quoted | Use "current_temperature" |
expected indent at start of block | A block body is not indented | Indent the if, else, or while body |
| Component not found | The name differs from the documentation | Copy the component name from the docs panel |
| Objective does not move | Missing same-run connection or no power | Connect to earth in the run and inspect the battery |
cannot access recipe on none | Biology has no analyzed specimen | Delay contracts and biology until self.input is ready |
The first-level objective is also a useful lesson in variable handling. The thermometer value should remain dynamic. Replacing value with a number copied from another player’s run makes the script dependent on a reading that may no longer match your build.
The same live-data approach appears in the opening oxygen repair. The starter pattern reads the sensor, applies the recorded conversion, and sends the corrected value to the calibration method:
sensor = get_component("oxygen sensor")
oxygen = sensor.get_value()
corrected = oxygen * 100
sensor.calibrate(corrected)
For the parity-based stabilization task, remember that % returns the remainder after division. Use == for comparison, not = for assignment:
p = p_sensor.get_value()
if p % 2 == 0:
fixed = p
else:
fixed = p + 1
p_sensor.stabilize(fixed)
| Debug category | What to inspect | Reliable habit |
|---|---|---|
| Syntax | Quotes, indentation, comparison operators | Fix the smallest visible error |
| Components | Exact names and available methods | Use the in-game documentation |
| Runtime state | Power and machine assignment | Inspect the grid before rewriting code |
| Objective state | Connection and destination | Keep connect() and transmit() together |
| Progression order | Biology and contract prerequisites | Finish the opening chain first |
Starter footage and Early Access documentation may use slightly different component labels or methods. When the objective text conflicts with an older example, follow the documentation in your current build.
First-Level Completion Checklist and FAQ
Use this checklist before moving into broader systems. It focuses on the conditions that determine whether the temperature uplink is recognized.
Temperature Uplink Checklist:
- Boot the terminal and open the main console
- Read the live thermometer value with get_value()
- Connect the transmitter to earth during the same script run
- Transmit the quoted current_temperature key with the live value
- Confirm the objective message and credit change
Once the objective confirms and the early grid is powered, continue with generation, storage, oxygen calibration, and solar automation rather than repeating the temperature script.
Q: What is the correct code terraform first level send temperature to earth order?
Read the thermometer first, connect the transmitter to 'earth' second, and transmit 'current_temperature' with the live value third. Keep all three actions in the same script run.
Q: Why does transmit() fail when the key looks correct?
The first transmit() argument must be a quoted string. Use 'current_temperature' instead of writing current_temperature without quotation marks.
Q: Why does the objective stay unchanged after running a correct-looking script?
Check whether connect('earth') ran in the same execution, whether the edited machine is the correct one, and whether the grid has enough power.
Q: Should I hardcode the temperature from another guide?
No. The objective expects the current reading, and the value can change. Store the result of thermo.get_value() and transmit that variable.
The opening objective rewards careful sequencing more than complicated code. A short script with live data, an active connection, an exact string key, and sufficient power is the intended path through the first contact milestone.