From 26770a42a4b12dd24d0e40adbb361ba4d972537e Mon Sep 17 00:00:00 2001 From: "Robert C. Helling" Date: Thu, 27 Aug 2015 14:13:12 +0200 Subject: [PATCH] Compute first stop pressure for each round of CVA Signed-off-by: Robert C. Helling --- planner.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/planner.c b/planner.c index 5afc117..1dda2f4 100644 --- a/planner.c +++ b/planner.c @@ -1143,6 +1143,12 @@ bool plan(struct diveplan *diveplan, char **cached_datap, bool is_planner, bool breaktime = -1; breakcylinder = 0; o2time = 0; + first_stop_pressure.mbar = depth_to_mbar(deco_allowed_depth(tissue_tolerance, + diveplan->surface_pressure / 1000.0, + &displayed_dive, + 1), + &displayed_dive); + last_ascend_rate = ascent_velocity(depth, avg_depth, bottom_time); if ((current_cylinder = get_gasidx(&displayed_dive, &gas)) == -1) { report_error(translate("gettextFromC", "Can't find gas %s"), gasname(&gas)); -- 1.9.5 (Apple Git-50.3)