NatLabRockies / NatLabRockies/fastsim

`StartStopControl::handle_fc_on_causes_for_temp` bug

Open
#312 0 comments 0 reactions 1 assignee View on GitHub

@kylecarow is already working on this.

Since Jul 30, 2026.

bug
Dominant language
Rust
Stars
60
Forks
19
Avg merge
10d 2h
Merged PRs (30d)
2

Description

https://github.com/NatLabRockies/fastsim/pull/271#discussion_r3679328429

StartStopControl::handle_fc_on_causes_for_temp is intended to use a previous temperature (temp_prev) for hysteresis, but both tuple entries are populated from the same fc_temperature value. This makes the (temp_prev < temp_fc_forced_on && temperature < temp_fc_allowed_off) branch ineffective and effectively ignores the temp_fc_allowed_off threshold.

To implement the intended hysteresis, you likely need to track a previous fuel-converter temperature (e.g., add a temp_prev/temperature_prev field to FuelConverterThermalState and update it each step) and use that here; otherwise consider simplifying the logic and error message so it doesn’t imply a non-existent fc.temp_prev() API.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.