From a14f4a158adee298879a789331cf327b47578d01 Mon Sep 17 00:00:00 2001 From: Matthew Kennedy Date: Wed, 25 Sep 2024 20:04:43 -0700 Subject: [PATCH] fix simulator --- firmware/controllers/bench_test.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/firmware/controllers/bench_test.cpp b/firmware/controllers/bench_test.cpp index 53f4f62d12..da2bdae715 100644 --- a/firmware/controllers/bench_test.cpp +++ b/firmware/controllers/bench_test.cpp @@ -80,8 +80,8 @@ struct BenchParams { }; static void runBench(BenchParams& params) { - int onTimeUs = MS2US(std::max(0.1, params.OnTimeMs)); - int offTimeUs = MS2US(std::max(0.1, params.OffTimeMs)); + int onTimeUs = MS2US(std::max(0.1f, params.OnTimeMs)); + int offTimeUs = MS2US(std::max(0.1f, params.OffTimeMs)); if (onTimeUs > TOO_FAR_INTO_FUTURE_US) { firmwareError(ObdCode::CUSTOM_ERR_BENCH_PARAM, "onTime above limit %dus", TOO_FAR_INTO_FUTURE_US);