Skip to content

BTM Custom Generation / Battery configs critical load error #2048

@cpaulgilman

Description

@cpaulgilman

Describe the bug

BTM Custom Generation / Battery configurations generate an SSC error for subhourly simulations, even when

  • Grid outages are not enabled, or
  • Outages are enabled and critical load data has correct time step.
exec fail(battery): Critical load crit_load must have same number of values as load.
Simulation battery failed :exec fail(battery): Critical load crit_load must have same number of values as load.
batt_annual_discharge_energy not assigned
Simulation cashloan failed :batt_annual_discharge_energy not assigned

Sample file for testing: critical-load-subhourly-test.zip

To Reproduce

Steps to reproduce the behavior:

  1. Open sample file from above.
  2. Run a simulation for each case.
  3. See error.

Expected behavior

Errors should only be generated under the following conditions:

  • Generation profile and load data have different time steps.
  • Grid outage is enabled and critical load and load have different time steps.

Operating System and Version

  • Windows 11
  • SAM 2024.12.12

Workaround

Error is caused by a missing check for "Custom Generation Battery" configuration in Electric Load Data UI callback and equations. A workaround solution is to run the following LK script to replace runtime/ui/Electric Load Data.json with a corrected version:

  1. Download and extract sam-2048-crit-load-fix.zip.
  2. Start SAM and, in the Welcome window, click Open script.
  3. Open the sam-2048-crit-load-fix.lk file.
  4. Click Run at the top of the script editor.
  5. At the "Choose Electric Load Data.json file" prompt, navigate to the .json file that you extracted in Step 1.
  6. When the script finishes, close SAM.
  7. Start SAM and test.

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions