comparison Discovery/Src/tMenuHardware.c @ 999:ac25c35a3c97 GasConsumption

New Tab for dynamic configuration: since more and more functions are added to the OSTC the space in the menus is getting short. To avoid problems a new Tab within the SYS menu has been added which shall focus an functions / views which are configuration dependend. In future this menu may have dynamic content dependend on which views are active or which sensors are connected. The Cview for compass and Timer have been moved to the new tab in the first step
author Ideenmodellierer
date Mon, 28 Apr 2025 19:47:41 +0200
parents ffb1036c27c2
children 85f7e19c6688
comparison
equal deleted inserted replaced
998:5a690195b6b7 999:ac25c35a3c97
73 } 73 }
74 nextline(text,&textPointer); 74 nextline(text,&textPointer);
75 75
76 if((line == 0) || (line == 2)) 76 if((line == 0) || (line == 2))
77 { 77 {
78 text[textPointer++] = TXT_2BYTE;
79 text[textPointer++] = TXT2BYTE_Compass;
80 text[textPointer++] = '\t';
81
82 if(settingsGetPointer()->compassBearing != 0)
83 {
84 textPointer += snprintf(&text[textPointer], 20, "(%03u`)", settingsGetPointer()->compassBearing % 360);
85 }
86 text[textPointer] = 0;
87 /*
88 textPointer += snprintf(&text[textPointer],20,"%i %i %i"
89 ,stateUsed->lifeData.compass_DX_f
90 ,stateUsed->lifeData.compass_DY_f
91 ,stateUsed->lifeData.compass_DZ_f);
92 */
93 }
94 nextline(text,&textPointer);
95
96 if((line == 0) || (line == 3))
97 {
98 text[textPointer++] = TXT_o2Sensors; 78 text[textPointer++] = TXT_o2Sensors;
99 if((stateUsed->lifeData.ppO2Sensor_bar[0] != 0) || (stateUsed->lifeData.ppO2Sensor_bar[1] != 0) || (stateUsed->lifeData.ppO2Sensor_bar[2] != 0)) 79 if((stateUsed->lifeData.ppO2Sensor_bar[0] != 0) || (stateUsed->lifeData.ppO2Sensor_bar[1] != 0) || (stateUsed->lifeData.ppO2Sensor_bar[2] != 0))
100 { 80 {
101 text[textPointer++] = '\t'; 81 text[textPointer++] = '\t';
102 sensorStatusColor[0] = '\020'; 82 sensorStatusColor[0] = '\020';
116 ,sensorStatusColor[2], stateUsed->lifeData.ppO2Sensor_bar[2]); 96 ,sensorStatusColor[2], stateUsed->lifeData.ppO2Sensor_bar[2]);
117 } 97 }
118 } 98 }
119 nextline(text,&textPointer); 99 nextline(text,&textPointer);
120 100
121 if((line == 0) || (line == 4)) 101 if((line == 0) || (line == 3))
122 { 102 {
123 text[textPointer++] = TXT_Brightness; 103 text[textPointer++] = TXT_Brightness;
124 text[textPointer++] = '\t'; 104 text[textPointer++] = '\t';
125 105
126 actualBrightness = data->brightness; 106 actualBrightness = data->brightness;
138 else 118 else
139 text[textPointer++] = '+'; 119 text[textPointer++] = '+';
140 } 120 }
141 nextline(text,&textPointer); 121 nextline(text,&textPointer);
142 122
143 if((line == 0) || (line == 5)) 123 if((line == 0) || (line == 4))
144 { 124 {
145 text[textPointer++] = TXT_2BYTE; 125 text[textPointer++] = TXT_2BYTE;
146 text[textPointer++] = TXT2BYTE_ButtonSensitivity; 126 text[textPointer++] = TXT2BYTE_ButtonSensitivity;
147 text[textPointer++] = '\t'; 127 text[textPointer++] = '\t';
148 128
158 "\017", 138 "\017",
159 button[3]); 139 button[3]);
160 } 140 }
161 nextline(text,&textPointer); 141 nextline(text,&textPointer);
162 142
163 if((line == 0) || (line == 6)) 143 if((line == 0) || (line == 5))
164 { 144 {
165 text[textPointer++] = TXT_2BYTE; 145 text[textPointer++] = TXT_2BYTE;
166 text[textPointer++] = TXT2BYTE_FLIPDISPLAY; 146 text[textPointer++] = TXT2BYTE_FLIPDISPLAY;
167 text[textPointer++] = '\t'; 147 text[textPointer++] = '\t';
168 if(settingsGetPointer()->FlipDisplay) 148 if(settingsGetPointer()->FlipDisplay)