Mercurial > public > ostc4
changeset 680:5575f21382d5 Betatest
Bugfix visualization better setpoint:
Due to a formating mistake a complete float was show in case a better setpoint had been suggested. The string formating has been updated to show a 4 characters string
author | Ideenmodellierer |
---|---|
date | Mon, 25 Apr 2022 21:07:28 +0200 |
parents | 52df13712fa3 |
children | 7fa5ef6ae419 |
files | Discovery/Src/t7.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/Discovery/Src/t7.c Fri Apr 22 18:24:43 2022 +0200 +++ b/Discovery/Src/t7.c Mon Apr 25 21:07:28 2022 +0200 @@ -2472,7 +2472,7 @@ TextR1[textPointer++] = '\a'; TextR1[textPointer++] = '\001'; TextR1[textPointer++] = ' '; - textPointer += snprintf(&TextR1[textPointer],TEXTSIZE,"%f01.2",((float)(stateUsed->diveSettings.setpoint[actualBetterSetpointId()].setpoint_cbar))/100); + textPointer += snprintf(&TextR1[textPointer],TEXTSIZE,"%01.2f",(float)(stateUsed->diveSettings.setpoint[actualBetterSetpointId()].setpoint_cbar) / 100.0); TextR1[textPointer++] = '?'; TextR1[textPointer++] = ' '; TextR1[textPointer++] = 0;