Mercurial > public > hwos_code
comparison src/option_table.asm @ 560:b7eb98dbd800
bump to 2.96beta (REFACTORED VERSION)
author | heinrichsweikamp |
---|---|
date | Wed, 31 Jan 2018 19:39:37 +0100 |
parents | dfac393b2199 |
children | 8b7ea27ea1fa |
comparison
equal
deleted
inserted
replaced
559:9cb967d844f0 | 560:b7eb98dbd800 |
---|---|
1 ;============================================================================= | 1 ;============================================================================= |
2 ; | 2 ; |
3 ; File option_table.asm | 3 ; File option_table.asm REFACTORED VERSION V2.95 |
4 ; | 4 ; |
5 ; The option table | 5 ; The option table |
6 ; | 6 ; |
7 ; Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved. | 7 ; Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved. |
8 ;============================================================================= | 8 ;============================================================================= |
43 db max, eeprom | 43 db max, eeprom |
44 dw unit | 44 dw unit |
45 dw register | 45 dw register |
46 ENDM | 46 ENDM |
47 | 47 |
48 ; NEW ## deco engine | |
49 OPTION_UINT8p5 MACRO lbl, min, max, default, unit, eeprom, register | |
50 global lbl | |
51 lbl: db 0, default ; Type0 = INT8 | |
52 db .5, min | |
53 db max, eeprom | |
54 dw unit | |
55 dw register | |
56 ENDM | |
57 | |
48 OPTION_UINT8p10 MACRO lbl, min, max, default, unit, eeprom, register | 58 OPTION_UINT8p10 MACRO lbl, min, max, default, unit, eeprom, register |
49 global lbl | 59 global lbl |
50 lbl: db 0, default ; Type0 = INT8 | 60 lbl: db 0, default ; Type0 = INT8 |
51 db .10, min | 61 db .10, min |
52 db max, eeprom | 62 db max, eeprom |
83 extern tPercent, tMeters, tMinutes, tGasDisabled, tbar | 93 extern tPercent, tMeters, tMinutes, tGasDisabled, tbar |
84 extern char_I_deco_gas_change, char_I_setpoint_change, char_I_setpoint_cbar, char_I_dil_change | 94 extern char_I_deco_gas_change, char_I_setpoint_change, char_I_setpoint_cbar, char_I_dil_change |
85 extern char_I_dive_interval, char_I_bottom_time, char_I_bottom_depth | 95 extern char_I_dive_interval, char_I_bottom_time, char_I_bottom_depth |
86 extern char_I_deco_model, char_I_saturation_multiplier, char_I_desaturation_multiplier | 96 extern char_I_deco_model, char_I_saturation_multiplier, char_I_desaturation_multiplier |
87 extern char_I_extra_time | 97 extern char_I_extra_time |
88 extern tDefName | 98 extern tDefName, tblank |
89 extern char_I_bottom_usage,char_I_deco_usage,tLitersMinute | 99 extern char_I_bottom_usage, char_I_deco_usage, tLitersMinute |
100 | |
101 ; NEW ## deco engine | |
102 extern char_I_PSCR_drop, char_I_PSCR_lungratio | |
103 | |
104 ; NEW ## bailout gas needs | |
105 extern char_I_tank_size, char_I_tank_pres_fill, tLiter, tbar10 | |
106 | |
107 ; NEW ## CCR max ppO2 limiter | |
108 extern char_I_cc_max_frac_o2 | |
109 | |
110 ; NEW ## no fly altitude | |
111 extern char_I_altitude_wait | |
112 | |
113 ; NEW ## V2.94 | |
114 extern char_I_ppO2_max, char_I_ppO2_min, char_I_ppO2_max_deco, char_I_ppO2_min_loop | |
115 | |
116 ; NEW ## V2.94 / V2.95 | |
117 extern char_I_ascent_speed, tMeterMinute | |
118 | |
119 ; NEW ## V2.95 | |
120 extern char_I_gas_change_time, tmin | |
121 | |
90 ; Option table | 122 ; Option table |
91 ; OPTION_UINT8 Label, min, max, default, text-string, EEPROM location (-1 for RAM only), RAM location | 123 ; OPTION_UINT8 Label, min, max, default, text-string, EEPROM location (-1 for RAM only), RAM location |
92 global option_table_begin | 124 global option_table_begin |
93 option_table_begin: | 125 option_table_begin: |
94 ;============================================================================= | 126 ;============================================================================= |
96 OPTION_UINT8p10 odiveInterval, .0, .240, .0, tMinutes, -1, char_I_dive_interval | 128 OPTION_UINT8p10 odiveInterval, .0, .240, .0, tMinutes, -1, char_I_dive_interval |
97 OPTION_UINT8p2 obottomTime, .1, .60, .5, tMinutes, -1, char_I_bottom_time | 129 OPTION_UINT8p2 obottomTime, .1, .60, .5, tMinutes, -1, char_I_bottom_time |
98 OPTION_UINT8p3 obottomDepth, .12,.120, .21, tMeters, -1, char_I_bottom_depth | 130 OPTION_UINT8p3 obottomDepth, .12,.120, .21, tMeters, -1, char_I_bottom_depth |
99 OPTION_ENUM8 oDiveMode, 5, 0, tDvOC, .8, opt_dive_mode ; 0=OC, 1=CC, 2=Gauge, 3=Apnea, 4=PSCR | 131 OPTION_ENUM8 oDiveMode, 5, 0, tDvOC, .8, opt_dive_mode ; 0=OC, 1=CC, 2=Gauge, 3=Apnea, 4=PSCR |
100 OPTION_ENUM8 oDecoMode, 2, 1, tZHL16, .9, char_I_deco_model ; 0 = ZH-L16, 1 = ZH-L16-GF | 132 OPTION_ENUM8 oDecoMode, 2, 1, tZHL16, .9, char_I_deco_model ; 0 = ZH-L16, 1 = ZH-L16-GF |
101 OPTION_UINT8p10 oPPO2Max, .120, ppo2_warning_high, .160, 0, .10, opt_ppO2_max | 133 OPTION_UINT8p10 oPPO2Max, .120, ppo2_warning_high, .160, 0, .10, char_I_ppO2_max |
102 OPTION_UINT8 oLastDeco, .3, .6, .3, tMeters, .11, opt_last_stop | 134 OPTION_UINT8 oLastDeco, .3, .6, .3, tMeters, .11, opt_last_stop |
103 OPTION_UINT8 oGF_low, .10, .100, .30, tPercent, .12, opt_GF_low | 135 OPTION_UINT8 oGF_low, .10, .100, .30, tPercent, .12, opt_GF_low |
104 OPTION_UINT8 oGF_high, .45, .110, .85, tPercent, .13, opt_GF_high | 136 OPTION_UINT8 oGF_high, .45, .110, .85, tPercent, .13, opt_GF_high |
105 OPTION_UINT8p10 osatmult, .100, .140, .110,tPercent, .14, char_I_saturation_multiplier | 137 OPTION_UINT8p5 osatmult, .100, .140, .110,tPercent, .14, char_I_saturation_multiplier |
106 OPTION_UINT8p10 odesatmult, .60, .100, .90,tPercent, .15, char_I_desaturation_multiplier | 138 OPTION_UINT8p5 odesatmult, .60, .100, .90,tPercent, .15, char_I_desaturation_multiplier |
107 OPTION_UINT8p10 oPPO2Min, .16, ppo2_warning_low, .19, 0, .16, opt_ppO2_min | 139 OPTION_UINT8p10 oPPO2Min, .16, ppo2_warning_low, .19, 0, .16, char_I_ppO2_min |
108 OPTION_UINT8 oaGF_low, .10, .100, .30, tPercent, .17, opt_aGF_low | 140 OPTION_UINT8 oaGF_low, .10, .100, .30, tPercent, .17, opt_aGF_low |
109 OPTION_UINT8 oaGF_high, .45, .110, .85, tPercent, .18, opt_aGF_high | 141 OPTION_UINT8 oaGF_high, .45, .110, .85, tPercent, .18, opt_aGF_high |
110 OPTION_BOOL oEnable_aGF, 0, .19, opt_enable_aGF ; =1: aGF can be selected underwater | 142 OPTION_BOOL oEnable_aGF, 0, .19, opt_enable_aGF ; =1: aGF can be selected underwater |
111 OPTION_UINT8 oCompassGain, 0, 7, 6, tMinutes, .20, opt_compass_gain ; 0-7 (230LSB/Gauss to 1370LSB/Gauss) | 143 OPTION_UINT8 oCompassGain, 0, 7, 6, tMinutes, .20, opt_compass_gain ; 0-7 (230LSB/Gauss to 1370LSB/Gauss) |
112 OPTION_ENUM8 oSamplingRate, 2, 0, tSampling2s, .21, opt_sampling_rate ; =1: 10s, =0: 2s | 144 OPTION_ENUM8 oSamplingRate, 2, 0, tSetSeconds, .21, opt_sampling_rate ; =1: 10s, =0: 2s |
113 | 145 |
114 ;============================================================================= | 146 ;============================================================================= |
115 ; Managing Settings | 147 ; Managing Settings |
116 OPTION_UINT8 oExtraTime, 0, .9, 0,tMinutes, .22, char_I_extra_time ; Future TTS | 148 OPTION_UINT8 oExtraTime, 0, .9, 0,tMinutes, .22, char_I_extra_time ; Future TTS |
117 OPTION_ENUM8 oBrightness, 3, 0, tEco, .23, opt_brightness ; =0: Eco, =1:Medium, =2:Full | 149 OPTION_ENUM8 oBrightness, 3, 0, tEco, .23, opt_brightness ; =0: Eco, =1:Medium, =2:Full |
118 OPTION_UINT8 oDiveSalinity, 0, 4, 0, tPercent, .24, opt_salinity ; 0-4% | 150 OPTION_UINT8 oDiveSalinity, 0, 4, 0, tPercent, .24, opt_salinity ; 0-4% |
119 OPTION_ENUM8 oCCRMode, 3, 0, tCCRModeFixedSP, .25, opt_ccr_mode ; =0: Fixed SP, =1: Sensor, =2: Auto SP | 151 OPTION_ENUM8 oCCRMode, 3, 0, tCCRModeFixedSP, .25, opt_ccr_mode ; =0: Fixed SP, =1: Sensor, =2: Auto SP |
120 IFNDEF french_italian | 152 |
121 OPTION_ENUM8 oLanguage, 2, 0, tEnglish, .26, opt_language ; 0=EN, 1=DE | 153 IFNDEF french_italian |
122 ELSE | 154 OPTION_ENUM8 oLanguage, 2, 0, tEnglish, .26, opt_language ; 0=EN, 1=DE |
123 OPTION_ENUM8 oLanguage, 2, 0, tFrench, .26, opt_language ; 0=FR, 1=IT | 155 ELSE |
124 ENDIF | 156 OPTION_ENUM8 oLanguage, 2, 0, tFrench, .26, opt_language ; 0=FR, 1=IT |
125 OPTION_ENUM8 oDateFormat, 3, 1, tDateformat,.27, opt_dateformat ; =0:MMDDYY, =1:DDMMYY, =2:YYMMDD | 157 ENDIF |
158 OPTION_ENUM8 oDateFormat, 3, 1, tDateformat,.27, opt_dateformat ; =0:MMDDYY, =1:DDMMYY, =2:YYMMDD | |
126 OPTION_ENUM8 oUnits, 2, 0, tMetric, .28, opt_units ; 0=Meters, 1=Feets | 159 OPTION_ENUM8 oUnits, 2, 0, tMetric, .28, opt_units ; 0=Meters, 1=Feets |
127 | 160 |
128 ;============================================================================= | 161 ;============================================================================= |
129 ; Compass calibration data | 162 ; Compass calibration data |
130 OPTION_UINT8 oCalx0, 0,.255,.0, 0, .29, compass_CX_f+0 | 163 OPTION_UINT8 oCalx0, 0,.255,.0, 0, .29, compass_CX_f+0 |
191 ; opt_name from 85 to 145 | 224 ; opt_name from 85 to 145 |
192 OPTION_STRING oName, opt_name_length, tDefName, .85, opt_name | 225 OPTION_STRING oName, opt_name_length, tDefName, .85, opt_name |
193 | 226 |
194 ;============================================================================= | 227 ;============================================================================= |
195 ; Misc | 228 ; Misc |
196 OPTION_ENUM8 oColorSetDive, 4, 0, tColorSetName0, .146, opt_dive_color_scheme ; Color scheme divemode | 229 OPTION_ENUM8 oColorSetDive, 4, 0, tColorSetName0, .146, opt_dive_color_scheme ; Color scheme divemode |
197 OPTION_UINT8 oPressureAdjust, .0,.255, .0, -1, .147, opt_pressure_adjust ; SIGNED int (-20/+20mbar max.) | 230 OPTION_UINT8 oPressureAdjust, .0,.255, .0, -1, .147, opt_pressure_adjust ; SIGNED int (-20/+20mbar max.) |
198 OPTION_BOOL oSafetyStop, 0, .148, opt_enable_safetystop ; =1: A safety stop is shown | 231 OPTION_BOOL oSafetyStop, 0, .148, opt_enable_safetystop ; =1: A safety stop is shown |
199 OPTION_UINT8 oCalGasO2, .21,.100, .21, tPercent, .149, opt_calibration_O2_ratio ; Calibration gas %O2 (Do not move in EEPROM, must stay at .149!) | 232 OPTION_UINT8 oCalGasO2, .21,.100, .21, tPercent, .149, opt_calibration_O2_ratio ; Calibration gas %O2 (Do not move in EEPROM, must stay at .149!) |
200 OPTION_BOOL oSensorFallback,1, .150, opt_sensor_fallback ; =1: Fallback to SP1 when sensor is lost | 233 OPTION_BOOL oFlipScreen, 0, .151, opt_flip_screen ; =1: Flip the screen |
201 OPTION_BOOL oFlipScreen, 0, .151, opt_flip_screen ; =1: Flip the screen | 234 OPTION_UINT8p10 ocR_button_left, .20, .100, .40, tPercent, .152, opt_cR_button_left ; left button sensitivity |
202 OPTION_UINT8p10 ocR_button_left, .20, .100, .40, tPercent, .152, opt_cR_button_left ; left button sensitivity | 235 OPTION_UINT8p10 ocR_button_right,.20, .100, .40, tPercent, .153, opt_cR_button_right ; right button sensitivity |
203 OPTION_UINT8p10 ocR_button_right,.20, .100, .40, tPercent, .153, opt_cR_button_right ; right button sensitivity | 236 OPTION_UINT8 obottom_usage, .5,.50, .20,tLitersMinute, .154, char_I_bottom_usage ; l/min |
204 OPTION_UINT8 obottom_usage, .5,.50, .20,tLitersMinute, .154, char_I_bottom_usage ; l/min | 237 OPTION_UINT8 odeco_usage, .5,.50, .20,tLitersMinute, .155, char_I_deco_usage ; l/min |
205 OPTION_UINT8 odeco_usage, .5,.50, .20,tLitersMinute, .155, char_I_deco_usage ; l/min | 238 OPTION_BOOL oMODwarning, 0, .156, opt_modwarning ; =1: red depth blinking warning |
206 OPTION_BOOL oMODwarning, 0, .156, opt_modwarning ; =1: red depth blinking warning | 239 OPTION_BOOL oVSItextv2, 0, .157, opt_vsitextv2 ; =1: use the dynamic (depends on depth) ascend rate limits |
207 OPTION_BOOL oVSItextv2, 0, .157, opt_vsitextv2 ; =1: use the dynamic (depends on depth) ascend rate limits | 240 OPTION_BOOL oVSIgraph, 0, .158, opt_vsigraph ; =1: draw the graphical VSI bar |
208 OPTION_BOOL oVSIgraph, 0, .158, opt_vsigraph ; =1: draw the graphical VSI bar | 241 OPTION_BOOL oShowppO2, 0, .159, opt_showppo2 ; =1:always show the ppO2 value in the warning position |
209 OPTION_BOOL oShowppO2, 0, .159, opt_showppo2 ; =1:always show the ppO2 value in the warning position | 242 OPTION_UINT8 oTemperatureAdjust, .0,.255, .0, -1, .160, opt_temperature_adjust ; SIGNED int (-2.0/+2.0 °C max.) |
210 OPTION_UINT8 oTemperatureAdjust, .0,.255, .0, -1, .160, opt_temperature_adjust ; SIGNED int (-2.0/+2.0 °C max.) | 243 OPTION_UINT8 oSafetyStopLength, .60,.240, .180, -1, .161, opt_safety_stop_length ; [s] |
211 OPTION_UINT8 oSafetyStopLength, .60,.240, .180, -1, .161, opt_safety_stop_length ; [s] | 244 OPTION_UINT8 oSafetyStopStart, .21,.61, .51, -1, .162, opt_safety_stop_start ; [cbar], default 510mbar, min 210mbar, max 610mbar |
212 OPTION_UINT8 oSafetyStopStart, .21,.61, .51, -1, .162, opt_safety_stop_start ; [cbar], default 510mbar, min 210mbar, max 610mbar | 245 OPTION_UINT8 oSafetyStopEnd, .19,.39, .29, -1, .163, opt_safety_stop_end ; [cbar], default 290mbar, min 190mbar, max 390mbar |
213 OPTION_UINT8 oSafetyStopEnd, .19,.39, .29, -1, .163, opt_safety_stop_end ; [cbar], default 290mbar, min 190mbar, max 390mbar | 246 OPTION_UINT8 oSafetyStopReset, .81,.151, .101, -1, .164, opt_safety_stop_reset ; [cbar], default 1010mbar, min 810mbar, max 1510mbar |
214 OPTION_UINT8 oSafetyStopReset, .81,.151, .101, -1, .164, opt_safety_stop_reset ; [cbar], default 1010mbar, min 810mbar, max 1510mbar | |
215 OPTION_UINT8 oDiveTimeout, .1,.20, divemode_timeout_default, tMinutes, .168, opt_diveTimeout ; Timeout for divemode in minutes | 247 OPTION_UINT8 oDiveTimeout, .1,.20, divemode_timeout_default, tMinutes, .168, opt_diveTimeout ; Timeout for divemode in minutes |
216 OPTION_UINT8 oPSCR_drop, .0,.15, .4, tPercent,.169, opt_PSCR_drop ; PSCR Drop [%] | 248 OPTION_UINT8 oPSCR_drop, .0,.15, .4, tPercent,.169, char_I_PSCR_drop ; PSCR Drop [%] |
217 OPTION_UINT8 oPSCR_lungratio,.5,.20, .10, tPercent,.170, opt_PSCR_lungratio ; PSCR Lung Ratio [1/x] | 249 OPTION_UINT8 oPSCR_lungratio,.5,.20, .10, tPercent,.170, char_I_PSCR_lungratio ; PSCR Lung Ratio [1/x] |
218 OPTION_UINT8p10 oPPO2MaxDeco,.120, ppo2_warning_high_deco,.160,0,.171, opt_ppO2_max_deco ; ppO2 max for deco gases | 250 OPTION_UINT8p10 oPPO2MaxDeco,.120, ppo2_warning_high_deco,.160,0,.171, char_I_ppO2_max_deco ; ppO2 max for deco gases |
251 OPTION_UINT8p10 oPPO2MinCC, ppo2_warning_low_cc_min, ppo2_warning_low_cc_max, ppo2_warning_low_cc, 0, .172, char_I_ppO2_min_loop ; ppO2 min for Loop | |
252 OPTION_UINT8 oTankSize1, .1, .40, .11, tLiter, .173, char_I_tank_size+0 ; size of OC gas tank 1 | |
253 OPTION_UINT8 oTankSize2, .1, .40, .11, tLiter, .174, char_I_tank_size+1 ; size of OC gas tank 2 | |
254 OPTION_UINT8 oTankSize3, .1, .40, .11, tLiter, .175, char_I_tank_size+2 ; size of OC gas tank 3 | |
255 OPTION_UINT8 oTankSize4, .1, .40, .11, tLiter, .176, char_I_tank_size+3 ; size of OC gas tank 4 | |
256 OPTION_UINT8 oTankSize5, .1, .40, .11, tLiter, .177, char_I_tank_size+4 ; size of OC gas tank 5 | |
257 OPTION_UINT8 oTankFillPres1, .5, .29, .20, tbar10, .178, char_I_tank_pres_fill+0 ; fill press of OC gas tank 1 | |
258 OPTION_UINT8 oTankFillPres2, .5, .29, .20, tbar10, .179, char_I_tank_pres_fill+1 ; fill press of OC gas tank 2 | |
259 OPTION_UINT8 oTankFillPres3, .5, .29, .20, tbar10, .180, char_I_tank_pres_fill+2 ; fill press of OC gas tank 3 | |
260 OPTION_UINT8 oTankFillPres4, .5, .29, .20, tbar10, .181, char_I_tank_pres_fill+3 ; fill press of OC gas tank 4 | |
261 OPTION_UINT8 oTankFillPres5, .5, .29, .20, tbar10, .182, char_I_tank_pres_fill+4 ; fill press of OC gas tank 5 | |
262 OPTION_UINT8 oCCmaxFracO2, .80, .100, .90, tPercent,.183, char_I_cc_max_frac_o2 ; max. O2 % in Loop | |
263 OPTION_UINT8 oSimSetpoint, .1, .5, .1, tblank, .184, opt_sim_setpoint_number ; setpoint to use for deco calculation | |
264 OPTION_BOOL oCalcAscGas, 0, .185, opt_calc_asc_gasvolume ; calculate OC gas volume needs for ascent | |
265 OPTION_BOOL oSimAGF, 0, -1, opt_sim_use_aGF ; use GF (no) or aGF (yes) for deco calculation | |
266 OPTION_ENUM8 oAltMode, 4, 0, tAltModeFly, .186, char_I_altitude_wait ; 0=no-fly, 1=1000m, 2=2000m, 3=3000m | |
267 OPTION_BOOL oEnable_IBCD, 0, .187, opt_enable_IBCD ; =1: IBCD warning activated | |
268 OPTION_UINT8 oAscentSpeed, .5, .10, .10,tMeterMinute,.188, char_I_ascent_speed ; ascent speed - Attention: proper operation with other values than the default of 10m/min has not been validated yet! Do not deviate from the default until further notice! | |
269 OPTION_UINT8 oGasChangeTime,.0, .3, .1, tmin ,.198, char_I_gas_change_time ; (extra) time at a stop to change the gas | |
270 | |
219 ;============================================================================= | 271 ;============================================================================= |
220 ; Set Time/Set Date (RAM only) | 272 ; Set Time/Set Date (RAM only) |
221 OPTION_UINT8 oSetHours, .0, .23, .0, 0, -1, hours | 273 OPTION_UINT8 oSetHours, .0, .23, .0, 0, -1, hours |
222 OPTION_UINT8 oSetMinutes, .0, .59, .0, 0, -1, mins | 274 OPTION_UINT8 oSetMinutes, .0, .59, .0, 0, -1, mins |
223 OPTION_UINT8 oSetDay, .1, .31, .0, 0, -1, day | 275 OPTION_UINT8 oSetDay, .1, .31, .0, 0, -1, day |