Mercurial > public > hwos_code
comparison src/hwos.inc @ 631:185ba2f91f59
3.09 beta 1 release
author | heinrichsweikamp |
---|---|
date | Fri, 28 Feb 2020 15:45:07 +0100 |
parents | 237931377539 |
children | 4050675965ea |
comparison
equal
deleted
inserted
replaced
630:4cd81bdbf15c | 631:185ba2f91f59 |
---|---|
1 ;============================================================================= | 1 ;============================================================================= |
2 ; | 2 ; |
3 ; File hwos.inc combined next generation V3.06.2 | 3 ; File hwos.inc combined next generation V3.08.8 |
4 ; | 4 ; |
5 ; OSTC Platform Definitions | 5 ; OSTC Platform Definitions |
6 ; | 6 ; |
7 ; Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved. | 7 ; Copyright (c) 2011, JD Gascuel, HeinrichsWeikamp, all right reserved. |
8 ;============================================================================= | 8 ;============================================================================= |
28 #DEFINE fr 3 ; select French | 28 #DEFINE fr 3 ; select French |
29 #DEFINE it 4 ; select Italian | 29 #DEFINE it 4 ; select Italian |
30 | 30 |
31 | 31 |
32 ; Magic Cookie Definition | 32 ; Magic Cookie Definition |
33 #DEFINE comm_service_key 0xABCDEF ; simsalabim to establish data connection | 33 #DEFINE comm_service_key 0xABCDEF ; simsalabim to establish comm service mode |
34 | 34 |
35 | 35 |
36 ; Logo Address Vectors | 36 ; Logo Address Vectors |
37 #DEFINE hw_logo_block 0x01E000 ; color image data for heinrichsweikamp logo | 37 #DEFINE hw_logo_block 0x01E000 ; color image data for heinrichsweikamp logo |
38 #DEFINE usb_ble_logo_1 0x01EEDE ; color image data for USB or BLE logo | 38 #DEFINE usb_ble_logo_1 0x01EEDE ; color image data for USB or BLE logo |
39 #DEFINE usb_ble_logo_2 0x01EA04 ; color image data for USB or BLE logo, "+" bootloader | 39 #DEFINE usb_ble_logo_2 0x01EA04 ; color image data for USB or BLE logo, "+" bootloader |
40 | 40 |
41 | 41 |
42 ;-----------------------------EEPROM DATA ------------------------------------ | 42 ;-----------------------------EEPROM DATA ------------------------------------ |
43 ; Automatic reset of all options when this is changed: | 43 ; Automatic reset of all options when this is changed: |
44 #DEFINE eeprom_opt_serial 0x0008 ; Version 0.8 | 44 #DEFINE eeprom_opt_version .8 ; range: 16 bit |
45 #DEFINE eeprom_vault_version .1 ; range: 8 bit | |
45 ;----------------------------------------------------------------------------- | 46 ;----------------------------------------------------------------------------- |
46 | 47 |
47 | 48 |
48 #DEFINE CCP1CON_VALUE b'00001100' ; PWM1 for LED dimming | 49 #DEFINE CCP1CON_VALUE b'00001100' ; PWM1 for LED dimming |
49 #DEFINE T2CON_ECO b'01111110' | 50 #DEFINE T2CON_ECO b'01111110' |
60 #DEFINE speed_is_normal cpu_speed_state,1 ; =1: CPU is running at normal speed | 61 #DEFINE speed_is_normal cpu_speed_state,1 ; =1: CPU is running at normal speed |
61 #DEFINE speed_is_fastest cpu_speed_state,2 ; =1: CPU is running at fastest speed | 62 #DEFINE speed_is_fastest cpu_speed_state,2 ; =1: CPU is running at fastest speed |
62 | 63 |
63 | 64 |
64 ; Divemode Custom View Indexes - Attention: these numbers need to be in line with the jump tables in customview.asm! | 65 ; Divemode Custom View Indexes - Attention: these numbers need to be in line with the jump tables in customview.asm! |
66 #DEFINE index_blank .0 ; blank view | |
65 #DEFINE index_avr_stopwatch .1 ; average depth and stopwatch | 67 #DEFINE index_avr_stopwatch .1 ; average depth and stopwatch |
66 #DEFINE index_compass_dm .2 ; compass | 68 #DEFINE index_compass_dm .2 ; compass |
67 #DEFINE index_ppo2_sensors .3 ; ppO2 sensors | 69 #DEFINE index_ppo2_sensors .3 ; ppO2 sensors |
68 #DEFINE index_sensor_check .4 ; sensor check | 70 #DEFINE index_sensor_check .4 ; sensor check |
69 #DEFINE index_pscr_info .5 ; pSCR data | 71 #DEFINE index_pscr_info .5 ; pSCR data |
70 #DEFINE index_pressures_SAC .6 ; tank pressure and SAC rate | 72 #DEFINE index_pressures_SAC .6 ; tank pressure and SAC rate |
71 #DEFINE index_gas_needs_ascent .7 ; gas needs for ascent / cave return | 73 #DEFINE index_gas_needs_ascent .7 ; gas needs for ascent / cave return |
72 #DEFINE index_decoplan .8 ; deco plan | 74 #DEFINE index_cave_tts .8 ; cave mode TTS |
73 #DEFINE index_ceiling_GF_tissue .9 ; ceiling, current GF and tissues | 75 #DEFINE index_decoplan .9 ; deco plan |
74 #DEFINE index_CNS .10 ; CNS values | 76 #DEFINE index_ceiling_GF_tissue .10 ; ceiling, current GF and tissues |
75 #DEFINE index_ppo2_ead_end_cns .11 ; ppO2, END/EAD and CNS or gas density | 77 #DEFINE index_CNS .11 ; CNS values |
76 #DEFINE index_gf_factors .12 ; GF factors | 78 #DEFINE index_ppo2_ead_end_cns .12 ; ppO2, END/EAD and CNS or gas density |
77 #DEFINE index_clock_batt_surfpress .13 ; clock, battery and surface pressure | 79 #DEFINE index_clock_batt_surfpress .13 ; clock, battery and surface pressure |
78 #DEFINE index_cv_dm_max .13 ; highest index in use in dive mode custom view | 80 #DEFINE index_gf_factors .14 ; GF factors |
81 #DEFINE index_cave_waypoints .15 ; cave waypoints | |
82 #DEFINE index_cv_dm_max .13 ; highest index used in normal custom view rotation | |
79 | 83 |
80 | 84 |
81 ; Timing for button hold-down flags | 85 ; Timing for button hold-down flags |
82 #DEFINE TMR1H_VALUE_FIRST .255-.128 ; in steps of 7.8125 ms -> 1 s | 86 #DEFINE TMR1H_VALUE_FIRST .255-.128 ; in steps of 7.8125 ms -> 1.00 s |
83 #DEFINE TMR1H_VALUE_CONT .255-.32 ; in steps of 7.8125 ms -> 0.25 s | 87 #DEFINE TMR1H_VALUE_CONT .255-.32 ; in steps of 7.8125 ms -> 0.25 s |
84 #DEFINE TMR1H_VALUE_CONT_DIVE .255-.64 ; in steps of 7.8125 ms -> 0.5 s | 88 #DEFINE TMR1H_VALUE_CONT_DIVE .255-.64 ; in steps of 7.8125 ms -> 0.50 s |
85 | 89 |
86 | 90 |
87 ; Color Definitions: 8 bit RGB b'RRRGGGBB' | 91 ; Color Definitions: 8 bit RGB b'RRRGGGBB' |
88 #DEFINE color_red b'11100000' ; (7,0,0) | 92 #DEFINE color_red b'11100000' ; (7,0,0) |
89 #DEFINE color_dark_red b'10000101' ; (4,1,1) | 93 #DEFINE color_dark_red b'10000101' ; (4,1,1) |
117 #DEFINE max_mv .2500 ; = 250 mV | 121 #DEFINE max_mv .2500 ; = 250 mV |
118 #DEFINE ignore_mv .3500 ; = 350 mV (to suppress ghost readings for long, open cables) | 122 #DEFINE ignore_mv .3500 ; = 350 mV (to suppress ghost readings for long, open cables) |
119 | 123 |
120 | 124 |
121 ; Profile Recording Parameters | 125 ; Profile Recording Parameters |
122 #DEFINE logbook_profile_version 0x24 | 126 #DEFINE logbook_profile_version 0x24 ; logbook recording format |
123 #DEFINE samplingrate_apnoe .1 ; [seconds] | 127 #DEFINE samplingrate_apnoe .1 ; [seconds] |
124 | 128 |
125 | 129 |
126 ; Profile Recording Rates - Attention: all Divisors must be < 16 ! | 130 ; Profile Recording Rates - Attention: all Divisors must be < 16 ! |
127 #DEFINE div_temperature .6 ; x sampling rate [s] | 131 #DEFINE div_temperature .6 ; x sampling rate [s] |
153 #DEFINE tr_pres_options .15 ; number of options for pressure measurement source / with diluents | 157 #DEFINE tr_pres_options .15 ; number of options for pressure measurement source / with diluents |
154 ELSE | 158 ELSE |
155 #DEFINE tr_pres_options .6 ; number of options for pressure measurement source / OC gases only | 159 #DEFINE tr_pres_options .6 ; number of options for pressure measurement source / OC gases only |
156 ENDIF | 160 ENDIF |
157 | 161 |
162 | |
158 ; Cave Mode | 163 ; Cave Mode |
159 IFDEF _cave_mode | 164 IFDEF _cave_mode |
160 #DEFINE calc_gas_options .3 ; 3 options: off, on, cave | 165 #DEFINE backtrack_waypoint_max .30 ; highest user-available waypoint number (max allowed: 30) |
161 ELSE | 166 #DEFINE backtrack_almost_full_threshold .240 ; backtrack index position at which the almost full flag will be set |
162 #DEFINE calc_gas_options .2 ; 2 options: off, on | 167 #DEFINE backtrack_entire_full_threshold .250 ; backtrack index position at which the entirely full flag will be set |
163 ENDIF | 168 ENDIF |
164 | 169 |
165 | 170 |
166 ; Gas Needs Settings | 171 ; Gas Needs Settings |
167 #DEFINE min_tank_size .1 ; [liter] | 172 #DEFINE min_tank_size .1 ; [liter] |
169 #DEFINE min_fill_press .5 ; [0 bar] value is in multiples of 10 bar | 174 #DEFINE min_fill_press .5 ; [0 bar] value is in multiples of 10 bar |
170 #DEFINE max_fill_press .29 ; [0 bar] value is in multiples of 10 bar, no 300 bar due to too far beyond ideal gas laws | 175 #DEFINE max_fill_press .29 ; [0 bar] value is in multiples of 10 bar, no 300 bar due to too far beyond ideal gas laws |
171 | 176 |
172 | 177 |
173 ; Timeouts for Menus | 178 ; Timeouts for Menus |
174 #DEFINE surfmode_timeout_default .90 ; [s] default timeout for surface mode and surface menus | 179 #DEFINE surfmode_timeout_default .240 ; [s] default timeout for surface mode and surface menus |
175 #DEFINE surfmode_timeout_simulator .240 ; [s] special timeout for simulator (deco calculator) mode | 180 #DEFINE surfmode_timeout_aa_15v .90 ; [s] timeout for surface mode and surface menus when on 1.5V battery |
176 #DEFINE surfmode_timeout_sensor .240 ; [s] special timeout for surface mode when in CCR/pSCR sensor mode | 181 #DEFINE surfmode_timeout_simulator .240 ; [s] special timeout for simulator mode |
177 #DEFINE surfmode_timeout_calibrate .240 ; [s] special timeout when in surface CCR calibrate sensors menu | 182 ;#DEFINE surfmode_timeout_sensor .240 ; [s] special timeout for surface mode when in CCR/pSCR sensor mode |
178 #DEFINE surfmode_timeout_xmitter .240 ; [s] special timeout when in surface transmitter pairing menu | 183 ;#DEFINE surfmode_timeout_calibrate .240 ; [s] special timeout when in surface CCR calibrate sensors menu |
184 ;#DEFINE surfmode_timeout_xmitter .240 ; [s] special timeout when in surface transmitter pairing menu | |
179 | 185 |
180 #DEFINE divemode_timeout_premenu .10 ; [s] timeout for dive mode pre-menu | 186 #DEFINE divemode_timeout_premenu .10 ; [s] timeout for dive mode pre-menu |
181 #DEFINE divemode_timeout_mainmenu .30 ; [s] timeout for dive mode main menu | 187 #DEFINE divemode_timeout_mainmenu .30 ; [s] timeout for dive mode main menu |
182 | 188 |
183 | 189 |
190 ; RS232 Timeout | |
191 #DEFINE rx_timeout .400 ; [ms] timeout for RS232 RX | |
192 | |
193 | |
194 ; Dive-End Timeouts | |
195 #DEFINE simulator_timeout_normal .90 ; [min] timeout simulator mode | |
196 #DEFINE simulator_timeout_cave .240 ; [min] timeout simulator mode (cave mode) | |
197 #DEFINE apnoe_timeout .15 ; [min] timeout at surface in apnoe mode | |
198 #DEFINE simulator_timeout .15 ; [s] timeout at surface in simulator mode | |
199 | |
200 | |
184 ; other Timeouts | 201 ; other Timeouts |
185 #DEFINE simulator_timeout .15 ; [s] | 202 #DEFINE deep_sleep_10mins .144 ; [x 10mins] (24h in this example) |
186 #DEFINE apnoe_timeout .15 ; [min] | 203 |
187 #DEFINE deep_sleep_10mins .144 ; [x 10mins] (24h in this example) | |
188 | 204 |
189 ; Surface Mode Thresholds and Limits | 205 ; Surface Mode Thresholds and Limits |
190 #DEFINE high_altitude_threshold .880 ; [mbar] ambient pressure at which to switch into high altitude mode | 206 #DEFINE high_altitude_threshold .880 ; [mbar] ambient pressure at which to switch into high altitude mode |
191 #DEFINE max_surfpressure .1030 ; [mbar] maximum value for internal surface pressure | 207 #DEFINE max_surfpressure .1030 ; [mbar] maximum value for internal surface pressure |
192 | 208 |
204 ; Dive Mode Margins | 220 ; Dive Mode Margins |
205 #DEFINE ppO2_margin_on_max .300 ; [0.1 mbar] extra margin on ppO2 max values to compensate for surface pressures > 1000 hPa | 221 #DEFINE ppO2_margin_on_max .300 ; [0.1 mbar] extra margin on ppO2 max values to compensate for surface pressures > 1000 hPa |
206 #DEFINE sensor_voting_logic_threshold .10 ; threshold in 0.01 bar | 222 #DEFINE sensor_voting_logic_threshold .10 ; threshold in 0.01 bar |
207 | 223 |
208 | 224 |
225 ; Gas and Dil types | |
226 #DEFINE num_gas_types .4 ; Disabled, First, Normal, Deco | |
227 #DEFINE num_dil_types .3 ; Disabled, First, Normal | |
228 | |
229 | |
209 ; ppO2 Limits | 230 ; ppO2 Limits |
210 #DEFINE ppo2_warning_low_lowest .15 ; [cbar] minimum value for minimum ppO2 on OC | 231 #DEFINE ppo2_warning_low_lowest .15 ; [cbar] minimum value for minimum ppO2 on OC |
211 #DEFINE ppo2_warning_low_default .17 ; [cbar] default value for minimum ppO2 on OC | 232 #DEFINE ppo2_warning_low_default .17 ; [cbar] default value for minimum ppO2 on OC |
212 #DEFINE ppo2_warning_low_highest .21 ; [cbar] maximum value for minimum ppO2 on OC | 233 #DEFINE ppo2_warning_low_highest .21 ; [cbar] maximum value for minimum ppO2 on OC |
213 | 234 |
227 ELSE | 248 ELSE |
228 #DEFINE ppo2_warning_high_highest .160 ; [cbar] maximum value for maximum ppO2 in none-deco phase | 249 #DEFINE ppo2_warning_high_highest .160 ; [cbar] maximum value for maximum ppO2 in none-deco phase |
229 #DEFINE ppo2_warning_deco_highest .160 ; [cbar] maximum value for maximum ppO2 in deco phase | 250 #DEFINE ppo2_warning_deco_highest .160 ; [cbar] maximum value for maximum ppO2 in deco phase |
230 ENDIF | 251 ENDIF |
231 | 252 |
253 ; Salinity Limits | |
254 #DEFINE salinity_min .0 ; [%] minimum value for salinity percentage | |
255 #DEFINE salinity_max .4 ; [%] maximum value for salinity percentage | |
232 | 256 |
233 ; Color-Code Parameters for the Dive Mode | 257 ; Color-Code Parameters for the Dive Mode |
234 #DEFINE color_code_velocity_warn_high .11 ; [m/min] | 258 #DEFINE color_code_velocity_warn_high .11 ; [m/min] |
235 #DEFINE color_code_velocity_attn_high .10 ; [m/min] | 259 #DEFINE color_code_velocity_attn_high .10 ; [m/min] |
236 #DEFINE velocity_display_threshold .3 ; [m/min] | 260 #DEFINE velocity_display_threshold .3 ; [m/min] |
250 #DEFINE lithium_36v_low .2000 ; [mV] Saft 3.6 V LS14500 AA - lowest possible voltage, value must be higher than value of aa_15v_high! | 274 #DEFINE lithium_36v_low .2000 ; [mV] Saft 3.6 V LS14500 AA - lowest possible voltage, value must be higher than value of aa_15v_high! |
251 #DEFINE aa_15v_high .1550 ; [mV] Energizer 1.5 V E2 AA - highest possible voltage, value must be lower than value of lithium_36v_low! | 275 #DEFINE aa_15v_high .1550 ; [mV] Energizer 1.5 V E2 AA - highest possible voltage, value must be lower than value of lithium_36v_low! |
252 #DEFINE aa_15v_low .1100 ; [mV] Energizer 1.5 V E2 AA - lowest possible voltage, according to Energizer data sheet EBC-4201R, page 2 | 276 #DEFINE aa_15v_low .1100 ; [mV] Energizer 1.5 V E2 AA - lowest possible voltage, according to Energizer data sheet EBC-4201R, page 2 |
253 #DEFINE battery_show_level .30 ; [%] threshold when to show battery level | 277 #DEFINE battery_show_level .30 ; [%] threshold when to show battery level |
254 #DEFINE battery_warn_level_36 .15 ; [%] threshold for 3.6 V battery warning, also acts as threshold for setting display brightness level to ECO when in dive mode | 278 #DEFINE battery_warn_level_36 .15 ; [%] threshold for 3.6 V battery warning, also acts as threshold for setting display brightness level to ECO when in dive mode |
255 #DEFINE battery_warn_level_15 .25 ; [%] threshold for 1.5 V battery warning, also acts as threshold for setting display brightness level to ECO when in dive modebattery warning level, also acts as threshold for setting display brightness level to ECO when in dive mode | 279 #DEFINE battery_warn_level_15 .25 ; [%] threshold for 1.5 V battery warning, also acts as threshold for setting display brightness level to ECO when in dive mode |
256 | 280 |
257 | 281 |
258 ; 3.6 Volt Battery Sensing Data Points at 70 mA Load | 282 ; 3.6 Volt Battery Sensing Data Points at 70 mA Load |
259 #DEFINE lithium_36v_75 .3000 ; [mV] | 283 #DEFINE lithium_36v_75 .3000 ; [mV] |
260 #DEFINE lithium_36v_50 .2900 ; [mV] | 284 #DEFINE lithium_36v_50 .2900 ; [mV] |
309 #DEFINE ambient_light_max_eco .70 | 333 #DEFINE ambient_light_max_eco .70 |
310 #DEFINE ambient_light_min_eco .10 ; must be the lowest value! | 334 #DEFINE ambient_light_min_eco .10 ; must be the lowest value! |
311 | 335 |
312 | 336 |
313 ; IR Link Timeout | 337 ; IR Link Timeout |
314 #DEFINE ir_timeout_value .128 ; in multiples of 62.5 ms | 338 #DEFINE ir_timeout_value .128 ; in multiples of 62.5 ms |
315 | 339 |
316 | 340 |
317 ; Setpoint Control | 341 ; Setpoint Control |
318 #DEFINE surface_sp .50 ; in cbar | 342 #DEFINE surface_sp .50 ; in cbar |
343 | |
344 | |
345 ; Gas / Diluent Type & State | |
346 ; .0 ; | 0: disabled, 1: first, 2: normal/work, 3: deco | |
347 ; .1 ; | | |
348 #DEFINE gas_lost .2 ; =1: gas/diluent is lost (permanently unavailable) | |
349 #DEFINE gas_staged .3 ; =1: gas/diluent is staged (temporary unavailable) | |
350 ; .4 ; --- unused | |
351 ; .5 ; --- unused | |
352 ; .6 ; --- unused | |
353 ; .7 ; --- unused | |
319 | 354 |
320 | 355 |
321 ; Gaslist hard-coded Limits | 356 ; Gaslist hard-coded Limits |
322 IFDEF _helium | 357 IFDEF _helium |
323 #DEFINE gaslist_min_o2 .7 ; minimum O2 [%] ( 7% is minimum value to keep MOD < 255 meters / 1 Byte) | 358 #DEFINE gaslist_min_o2 .7 ; minimum O2 [%] ( 7% is minimum value to keep MOD < 255 meters / 1 Byte) |
359 #DEFINE gaslist_max_o2 .100 ; maximum O2 [%] | |
324 #DEFINE gaslist_max_He .100-gaslist_min_o2 ; maximum He [%] | 360 #DEFINE gaslist_max_He .100-gaslist_min_o2 ; maximum He [%] |
325 #DEFINE gaslist_max_change_depth .220 ; max. change depth [m] (219 is maximum value that can be produced by gaslist_calc_mod with 7% O2) | 361 #DEFINE gaslist_max_change_depth .220 ; max. change depth [m] (219 is maximum value that can be produced by gaslist_calc_mod with 7% O2) |
326 #DEFINE tissue_graphics_options .2 ; tissue graphics "Pres+Sat" and "N2+He" available | 362 #DEFINE tissue_graphics_options .2 ; tissue graphics "Pres+Sat" and "N2+He" available |
327 ELSE | 363 ELSE |
328 #DEFINE gaslist_min_o2 .21 ; minimum O2 [%] | 364 #DEFINE gaslist_min_o2 .21 ; minimum O2 [%] |
365 #DEFINE gaslist_max_o2 .100 ; maximum O2 [%] | |
329 #DEFINE gaslist_max_He .0 ; maximum He [%] | 366 #DEFINE gaslist_max_He .0 ; maximum He [%] |
330 #DEFINE gaslist_max_change_depth .70 ; max. change depth [m] (67 is maximum value that can be produced by gaslist_calc_mod with 21% O2) | 367 #DEFINE gaslist_max_change_depth .70 ; max. change depth [m] (67 is maximum value that can be produced by gaslist_calc_mod with 21% O2) |
331 #DEFINE tissue_graphics_options .1 ; tissue graphics "Pres+Sat" only available | 368 #DEFINE tissue_graphics_options .1 ; tissue graphics "Pres+Sat" only available |
332 ENDIF | 369 ENDIF |
333 | 370 |
334 | 371 |
335 ; Setpoint list hard-coded Limits | 372 ; Setpoint list hard-coded Limits |
336 #DEFINE gaslist_sp_stepsize .10 ; steps for setpoint setup [cbar] | 373 #DEFINE gaslist_sp_stepsize .10 ; steps for setpoint setup [cbar] |
337 #DEFINE gaslist_sp_max .160 ; max. setpoint [cbar] | 374 #DEFINE gaslist_sp_max .160 ; max. setpoint [cbar] |
338 #DEFINE gaslist_sp_min .50 ; min. setpoint [cbar] | 375 #DEFINE gaslist_sp_min .50 ; min. setpoint [cbar] |
376 #DEFINE sp_max_change_depth .100 ; max change depth [m] | |
339 | 377 |
340 | 378 |
341 ; Compass Display | 379 ; Compass Display |
342 #DEFINE compass_fast_treshold .9 ; show new heading instantly if angular difference > compass_fast_treshold, else show animated turning of compass rose | 380 #DEFINE compass_fast_treshold .9 ; show new heading instantly if angular difference > compass_fast_treshold, else show animated turning of compass rose |
343 #DEFINE compass_averaging .10 ; number of averaging cycles | 381 #DEFINE compass_averaging .10 ; number of averaging cycles |
345 | 383 |
346 ; Bit Flags for Communication with p2_deco.c - char_O_main_status | 384 ; Bit Flags for Communication with p2_deco.c - char_O_main_status |
347 #DEFINE DECO_VOLUME_FLAG .0 ; =1: calculate gas needs | 385 #DEFINE DECO_VOLUME_FLAG .0 ; =1: calculate gas needs |
348 #DEFINE DECO_BOTTOM_FLAG .1 ; =1: calculate gas needs for full bottom segment, =0: ...for extra time only | 386 #DEFINE DECO_BOTTOM_FLAG .1 ; =1: calculate gas needs for full bottom segment, =0: ...for extra time only |
349 #DEFINE DECO_CAVE_MODE .2 ; =1: calculate ascent and gas needs using backtracking data | 387 #DEFINE DECO_CAVE_MODE .2 ; =1: calculate ascent and gas needs using backtracking data |
350 #DEFINE DECO_Z_FACTOR_FLAG .3 ; =1: calculate with Z factor when converting gas volumes <-> pressures | 388 #DEFINE DECO_GAS_CONTINGENCY .3 ; =1: use a second best gas if best gas is all used up |
351 #DEFINE DECO_TR_FUNCTIONS .4 ; =1: calculate TR functions (pressure readings) | 389 #DEFINE DECO_TR_FUNCTIONS .4 ; =1: calculate TR functions (pressure readings) |
352 #DEFINE DECO_EXTENDED_STOPS .5 ; =1: place gas changes also below 1st stop depth | 390 #DEFINE DECO_EXTENDED_STOPS .5 ; =1: place gas changes also below 1st stop depth |
353 #DEFINE DECO_MODE_LOOP_FLAG .6 ; =1: calculate real tissues in loop mode (CCR or pSCR) | 391 #DEFINE DECO_MODE_LOOP_FLAG .6 ; =1: calculate real tissues in loop mode (CCR or pSCR) |
354 #DEFINE DECO_MODE_PSCR_FLAG .7 ; =1: calculate real tissues in pSCR mode (loop flag needs to be set, too) | 392 #DEFINE DECO_MODE_PSCR_FLAG .7 ; =1: calculate real tissues in pSCR mode (loop flag needs to be set, too) |
355 | 393 |
360 #DEFINE DECO_COMPLETED_NORM .0 ; =1: read: calculation of a normal deco plan has completed | 398 #DEFINE DECO_COMPLETED_NORM .0 ; =1: read: calculation of a normal deco plan has completed |
361 #DEFINE DECO_COMPLETED_ALT .1 ; =1: read: calculation of an alternative deco plan has completed | 399 #DEFINE DECO_COMPLETED_ALT .1 ; =1: read: calculation of an alternative deco plan has completed |
362 #DEFINE DECO_INITIALIZE .2 ; =1: write: initialize deco engine (to be done only once at the begin of every dive) | 400 #DEFINE DECO_INITIALIZE .2 ; =1: write: initialize deco engine (to be done only once at the begin of every dive) |
363 #DEFINE DECO_CALCULATOR_MODE .3 ; =1: deco engone is run from the deco calculator | 401 #DEFINE DECO_CALCULATOR_MODE .3 ; =1: deco engone is run from the deco calculator |
364 #DEFINE DECO_BAILOUT_FLAG .4 ; =1: allow gas switches before first deco stop (used in bailout plans) | 402 #DEFINE DECO_BAILOUT_FLAG .4 ; =1: allow gas switches before first deco stop (used in bailout plans) |
365 #DEFINE DECO_ASCENT_FLAG .5 ; =1: figure in a delayed ascent (fTTS) | 403 #DEFINE DECO_DELAY_FLAG .5 ; =1: figure in a delayed ascent (fTTS) |
366 ; DECO_MODE_LOOP_FLAG .6 ; =1: calculate simulated tissues in loop mode (CCR or pSCR) | 404 ; DECO_MODE_LOOP_FLAG .6 ; =1: calculate simulated tissues in loop mode (CCR or pSCR) |
367 ; DECO_MODE_PSCR_FLAG .7 ; =1: calculate simulated tissues in pSCR mode (loop flag needs to be set, too) | 405 ; DECO_MODE_PSCR_FLAG .7 ; =1: calculate simulated tissues in pSCR mode (loop flag needs to be set, too) |
368 | 406 |
369 | 407 |
370 ; Bit Flags for Communication with p2_deco.c - char_O_deco_warnings | 408 ; Bit Flags for Communication with p2_deco.c - char_O_deco_warnings |
379 | 417 |
380 | 418 |
381 ; Bit Flags for Communication with p2_deco.c - char_O_deco_info | 419 ; Bit Flags for Communication with p2_deco.c - char_O_deco_info |
382 #DEFINE deco_mode .0 ; =1: in deco mode, deco ppO2 levels permitted | 420 #DEFINE deco_mode .0 ; =1: in deco mode, deco ppO2 levels permitted |
383 #DEFINE ind_double_switch .1 ; =1: switch to other tank advice active | 421 #DEFINE ind_double_switch .1 ; =1: switch to other tank advice active |
384 ; .2 ; --- unused | 422 #DEFINE gas_needs_fTTS .2 ; =1: indicated gas needs are calculated in fTTS mode |
385 #DEFINE deco_zone .3 ; =1: fTTS is <= TTS (not updated when in bailout mode) | 423 #DEFINE deco_zone .3 ; =1: fTTS is <= TTS (not updated when in bailout mode) |
386 #DEFINE deco_ceiling .4 ; =1: ceiling depth > 0 | 424 #DEFINE deco_ceiling .4 ; =1: ceiling depth > 0 |
387 #DEFINE deco_stops .5 ; =1: deco stops found | 425 #DEFINE deco_stops_norm .5 ; =1: deco stops found in normal plan |
388 #DEFINE gas_needs_cave .6 ; =1: indicated gas needs are calculated in cave mode | 426 #DEFINE deco_stops_alt .6 ; =1: deco stops found in alternative plan |
389 ; .7 ; --- unused | 427 #DEFINE gas_needs_cave .7 ; =1: indicated gas needs are calculated in cave mode |
390 | 428 |
391 | 429 |
392 ; Bit Flags for Status on Variables of Type char | 430 ; Bit Flags for Status on Variables of Type char |
393 #DEFINE char_transmitter_lost .6 | 431 #DEFINE char_transmitter_lost .6 |
394 #DEFINE char_invalid_flag .7 | 432 #DEFINE char_invalid_flag .7 |
395 #DEFINE char_transmitter_low_bat .7 | 433 #DEFINE char_transmitter_low_bat .7 |
396 | 434 |
397 | 435 |
398 ; Bit Flags for Status on Variables of Type int (Flags are placed in the upper byte) | 436 ; Bit Flags for Status on Variables of Type int (Flags are placed in the UPPER byte!) |
399 #DEFINE int_invalid_flag .2 | 437 #DEFINE int_invalid_flag .2 |
400 #DEFINE int_not_yet_computed .3 | 438 #DEFINE int_not_yet_computed .3 |
401 #DEFINE int_is_zero .3 | 439 #DEFINE int_is_zero .3 |
402 #DEFINE int_low_flag .4 | 440 #DEFINE int_low_flag .4 |
403 #DEFINE int_not_avail_flag .4 | 441 #DEFINE int_not_avail_flag .4 |
464 #DEFINE compass_enabled HW_flags_state1,7 ; =1: the compass and accelerometer chip is active | 502 #DEFINE compass_enabled HW_flags_state1,7 ; =1: the compass and accelerometer chip is active |
465 | 503 |
466 ;---- Hardware - States 2 (stored in access RAM, NOT cleared on restart) | 504 ;---- Hardware - States 2 (stored in access RAM, NOT cleared on restart) |
467 #DEFINE cc_active HW_flags_state2,0 ; =1: constant current charging active (cR hardware only) | 505 #DEFINE cc_active HW_flags_state2,0 ; =1: constant current charging active (cR hardware only) |
468 #DEFINE cv_active HW_flags_state2,1 ; =1: constant voltage charging active (cR hardware only) | 506 #DEFINE cv_active HW_flags_state2,1 ; =1: constant voltage charging active (cR hardware only) |
469 ; HW_flags_state2,2 ; --- unused | 507 #DEFINE i2c_error_flag HW_flags_state2,2 ; =1: an I2C error occurred |
470 ; HW_flags_state2,3 ; --- unused | 508 #DEFINE rs232_rx_timeout HW_flags_state2,3 ; =1: RS232 receive timeout occurred |
471 ; HW_flags_state2,4 ; --- unused | 509 #DEFINE address_wrap_around HW_flags_state2,4 ; =1: the ext_flash_address wrapped around on increment |
472 ; HW_flags_state2,5 ; --- unused | 510 #DEFINE battery_low_condition HW_flags_state2,5 ; =1: low battery condition detected |
473 ; HW_flags_state2,6 ; --- unused | 511 ; HW_flags_state2,6 ; --- unused |
474 ; HW_flags_state2,7 ; --- unused | 512 ; HW_flags_state2,7 ; --- unused |
475 | 513 |
476 | 514 |
477 ;---- Operating System - persistent Settings (stored in access RAM, NOT cleared in restart) | 515 ;---- Operating System - persistent Settings (stored in access RAM, NOT cleared in restart) |
478 #DEFINE sensor1_calibrated_ok OS_flags_persist,0 ; =1: sensor 1 calibration ok | 516 #DEFINE sensor1_calibrated_ok OS_flags_persist,0 ; =1: sensor 1 calibration ok |
479 #DEFINE sensor2_calibrated_ok OS_flags_persist,1 ; =1: sensor 2 calibration ok | 517 #DEFINE sensor2_calibrated_ok OS_flags_persist,1 ; =1: sensor 2 calibration ok |
480 #DEFINE sensor3_calibrated_ok OS_flags_persist,2 ; =1: sensor 3 calibration ok | 518 #DEFINE sensor3_calibrated_ok OS_flags_persist,2 ; =1: sensor 3 calibration ok |
481 #DEFINE compass_bearing_set OS_flags_persist,3 ; =1: compass bearing is set | 519 #DEFINE compass_bearing_set OS_flags_persist,3 ; =1: compass bearing is set |
482 #DEFINE use_old_batt_flag OS_flags_persist,4 ; =1: load old battery data after power-on reset | 520 #DEFINE use_old_batt_flag OS_flags_persist,4 ; =1: load old battery data after power-on reset |
483 #DEFINE option_repaired OS_flags_persist,5 ; =1: options have been repaired | 521 #DEFINE options_changed OS_flags_persist,5 ; =1: option values have been changed, EEPROM needs to be updated |
484 #DEFINE restart_fast OS_flags_persist,6 ; =1: skip logos and waits on restart | 522 #DEFINE restart_fast OS_flags_persist,6 ; =1: request to skip logos and waits on restart |
485 #DEFINE battery_overtemp OS_flags_persist,7 ; =1: battery charging temperature limit exceeded | 523 #DEFINE battery_overtemp OS_flags_persist,7 ; =1: battery charging temperature limit exceeded |
486 | 524 |
487 | 525 |
488 ;---- Operating System - ISR Control 1 (stored in access RAM) | 526 ;---- Operating System - ISR Control 1 (stored in access RAM) |
489 #DEFINE reset_timebase OS_flags_ISR1,0 ; =1: request ISR to reset the timebase for the trigger flags | 527 #DEFINE reset_timebase OS_flags_ISR1,0 ; =1: request ISR to reset the timebase for the trigger flags |
535 ;----------------------------------------------------------------------------- | 573 ;----------------------------------------------------------------------------- |
536 ; Flags - stored in bank common | 574 ; Flags - stored in bank common |
537 | 575 |
538 ;---- Dive Mode - Dive States | 576 ;---- Dive Mode - Dive States |
539 #DEFINE use_aGF DM_flags_state,0 ; =1: use aGF, =0: use GF | 577 #DEFINE use_aGF DM_flags_state,0 ; =1: use aGF, =0: use GF |
540 #DEFINE sp_fallback DM_flags_state,1 ; =1: fall-back to SP1 due to external O2 sensor failure | 578 #DEFINE deco_locked DM_flags_state,1 ; =1: in or has been in deco obligation during the dive |
541 #DEFINE dive_turned DM_flags_state,2 ; =1: dive is turned | 579 #DEFINE deco_region DM_flags_state,2 ; =1: in or has been in the deco stops region during the dive |
542 #DEFINE cave_mode DM_flags_state,3 ; =1: in cave mode (gas needs by backtracking) | 580 #DEFINE cave_mode DM_flags_state,3 ; =1: cave mode is active (cave mode) |
543 #DEFINE depth_limit_exceeded DM_flags_state,4 ; =1: depth limit exceeded | 581 #DEFINE dive_turned DM_flags_state,4 ; =1: dive is turned (cave mode) |
544 #DEFINE deco_locked DM_flags_state,5 ; =1: in or has been in deco obligation during the dive | 582 #DEFINE backtrack_almost_full DM_flags_state,5 ; =1: the backtracking storage is almost full (cave mode) |
545 #DEFINE deco_region DM_flags_state,6 ; =1: in or has been in the deco stops region during the dive | 583 #DEFINE backtrack_entire_full DM_flags_state,6 ; =1: the backtracking storage is entirely full (cave mode) |
546 ; DM_flags_state,7 ; --- unused | 584 #DEFINE backtrack_shutdown DM_flags_state,7 ; =1: the backtracking has shut down due to entirely full (cave mode) |
547 | 585 |
548 ;---- Dive Mode - O2 Sensors | 586 ;---- Dive Mode - O2 Sensors |
549 #DEFINE use_O2_sensor1 DM_flags_sensor,0 ; =1: sensor 1 shall be used | 587 #DEFINE use_O2_sensor1 DM_flags_sensor,0 ; =1: sensor 1 shall be used |
550 #DEFINE use_O2_sensor2 DM_flags_sensor,1 ; =1: sensor 2 shall be used | 588 #DEFINE use_O2_sensor2 DM_flags_sensor,1 ; =1: sensor 2 shall be used |
551 #DEFINE use_O2_sensor3 DM_flags_sensor,2 ; =1: sensor 3 shall be used | 589 #DEFINE use_O2_sensor3 DM_flags_sensor,2 ; =1: sensor 3 shall be used |
552 #DEFINE voting_logic_sensor1 DM_flags_sensor,3 ; =1: sensor 1 is within the voting logic threshold | 590 #DEFINE voting_logic_sensor1 DM_flags_sensor,3 ; =1: sensor 1 is within the voting logic threshold |
553 #DEFINE voting_logic_sensor2 DM_flags_sensor,4 ; =1: sensor 2 is within the voting logic threshold | 591 #DEFINE voting_logic_sensor2 DM_flags_sensor,4 ; =1: sensor 2 is within the voting logic threshold |
554 #DEFINE voting_logic_sensor3 DM_flags_sensor,5 ; =1: sensor 3 is within the voting logic threshold | 592 #DEFINE voting_logic_sensor3 DM_flags_sensor,5 ; =1: sensor 3 is within the voting logic threshold |
555 ; DM_flags_sensor,6 ; --- unused | 593 #DEFINE sp_fallback DM_flags_sensor,6 ; =1: fall-back to SP1 due to external O2 sensor failure |
556 ; DM_flags_sensor,7 ; --- unused | 594 ; DM_flags_sensor,7 ; --- unused |
557 | 595 |
558 ;---- Dive Mode - User Requests | 596 ;---- Dive Mode - User Requests / General |
559 #DEFINE request_gaschange DM_flags_request,0 ; =1: request to change the gas | 597 #DEFINE request_gas_change DM_flags_request,0 ; =1: request to change the gas |
560 #DEFINE request_reset_avg DM_flags_request,1 ; =1: request to reset the average depth | 598 #DEFINE request_gas_update DM_flags_request,1 ; =1: request to update the gas |
561 #DEFINE request_next_custview DM_flags_request,2 ; =1: request to show the next custom view | 599 #DEFINE request_reset_avg DM_flags_request,2 ; =1: request to reset the average depth |
562 #DEFINE request_back_to_loop DM_flags_request,3 ; =1: request to switch back from bailout to loop | 600 #DEFINE request_next_custview DM_flags_request,3 ; =1: request to show the next custom view |
563 #DEFINE request_toggle_GF DM_flags_request,4 ; =1: request to toggle between GF and aGF | 601 #DEFINE request_back_to_loop DM_flags_request,4 ; =1: request to switch back from bailout to loop |
564 #DEFINE request_set_marker DM_flags_request,5 ; =1: request to set a marker in the logbook | 602 #DEFINE request_toggle_GF DM_flags_request,5 ; =1: request to toggle between GF and aGF |
565 #DEFINE request_turn_dive DM_flags_request,6 ; =1: request to toggle the dive turned status | 603 #DEFINE request_set_marker DM_flags_request,6 ; =1: request to set a marker in the logbook |
566 ; DM_flags_request,7 ; --- unused | 604 #DEFINE request_restart_engine DM_flags_request,7 ; =1: request to restart the deco engine |
605 | |
606 ;---- Dive Mode - User Requests / Cave Mode | |
607 #DEFINE request_cave_toggle DM_flags_cavereq,0 ; =1: request to toggle cave mode off/on (cave mode) | |
608 #DEFINE request_cave_off_turned DM_flags_cavereq,1 ; =1: request to switch cave mode off (cave mode) | |
609 #DEFINE request_turn_toggle DM_flags_cavereq,2 ; =1: request to toggle dive turned state (cave mode) | |
610 #DEFINE request_turn_turn DM_flags_cavereq,3 ; =1: request to switch dive turned state to turned (cave mode) | |
611 #DEFINE request_waypoint_set DM_flags_cavereq,4 ; =1: request to set a waypoint (cave mode) | |
612 #DEFINE request_waypoint_out DM_flags_cavereq,5 ; =1: request to go one waypoint out of the cave (cave mode) | |
613 #DEFINE request_waypoint_in DM_flags_cavereq,6 ; =1: request to go one waypoint into the cave (cave mode) | |
614 ; DM_flags_cavereq,7 ; --- unused | |
567 | 615 |
568 ;---- Dive Mode - Data Recording Events | 616 ;---- Dive Mode - Data Recording Events |
569 #DEFINE event_occured DM_flags_event,0 ; =1: an event occurred (global indicator flag) | 617 #DEFINE event_occured DM_flags_event,0 ; =1: an event occurred (global indicator flag) |
570 #DEFINE event_gas_change DM_flags_event,1 ; =1: a change to another gas or diluent occurred | 618 #DEFINE event_gas_change DM_flags_event,1 ; =1: a change to another gas or diluent occurred |
571 #DEFINE event_gas_change_gas6 DM_flags_event,2 ; =1: a change to or of the gas 6 has occurred | 619 #DEFINE event_gas_change_gas6 DM_flags_event,2 ; =1: a change to or of the gas 6 has occurred |
572 #DEFINE event_bailout DM_flags_event,3 ; =1: a change to or of the OC gas occurred due to bailout | 620 #DEFINE event_bailout DM_flags_event,3 ; =1: a change to or of the OC gas occurred due to bailout |
573 #DEFINE event_SP_change DM_flags_event,4 ; =1: a change of the setpoint has occurred | 621 #DEFINE event_SP_change DM_flags_event,4 ; =1: a change of the setpoint has occurred |
574 ; DM_flags_event,5 ; --- unused | 622 ; DM_flags_event,5 ; --- unused |
575 #DEFINE rs232_rx_timeout DM_flags_event,6 ; =1: RS232 receive timeout occurred | no better place found | 623 ; DM_flags_event,6 ; --- unused |
576 #DEFINE i2c_error_flag DM_flags_event,7 ; =1: an I2C error occurred | for these two flags... | 624 ; DM_flags_event,7 ; --- unused |
577 | 625 |
578 ;---- Dive Mode - Display Control / Layout | 626 ;---- Dive Mode - Display Control / Layout |
579 #DEFINE safety_stop_enabled DM_flags_layout1,0 ; =1: safety stop is enabled | 627 #DEFINE safety_stop_enabled DM_flags_layout1,0 ; =1: safety stop is enabled |
580 #DEFINE safety_stop_active DM_flags_layout1,1 ; =1: safety stop is shown | 628 #DEFINE safety_stop_active DM_flags_layout1,1 ; =1: safety stop is shown |
581 #DEFINE decostop_active DM_flags_layout1,2 ; =1: decompression stop is shown | 629 #DEFINE decostop_active DM_flags_layout1,2 ; =1: decompression stop is shown |
592 #DEFINE depth_warn_att_last DM_flags_layout2,4 ; =1: last depth was shown in warning or attention color | 640 #DEFINE depth_warn_att_last DM_flags_layout2,4 ; =1: last depth was shown in warning or attention color |
593 #DEFINE depth_inverse_last DM_flags_layout2,5 ; =1: last depth was shown in inverse | 641 #DEFINE depth_inverse_last DM_flags_layout2,5 ; =1: last depth was shown in inverse |
594 #DEFINE gas_needs_mode_last DM_flags_layout2,6 ; =1: last gas needs were computed for cave mode, =0: direct ascent | 642 #DEFINE gas_needs_mode_last DM_flags_layout2,6 ; =1: last gas needs were computed for cave mode, =0: direct ascent |
595 #DEFINE tts_greater_99 DM_flags_layout2,7 ; =1: TTS > 99 minutes | 643 #DEFINE tts_greater_99 DM_flags_layout2,7 ; =1: TTS > 99 minutes |
596 | 644 |
645 #DEFINE tissue_graphic_layout DM_flags_layout3,0 ; =1: show pres+sat, =0: show N2/He pressures | |
646 #DEFINE tissue_graphic_gf DM_flags_layout3,1 ; =1: show GF lines | |
647 #DEFINE tissue_graphic_cns DM_flags_layout3,2 ; =1: shwo CNS value (surface mode graphic only) | |
648 #DEFINE tissue_graphic_mode DM_flags_layout3,3 ; =1: logbook mode (surface mode graphic only) | |
649 ; DM_flags_layout3,4 ; --- unused | |
650 ; DM_flags_layout3,5 ; --- unused | |
651 ; DM_flags_layout3,6 ; --- unused | |
652 ; DM_flags_layout3,7 ; --- unused | |
653 | |
654 | |
597 ;---- Dive Mode - Display Control / Messages | 655 ;---- Dive Mode - Display Control / Messages |
598 #DEFINE message_advice DM_flags_message,0 ; =1: an advice is active in dive mode | 656 #DEFINE message_advice DM_flags_message,0 ; =1: an advice is active in dive mode |
599 #DEFINE message_attention DM_flags_message,1 ; =1: an attention is active in dive mode or surface mode | 657 #DEFINE message_attention DM_flags_message,1 ; =1: an attention is active in dive mode or surface mode |
600 #DEFINE message_warning DM_flags_message,2 ; =1: a warning is active in dive mode or surface mode | 658 #DEFINE message_warning DM_flags_message,2 ; =1: a warning is active in dive mode or surface mode |
601 #DEFINE message_2nd_row_used DM_flags_message,3 ; =1: the second row contains a warning/attention/advice | 659 #DEFINE message_2nd_row_used DM_flags_message,3 ; =1: the second row contains a warning/attention/advice |
602 #DEFINE sign_shown DM_flags_message,4 ; =1: the warning/attention/advice sign is shown | 660 #DEFINE sign_shown DM_flags_message,4 ; =1: the warning/attention/advice sign is shown |
603 #DEFINE gas_needs_attention DM_flags_message,5 ; =1: the gas needs attention has been shown before | 661 #DEFINE gas_needs_attention DM_flags_message,5 ; =1: the gas needs attention has been shown before |
604 #DEFINE gas_needs_warning DM_flags_message,6 ; =1: the gas needs warning has been shown before | 662 #DEFINE gas_needs_warning DM_flags_message,6 ; =1: the gas needs warning has been shown before |
605 #DEFINE o2_sensors_warning DM_flags_message,7 ; =1: the O2 sensors warning has been shown before | 663 #DEFINE o2_sensors_warning DM_flags_message,7 ; =1: the O2 sensors warning has been shown before |
606 | 664 |
607 ;---- Dive Mode - Display Control / Gas, Diluent | 665 ;---- Dive Mode - Display Control / Gas, Diluent, Depth |
608 #DEFINE better_gas_hint DM_flags_gas_dil,0 ; =1: mark a gas when it is a better gas | 666 #DEFINE better_gas_hint DM_flags_gas_dil,0 ; =1: mark a gas when it is a better gas |
609 #DEFINE better_gas_available DM_flags_gas_dil,1 ; =1: a better gas is available | 667 #DEFINE color_code_gases DM_flags_gas_dil,1 ; =1: color code the gases by ppO2 & current depth |
610 #DEFINE better_gas_blinking DM_flags_gas_dil,2 ; =1: gas is blinking | 668 #DEFINE better_gas_available DM_flags_gas_dil,2 ; =1: a better gas is available |
611 #DEFINE better_dil_available DM_flags_gas_dil,3 ; =1: a better diluent is available | 669 #DEFINE better_gas_blinking DM_flags_gas_dil,3 ; =1: gas is blinking |
612 #DEFINE better_dil_blinking DM_flags_gas_dil,4 ; =1: diluent is blinking | 670 #DEFINE better_dil_available DM_flags_gas_dil,4 ; =1: a better diluent is available |
613 ; DM_flags_gas_dil,5 ; --- unused | 671 #DEFINE better_dil_blinking DM_flags_gas_dil,5 ; =1: diluent is blinking |
614 ; DM_flags_gas_dil,6 ; --- unused | 672 #DEFINE gas6_or_EXIT DM_flags_gas_dil,6 ; =1: exit menu, =0: provide gas6 option |
615 ; DM_flags_gas_dil,7 ; --- unused | 673 #DEFINE depth_limit_exceeded DM_flags_gas_dil,7 ; =1: depth limit exceeded |
616 | |
617 | 674 |
618 ;---- Menu System - Control | 675 ;---- Menu System - Control |
619 #DEFINE surfmode_menu MS_flags_control,0 ; =1: surface menu is shown (i.e. returning from it) | 676 #DEFINE surfmode_menu MS_flags_control,0 ; =1: surface menu is shown (i.e. returning from it) |
620 #DEFINE dive_options_menu MS_flags_control,1 ; =1: dive options menu is shown (e.g. "Menu?") | 677 #DEFINE dive_options_menu MS_flags_control,1 ; =1: dive options menu is shown (e.g. "Menu?") |
621 #DEFINE dive_main_menu MS_flags_control,2 ; =1: dive mode menu is shown (i.e. the "big" menu) | 678 #DEFINE dive_main_menu MS_flags_control,2 ; =1: dive mode menu is shown (i.e. the "big" menu) |
622 #DEFINE compass_menu MS_flags_control,3 ; =1: "set bearing" is shown | 679 #DEFINE compass_menu MS_flags_control,3 ; =1: "set bearing" is shown |
623 #DEFINE is_diluent_menu MS_flags_control,4 ; =1: setting up diluents, =0: setting up OC gases | 680 #DEFINE is_diluent_menu MS_flags_control,4 ; =1: setting up diluents, =0: setting up OC gases |
624 #DEFINE is_bailout_menu MS_flags_control,5 ; =1: in bailout menu | 681 #DEFINE is_bailout_menu MS_flags_control,5 ; =1: in bailout menu |
625 ; MS_flags_control,6 ; --- unused | 682 #DEFINE custom_view_locked MS_flags_control,6 ; =1: the custom view is locked (defer CV auto-popup) |
626 ; MS_flags_control,7 ; --- unused | 683 ; MS_flags_control,7 ; --- unused |
627 | 684 |
628 ;---- Menu System - Data Imprinting | 685 ;---- Menu System - Data Imprinting |
629 #DEFINE imprint_time_date MS_flags_imprint,0 ; =1: imprint current time & date | 686 #DEFINE imprint_time_date MS_flags_imprint,0 ; =1: imprint current time & date |
630 #DEFINE imprint_color_schemes MS_flags_imprint,1 ; =1: imprint color schemes | 687 #DEFINE imprint_color_schemes MS_flags_imprint,1 ; =1: imprint color schemes |
649 | 706 |
650 ;---- Convert and Display Functions (Control of numerical and other Output) | 707 ;---- Convert and Display Functions (Control of numerical and other Output) |
651 #DEFINE leftbind CVT_flags1,0 ; =1: align numbers to the left | 708 #DEFINE leftbind CVT_flags1,0 ; =1: align numbers to the left |
652 #DEFINE win_invert CVT_flags1,1 ; =1: the text shall be printed in inverse | 709 #DEFINE win_invert CVT_flags1,1 ; =1: the text shall be printed in inverse |
653 #DEFINE short_gas_descriptions CVT_flags1,2 ; =1: use short versions of gaslist_strcat_gas_cd and gaslist_strcat_setpoint | 710 #DEFINE short_gas_descriptions CVT_flags1,2 ; =1: use short versions of gaslist_strcat_gas_cd and gaslist_strcat_setpoint |
654 #DEFINE ignore_digit3 CVT_flags1,3 | 711 #DEFINE ignore_digit3 CVT_flags1,3 ; controls suppression of digits when printing numbers |
655 #DEFINE ignore_digit4 CVT_flags1,4 | 712 #DEFINE ignore_digit4 CVT_flags1,4 ; controls suppression of digits when printing numbers |
656 #DEFINE ignore_digit5 CVT_flags1,5 | 713 #DEFINE ignore_digit5 CVT_flags1,5 ; controls suppression of digits when printing numbers |
657 #DEFINE aux_flag CVT_flags1,6 ; provided for local boolean arguments and storage | 714 ; CVT_flags1,6 ; --- unused |
658 ; CVT_flags1,7 ; --- unused | 715 ; CVT_flags1,7 ; --- unused |
659 | 716 |
660 #DEFINE pre_zero_flag CVT_flags2,0 | 717 #DEFINE pre_zero_flag CVT_flags2,0 |
661 #DEFINE all_zeros_flag CVT_flags2,1 | 718 #DEFINE all_zeros_flag CVT_flags2,1 |
662 #DEFINE DP_done CVT_flags2,2 | 719 #DEFINE DP_done CVT_flags2,2 |
665 #DEFINE leading_zeros CVT_flags2,5 | 722 #DEFINE leading_zeros CVT_flags2,5 |
666 #DEFINE show_last4 CVT_flags2,6 | 723 #DEFINE show_last4 CVT_flags2,6 |
667 #DEFINE neg_flag CVT_flags2,7 ; =1: result is negative | 724 #DEFINE neg_flag CVT_flags2,7 ; =1: result is negative |
668 | 725 |
669 | 726 |
670 ;---- Miscellaneous Flags | 727 ;---- Miscellaneous Flags |
671 #DEFINE ignore_last_edited_gas misc_flags,0 ; =1: ignore last edited gas while cleaning up gas/dil list | 728 #DEFINE ignore_last_edited_gas misc_flags,0 ; =1: ignore last edited gas while cleaning up gas/dil list |
672 #DEFINE copying_dil misc_flags,1 ; =1: copying a diluent | 729 #DEFINE copying_dil misc_flags,1 ; =1: copying a diluent |
673 #DEFINE comm_service_enabled misc_flags,2 ; =1: COMM service mode is enabled | 730 #DEFINE comm_service_mode misc_flags,2 ; =1: service mode (extended command set) is enabled |
674 ; misc_flags,3 ; --- unused | 731 #DEFINE waypoint_reached_first misc_flags,3 ; =1: the first (most outside) waypoint is reached (cave mode) |
675 ; misc_flags,4 ; --- unused | 732 #DEFINE waypoint_reached_last misc_flags,4 ; =1: the last (most inside) waypoint is reached (cave mode) |
676 ; misc_flags,5 ; --- unused | 733 #DEFINE option_repaired misc_flags,5 ; =1: option value was set to default |
677 ; misc_flags,6 ; --- unused | 734 #DEFINE flash_wait misc_flags,6 ; =1: wait for flash write operation to complete |
678 ; misc_flags,7 ; --- unused | 735 #DEFINE aux_flag misc_flags,7 ; local flag, used in various places |
679 | 736 |
680 ;---- HUD Status Byte (stored in access RAM) | 737 ;---- HUD Status Byte (stored in access RAM) |
681 #DEFINE hud_connection_ok hud_status_byte,0 ; =1 HUD connection ok | 738 #DEFINE hud_connection_ok hud_status_byte,0 ; =1 HUD connection ok |
682 ; hud_status_byte,1 ; =1 HUD is calibrated | 739 ; hud_status_byte,1 ; =1 HUD is calibrated |
683 ; hud_status_byte,2 ; =1 HUD battery is low (< 3000 mV) | 740 ; hud_status_byte,2 ; =1 HUD battery is low (< 3000 mV) |
688 ; hud_status_byte,7 ; --- unused in stand-alone HUD | 745 ; hud_status_byte,7 ; --- unused in stand-alone HUD |
689 | 746 |
690 | 747 |
691 ;---------------------------- Macros ------------------------------------ | 748 ;---------------------------- Macros ------------------------------------ |
692 | 749 |
750 | |
751 ; ---- options checking ---- | |
752 | |
693 TSTOSS macro opt_reg ; TeST Option Skip next instruction if Set (not zero) | 753 TSTOSS macro opt_reg ; TeST Option Skip next instruction if Set (not zero) |
694 movff opt_reg,WREG ; Attention: destroys WREG! | 754 movff opt_reg,EEDATA ; Attention: destroys EEDATA! |
695 tstfsz WREG,A ; Attention: must be followed by a plain machine | 755 tstfsz EEDATA,A ; Attention: must be followed by a plain machine |
696 bra $+4 ; command, do not let follow a macro! | 756 bra $+4 ; command, do not let follow a macro! |
697 endm ; | 757 endm ; |
698 | 758 |
699 | |
700 TSTOSC macro opt_reg ; TeST Option Skip next instruction if Clear (zero) | 759 TSTOSC macro opt_reg ; TeST Option Skip next instruction if Clear (zero) |
701 movff opt_reg,WREG ; Attention: destroys WREG! | 760 movff opt_reg,EEDATA ; Attention: destroys EEDATA! |
702 tstfsz WREG,A ; Attention: must be followed by a plain machine | 761 tstfsz EEDATA,A ; Attention: must be followed by a plain machine |
703 endm ; command, do not let follow a macro! | 762 endm ; command, do not let follow a macro! |
704 | 763 |
705 | 764 |
706 CLRI macro int ; CLeaR Integer (version of clrf for 2 byte integers) | 765 ; ---- literal operations ---- |
707 clrf int+0 ; Attention: must be in bank where target variable resides! | 766 |
708 clrf int+1 ; | 767 CLRI macro address ; CLeaR Integer (version of clrf for 2 byte integers) |
768 clrf address+0 ; Attention: must be in bank where target variable resides! | |
769 clrf address+1 ; | |
709 endm ; | 770 endm ; |
710 | 771 |
711 | 772 CLRT macro address ; CLeaR Three byte integer (version of clrf for 3 byte integers) |
712 SETI macro int ; SET Integer (version of setf for 2 byte integers) | 773 clrf address+0 ; Attention: must be in bank where target variable resides! |
713 setf int+0 ; Attention: must be in bank where target variable resides! | 774 clrf address+1 ; |
714 setf int+1 ; | 775 clrf address+2 ; |
715 endm ; | 776 endm ; |
716 | 777 |
717 | 778 CLRR macro address,range ; CLeaR a Range of bytes (version of clrf for 1-256 bytes) |
718 MOVLI macro lit, int ; MOVe Literal to Integer | 779 movlw low(range) ; initialize loop counter |
719 movlw LOW (lit) ; Attention: destroys WREG! | 780 lfsr FSR1,address ; set start address |
720 movwf int+0 ; Attention: must be in bank where target variable resides! | 781 extern memory_clear |
721 movlw HIGH (lit) ; | 782 call memory_clear |
722 movwf int+1 ; | 783 endm |
784 | |
785 SETI macro address ; SET Integer (version of setf for 2 byte integers) | |
786 setf address+0 ; Attention: must be in bank where target variable resides! | |
787 setf address+1 ; | |
723 endm ; | 788 endm ; |
724 | 789 |
725 | 790 MOVLI macro literal,address ; MOVe Literal to Integer |
726 INCI macro int ; INCrement Integer (version of incf for 2 byte integers) | 791 movlw LOW (literal) ; Attention: destroys WREG! |
727 infsnz int+0,F ; Attention: must be in bank where target variable resides! | 792 movwf address+0 ; Attention: must be in bank where target variable resides! |
728 incf int+1,F ; | 793 movlw HIGH (literal) ; |
794 movwf address+1 ; | |
729 endm ; | 795 endm ; |
730 | 796 |
731 | 797 |
732 DECI macro int ; DECrement Integer (version of decf for 2 byte integers) | 798 ; ---- arithetics ---- |
799 | |
800 INCI macro address ; INCrement Integer (version of incf for 2 byte integers) | |
801 infsnz address+0,F ; Attention: must be in bank where target variable resides! | |
802 incf address+1,F ; | |
803 endm ; | |
804 | |
805 DECI macro address ; DECrement Integer (version of decf for 2 byte integers) | |
733 movlw .1 ; Attention: destroys WREG! | 806 movlw .1 ; Attention: destroys WREG! |
734 subwf int+0,F ; Attention: must be in bank where target variable resides! | 807 subwf address+0,F ; Attention: must be in bank where target variable resides! |
735 movlw .0 ; | 808 movlw .0 ; |
736 subwfb int+1,F ; | 809 subwfb address+1,F ; |
737 endm ; | 810 endm ; |
738 | 811 |
739 | 812 ADDLI macro literal, address ; ADD Literal to Integer |
740 ADDLI macro lit, int ; ADD Literal to Integer | 813 movlw LOW (literal) ; Attention: destroys WREG! |
741 movlw LOW (lit) ; Attention: destroys WREG! | 814 addwf address+0,F ; Attention: must be in bank where target variable resides! |
742 addwf int+0,F ; Attention: must be in bank where target variable resides! | 815 movlw HIGH (literal) ; |
743 movlw HIGH (lit) ; | 816 addwfc address+1,F ; |
744 addwfc int+1,F ; | |
745 endm ; | 817 endm ; |
746 | 818 |
747 | 819 SUBLI macro literal, address ; SUBtract Literal from Integer |
748 SUBLI macro lit, int ; SUBtract Literal from Integer | 820 movlw LOW (literal) ; Attention: destroys WREG! |
749 movlw LOW (lit) ; Attention: destroys WREG! | 821 subwf address+0,F ; Attention: must be in bank where target variable resides! |
750 subwf int+0,F ; Attention: must be in bank where target variable resides! | 822 movlw HIGH (literal) ; |
751 movlw HIGH (lit) ; | 823 subwfb address+1,F ; |
752 subwfb int+1,F ; | |
753 endm ; | 824 endm ; |
754 | 825 |
755 | 826 |
756 MOVII macro from, to ; MOVe Integer to Integer (version of movff for 2 byte integers) | 827 ; ---- moves ---- |
757 movff from+0,to+0 ; banksafe | 828 |
758 movff from+1,to+1 ; | 829 MOVCC macro from,to ; MOVe 1 byte Char (actually an alias for movff) |
830 movff from,to | |
831 endm | |
832 | |
833 MOVII macro from,to ; MOVe 2 byte Integer (version of movff for 2 bytes) | |
834 movff from+0,to+0 ; copy 1st byte | |
835 movff from+1,to+1 ; copy 2nd byte | |
759 endm ; | 836 endm ; |
760 | 837 |
761 | 838 MOVTT macro from,to ; MOVe Three byte Integer (version of movff for 3 bytes) |
762 SMOVII macro from, to ; isr-Safe MOVe 2 byte Integer to Integer (version of MOVII for integers updated in ISR) | 839 movff from+0,to+0 ; copy 1st byte |
840 movff from+1,to+1 ; copy 2nd byte | |
841 movff from+2,to+2 ; copy 3rd byte | |
842 endm ; | |
843 | |
844 MOVRR macro from,to,range ; MOVe a Range of bytes (version of movff for 1-256 bytes) | |
845 movlw low(range) ; initialize loop counter | |
846 lfsr FSR1,from ; from | |
847 lfsr FSR2,to ; to | |
848 extern memory_move | |
849 call memory_move | |
850 endm | |
851 | |
852 | |
853 ; ---- ISR-safe moves ---- | |
854 | |
855 SMOVII macro from, to ; isr-Safe MOVe 2 byte Integer (version of MOVII for ISR-safe copying) | |
763 local retry ; | 856 local retry ; |
764 retry: | 857 retry: |
765 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in | 858 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in |
766 movff from+0,to+0 ; copy low byte | 859 movff from+0,to+0 ; copy low byte |
767 movff from+1,to+1 ; copy high byte | 860 movff from+1,to+1 ; copy high byte |
768 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? | 861 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? |
769 bra retry ; YES - retry copy | 862 bra retry ; YES - retry copy |
770 endm ; NO - done | 863 endm ; NO - done |
771 | 864 |
772 | 865 SMOVTT macro from, to ; isr-Safe MOVe Three byte integer (version of MOVTT for ISR-safe copying) |
773 SMOVTT macro from, to ; isr-Safe MOVe Three byte integer to integer (version of MOVII for integers updated in ISR) | |
774 local retry ; | 866 local retry ; |
775 retry: | 867 retry: |
776 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in | 868 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in |
777 movff from+0,to+0 ; copy low byte | 869 movff from+0,to+0 ; copy low byte |
778 movff from+1,to+1 ; copy high byte | 870 movff from+1,to+1 ; copy high byte |
779 movff from+2,to+2 ; copy upper byte | 871 movff from+2,to+2 ; copy upper byte |
780 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? | 872 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? |
781 bra retry ; YES - retry copy | 873 bra retry ; YES - retry copy |
782 endm ; NO - done | 874 endm ; NO - done |
783 | 875 |
784 | 876 SMOVQQ macro from, to ; isr-Safe MOVe Quad byte integer (version of MOVII for ISR-safe copying) |
785 SMOVFF macro from, to ; isr-Safe MOVe Four byte integer to integer (version of MOVII for integers updated in ISR) | |
786 local retry ; | 877 local retry ; |
787 retry: | 878 retry: |
788 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in | 879 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in |
789 movff from+0,to+0 ; copy byte 0 (LSB) | 880 movff from+0,to+0 ; copy byte 0 (LSB) |
790 movff from+1,to+1 ; copy byte 1 | 881 movff from+1,to+1 ; copy byte 1 |
791 movff from+2,to+2 ; copy byte 2 | 882 movff from+2,to+2 ; copy byte 2 |
792 movff from+3,to+3 ; copy byte 3 (MSB) | 883 movff from+3,to+3 ; copy byte 3 (MSB) |
793 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? | 884 btfsc trigger_isr_updates ; did the ISR kicked in since we cleared the flag? |
794 bra retry ; YES - retry copy | 885 bra retry ; YES - retry copy |
795 endm ; NO - done | 886 endm ; NO - done |
796 | |
797 | 887 |
798 SMOVSS macro from, to ; isr-Safe MOVe Six byte integer to integer (version of MOVII for integers updated in ISR) | 888 SMOVSS macro from, to ; isr-Safe MOVe Six byte integer to integer (version of MOVII for integers updated in ISR) |
799 local retry ; | 889 local retry ; |
800 retry: | 890 retry: |
801 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in | 891 bcf trigger_isr_updates ; clear flag, it will be set by the ISR in case it had kicked in |
867 extern simulatormode_depth | 957 extern simulatormode_depth |
868 | 958 |
869 extern hud_status_byte | 959 extern hud_status_byte |
870 extern hud_battery_mv | 960 extern hud_battery_mv |
871 | 961 |
872 endif | 962 endif ; ACCESS_RAM_VARS |
873 | 963 |
874 ;---------------------------- Bank0 NORMAL RAM ------------------------------ | 964 ;---------------------------- Bank0 NORMAL RAM ------------------------------ |
875 isr_backup equ 0x060 ; Alias for "banksel isr_backup" | 965 isr_backup equ 0x060 ; Alias for "banksel isr_backup" |
876 isr_backup udata_ovr isr_backup ; Bank 0 ISR data | 966 isr_backup udata_ovr isr_backup ; Bank 0 ISR data |
877 | 967 |
878 ;---- Backup for general Registers | 968 ;---- Backup for general Registers, used by ISR Routines |
879 PROD_backup res 2 | 969 PROD_backup res 2 |
880 FSR0_backup res 2 | 970 FSR0_backup res 2 |
881 BSR_backup res 1 | 971 BSR_backup res 1 |
882 | 972 |
883 ;---- Multi-Purpose Register for ISR Routines | 973 ;---- Multi-Purpose Registers, used by ISR Routines |
884 isr_mpr res 2 ; used in ms5541.asm and isr.asm | 974 isr_mpr res 2 ; used in ms5541.asm and isr.asm |
885 #DEFINE isr_lo isr_mpr+0 ; | 975 #DEFINE isr_lo isr_mpr+0 ; ... |
886 #DEFINE isr_hi isr_mpr+1 ; | 976 #DEFINE isr_hi isr_mpr+1 ; ... |
977 | |
978 ;---- Multi-Purpose Registers, NOT USED by ISR Routines | |
979 backup_mpr res 2 ; used in rtc.asm | |
980 #DEFINE backup_lo backup_mpr+0 | |
981 #DEFINE backup_hi backup_mpr+1 | |
982 | |
887 | 983 |
888 ;---- Time and Date - Real Time Clock | 984 ;---- Time and Date - Real Time Clock |
889 rtc_year res 1 ; running year | Attention: | 985 rtc_year res 1 ; running year | Attention: |
890 rtc_month res 1 ; running month | do not change | 986 rtc_month res 1 ; running month | do not change |
891 rtc_day res 1 ; running day | the Position of | 987 rtc_day res 1 ; running day | the Position of |
981 analog_counter res 1 ; for averaging | 1077 analog_counter res 1 ; for averaging |
982 analog_sw1 res 1 ; analog value for switch 1 | 1078 analog_sw1 res 1 ; analog value for switch 1 |
983 analog_sw2 res 1 ; analog value for switch 2 | 1079 analog_sw2 res 1 ; analog value for switch 2 |
984 button_polarity res 1 ; 0xFF (both normal), 0x00 (both inverted), 0x01 (left inverted only), 0x02 (right inverted only) | 1080 button_polarity res 1 ; 0xFF (both normal), 0x00 (both inverted), 0x01 (left inverted only), 0x02 (right inverted only) |
985 | 1081 |
1082 | |
986 ;--- resettable min and max Depth Option | 1083 ;--- resettable min and max Depth Option |
987 IFDEF _min_depth_option | 1084 IFDEF _min_depth_option |
988 pressure_rel_min_trip res 2 ; resettable minimum relative pressure | 1085 pressure_rel_min_trip res 2 ; resettable minimum relative pressure |
989 pressure_rel_max_trip res 2 ; resettable maximum relative pressure | 1086 pressure_rel_max_trip res 2 ; resettable maximum relative pressure |
990 ENDIF | 1087 ENDIF |
991 | 1088 |
992 ; 141 byte used, 19 byte free | 1089 ; 143 byte used, 17 byte free |
993 | 1090 |
994 | 1091 |
995 ;---------------------------- Common DATA ------------------------------------ | 1092 ;---------------------------- Common DATA ------------------------------------ |
996 common equ 0x100 ; Alias for "banksel common" | 1093 common equ 0x100 ; Alias for "banksel common" |
997 common udata_ovr common ; Bank 1 general variables | 1094 common udata_ovr common ; Bank 1 general variables |
1008 | 1105 |
1009 ;---- Flags - Menu System (2 byte) | 1106 ;---- Flags - Menu System (2 byte) |
1010 MS_flags_control res 1 ; menu system - control | 1107 MS_flags_control res 1 ; menu system - control |
1011 MS_flags_imprint res 1 ; menu system - data imprinting | 1108 MS_flags_imprint res 1 ; menu system - data imprinting |
1012 | 1109 |
1013 ;---- Flags - Dive Mode (7 byte) | 1110 ;---- Flags - Dive Mode (9 byte) |
1014 DM_flags_state res 1 ; dive mode - dive states | 1111 DM_flags_state res 1 ; dive mode - dive states |
1015 DM_flags_sensor res 1 ; dive mode - O2 sensors | 1112 DM_flags_sensor res 1 ; dive mode - O2 sensors |
1016 DM_flags_request res 1 ; dive mode - user requests | 1113 DM_flags_request res 1 ; dive mode - user requests / general |
1017 DM_flags_event res 1 ; dive mode - data recording events | 1114 DM_flags_event res 1 ; dive mode - data recording events |
1018 DM_flags_layout1 res 1 ; dive mode - display control / layout (1) | 1115 DM_flags_layout1 res 1 ; dive mode - display control / layout (1) |
1019 DM_flags_layout2 res 1 ; dive mode - display control / layout (2) | 1116 DM_flags_layout2 res 1 ; dive mode - display control / layout (2) |
1117 DM_flags_layout3 res 1 ; dive mode - display control / layout (3) | |
1020 DM_flags_message res 1 ; dive mode - display control / messages | 1118 DM_flags_message res 1 ; dive mode - display control / messages |
1021 DM_flags_gas_dil res 1 ; dive mode - display control / gas, diluent | 1119 DM_flags_gas_dil res 1 ; dive mode - display control / gas, diluent |
1022 | 1120 |
1023 ;---- Miscellaneous Flags (1 byte) | 1121 ;---- Miscellaneous Flags (1 byte) |
1024 misc_flags res 1 | 1122 misc_flags res 1 |
1046 xC res 4 | 1144 xC res 4 |
1047 sub_a res 2 | 1145 sub_a res 2 |
1048 sub_b res 2 | 1146 sub_b res 2 |
1049 sub_c res 2 | 1147 sub_c res 2 |
1050 | 1148 |
1051 ;---- Menu System and Views (4 byte) | 1149 ;---- Menu System and Views (5 byte) |
1052 menu_pos_cur res 1 ; current position in main menu | 1150 menu_pos_cur res 1 ; current position in main menu |
1053 menu_pos_max res 1 ; highest position in main menu | 1151 menu_pos_max res 1 ; highest position in main menu |
1054 active_premenu res 1 ; currently shown pre-menu (0: none) | 1152 active_premenu res 1 ; currently shown pre-menu (0: none) |
1055 active_customview res 1 ; currently shown custom view | 1153 active_customview res 1 ; currently shown custom view |
1154 backup_customview res 1 ; previously shown custom view | |
1056 | 1155 |
1057 ;---- Miscellaneous (6 byte) | 1156 ;---- Miscellaneous (6 byte) |
1058 batt_voltage res 2 ; battery voltage in mV (no ISR involved) | 1157 batt_voltage res 2 ; battery voltage in mV (no ISR involved) |
1059 batt_percent res 1 ; battery in percent (1-100%) | 1158 batt_percent res 1 ; battery in percent (1-100%) |
1060 message_counter res 1 ; counts amount of messages | 1159 message_counter res 1 ; counts amount of messages |
1061 message_page res 1 ; current message page number | 1160 message_page res 1 ; current message page number |
1062 pairing_slot res 1 ; slot number, used in transmitter pairing | 1161 pairing_slot res 1 ; slot number, used in transmitter pairing |
1063 | 1162 |
1064 ;---- Dive Mode / all modes (25 byte) | 1163 ;---- Dive Mode / all modes (26 byte) |
1065 divesecs_avg_trip res 2 ; time accumulator for the resettable average depth & stopwatch | 1164 divesecs_avg_trip res 2 ; time accumulator for the resettable average depth & stopwatch |
1066 divesecs_avg_total res 2 ; time accumulator for the total dive average depth | 1165 divesecs_avg_total res 2 ; time accumulator for the total dive average depth |
1067 pressure_rel_avg_trip res 2 ; calculated resettable average depth | 1166 pressure_rel_avg_trip res 2 ; calculated resettable average depth |
1068 pressure_rel_avg_total res 2 ; calculated total dive average depth | 1167 pressure_rel_avg_total res 2 ; calculated total dive average depth |
1069 pressure_rel_cur_cached res 2 ; cached current relative pressure | 1168 pressure_rel_cur_cached res 2 ; cached current relative pressure |
1080 IFDEF _ccr_pscr | 1179 IFDEF _ccr_pscr |
1081 best_dil_number res 1 ; number of the "best dil": 0= none found, 1-5= dils 1-5, 255= not computed | 1180 best_dil_number res 1 ; number of the "best dil": 0= none found, 1-5= dils 1-5, 255= not computed |
1082 active_dil res 1 ; the currently used diluent (1-5) | 1181 active_dil res 1 ; the currently used diluent (1-5) |
1083 ENDIF | 1182 ENDIF |
1084 | 1183 |
1184 IFDEF _cave_mode | |
1185 DM_flags_cavereq res 1 ; dive mode - user requests / cave mode | |
1186 backtrack_deltatime res 1 ; time elapsed since last depth recording in seconds | |
1187 backtrack_waypoint_num res 1 ; current waypoint number | |
1188 backtrack_waypoint_turn res 1 ; waypoint number of the turn point | |
1189 ENDIF | |
1190 | |
1085 ;---- Dive Mode / apnoe mode (2 byte) | 1191 ;---- Dive Mode / apnoe mode (2 byte) |
1086 apnoe_max_pressure res 2 ; max depth over all dives in the series | 1192 apnoe_max_pressure res 2 ; max depth over all dives in the series |
1087 | 1193 |
1088 ;---- Gas 6 Data (2 byte) | 1194 ;---- Gas 6 Data (2 byte) |
1089 gas6_O2_ratio res 1 ; gas 6 O2 ratio | 1195 gas6_O2_ratio res 1 ; gas 6 O2 ratio |
1095 alarm_type res 1 ; | 1201 alarm_type res 1 ; |
1096 event_byte1 res 1 ; | 1202 event_byte1 res 1 ; |
1097 event_byte2 res 1 ; | 1203 event_byte2 res 1 ; |
1098 CNS_start res 2 ; CNS value at beginning of dive | 1204 CNS_start res 2 ; CNS value at beginning of dive |
1099 | 1205 |
1100 ;---- External Flash (13 byte) | 1206 ;---- External Flash (14 byte) |
1101 ext_flash_rw res 1 ; transfer register for data read / write | |
1102 ext_flash_address res 3 ; 24 bit address | 1207 ext_flash_address res 3 ; 24 bit address |
1208 ext_flash_length_counter res 3 ; 24 bit length counter | |
1103 ext_flash_log_pointer res 3 ; 24 bit address for logbook profile storing | 1209 ext_flash_log_pointer res 3 ; 24 bit address for logbook profile storing |
1104 ext_flash_end_pointer res 3 ; 24 bit address for logbook profile storing | 1210 ext_flash_end_pointer res 3 ; 24 bit address for logbook profile storing |
1105 ext_flash_dive_counter res 3 ; 24 bit counter for dive length (increased in write_byte_ext_flash_plus) | 1211 ext_flash_rw res 1 ; transfer register for data read / write |
1212 ext_flash_rollover_threshold res 1 ; rollover threshold for address increment operations | |
1106 | 1213 |
1107 ;---- Battery Management (12 byte) | 1214 ;---- Battery Management (12 byte) |
1108 battery_capacity_internal res 2 ; for internal battery gauging | 1215 battery_capacity_internal res 2 ; for internal battery gauging |
1109 battery_capacity res 2 ; for battery gauge IC | 1216 battery_capacity res 2 ; for battery gauge IC |
1110 battery_offset res 2 ; for battery gauge IC | 1217 battery_offset res 2 ; for battery gauge IC |
1147 | 1254 |
1148 ;---- comm.asm | 1255 ;---- comm.asm |
1149 comm_timeout_timer res 1 ; timeout for communication | 1256 comm_timeout_timer res 1 ; timeout for communication |
1150 | 1257 |
1151 ;---- eeprom_rs232.asm | 1258 ;---- eeprom_rs232.asm |
1152 uart_timeout_timer res 3 ; RS232 receive timeout counter | 1259 eeprom_loop res 1 ; loop counter (actually used in flash and serial, too) |
1260 rx_timoeut_tmr5h_load res 1 ; TMR5H load value for RS232 RX timeout | |
1153 | 1261 |
1154 ;---- i2c.asm | 1262 ;---- i2c.asm |
1155 i2c_temp1 res 1 ; temporary data | 1263 i2c_temp1 res 1 ; temporary data |
1156 i2c_temp2 res 1 ; temporary data | 1264 i2c_temp2 res 1 ; temporary data |
1157 | 1265 |
1172 menu_center res 1 ; centering for line menu | 1280 menu_center res 1 ; centering for line menu |
1173 proc_item res 3 ; address of the current procedure | 1281 proc_item res 3 ; address of the current procedure |
1174 text_item res 2 ; address of the current text | 1282 text_item res 2 ; address of the current text |
1175 | 1283 |
1176 ;---- options.asm | 1284 ;---- options.asm |
1177 opt_type res 1 ; option type | 1285 #DEFINE opt_definiton_bytes .12 ; | Attention: do not change the relative position of these vars! |
1178 opt_default res 1 ; default value | 1286 opt_type res 1 ; | option type |
1179 opt_inc res 1 ; also used for default+1 (string) and enum low | 1287 opt_serial res 1 ; | index used for option read/write via RS232 |
1180 opt_min res 1 ; minimum value, also used for enum high | 1288 opt_inc res 1 ; | increment value, also used for enum low and string default+1 |
1181 opt_max res 1 ; maximum value | 1289 opt_min res 1 ; | minimum value, also used for enum high |
1182 opt_unit res 2 ; multi-lingual unit text | 1290 opt_max res 1 ; | maximum value |
1183 opt_eeprom res 1 ; storage position in EEPROM | 1291 opt_default res 1 ; | default value |
1184 opt_backup_tbl res 3 ; buffer for table pointer | 1292 opt_unit res 2 ; | pointer to multi-lingual unit text |
1293 opt_memory res 2 ; | pointer to memory position | |
1294 opt_eeprom_index res 1 ; | pointer to EEPROM position (index) | |
1295 opt_eeprom_bank res 1 ; | pointer to EEPROM position (bank) | |
1296 opt_end_token res 1 ; | =0xFF: end of table reached (does not count into opt_definiton_bytes) | |
1297 | |
1185 | 1298 |
1186 ;---- tft.asm | 1299 ;---- tft.asm |
1187 tft_save_top res 1 | 1300 tft_save_top res 1 |
1188 tft_save_height res 1 | 1301 tft_save_height res 1 |
1189 tft_save_left res 1 | 1302 tft_save_left res 1 |
1203 | 1316 |
1204 ;---- wait.asm | 1317 ;---- wait.asm |
1205 wait_counter res 1 | 1318 wait_counter res 1 |
1206 | 1319 |
1207 | 1320 |
1208 ; 193 byte used, 15 byte free (208 byte total) | 1321 ; 201 byte used, 7 byte free (208 byte total) |
1209 | 1322 |
1210 | 1323 |
1211 ;============================ LOCAL DATA ====================================== | 1324 ;============================ LOCAL DATA ====================================== |
1212 ; Space for various overlayed local data from top-level applications, | 1325 ; Space for various overlayed local data from top-level applications, |
1213 ; i.e. applications that never run in parallel to each other | 1326 ; i.e. applications that never run in parallel to each other |
1250 start_mins res 1 ; minute | to each other! | 1363 start_mins res 1 ; minute | to each other! |
1251 start_secs res 1 ; second, not used, for code commonality | | 1364 start_secs res 1 ; second, not used, for code commonality | |
1252 | 1365 |
1253 supersat_start res 1 ; leading tissue supersaturation at beginning of the dive | 1366 supersat_start res 1 ; leading tissue supersaturation at beginning of the dive |
1254 | 1367 |
1255 ;---- Backup for lost Gas Function (10 byte) | |
1256 opt_gas_type_backup res 5 ; 0=Disabled, 1=First, 2=Travel, 3=Deco | ATTENTION: | |
1257 opt_dil_type_backup res 5 ; 0=Disabled, 1=First, 2=Normal | (as above) | |
1258 | |
1259 ;---- O2 Sensors (9 byte, updated by ISR when sensors are connected via datalink) | 1368 ;---- O2 Sensors (9 byte, updated by ISR when sensors are connected via datalink) |
1260 IFDEF _external_sensor | 1369 IFDEF _external_sensor |
1261 sensor1_mv res 2 ; sensor 1 voltage in 0.1 mV steps | 1370 sensor1_mv res 2 ; sensor 1 voltage in 0.1 mV steps |
1262 sensor2_mv res 2 ; sensor 2 voltage in 0.1 mV steps | 1371 sensor2_mv res 2 ; sensor 2 voltage in 0.1 mV steps |
1263 sensor3_mv res 2 ; sensor 3 voltage in 0.1 mV steps | 1372 sensor3_mv res 2 ; sensor 3 voltage in 0.1 mV steps |
1303 compass_DY_f res 2 ; filtered Data | 1412 compass_DY_f res 2 ; filtered Data |
1304 compass_DZ_f res 2 ; filtered Data | 1413 compass_DZ_f res 2 ; filtered Data |
1305 accel_DX_f res 2 ; filtered Data | 1414 accel_DX_f res 2 ; filtered Data |
1306 accel_DY_f res 2 ; filtered Data | 1415 accel_DY_f res 2 ; filtered Data |
1307 accel_DZ_f res 2 ; filtered Data | 1416 accel_DZ_f res 2 ; filtered Data |
1308 compass_CX_f res 2 ; calibration data | 1417 compass_CX_f res 2 ; calibration data (stored via options system) |
1309 compass_CY_f res 2 ; calibration data | 1418 compass_CY_f res 2 ; calibration data (stored via options system) |
1310 compass_CZ_f res 2 ; calibration data | 1419 compass_CZ_f res 2 ; calibration data (stored via options system) |
1311 | 1420 |
1312 ;---- temporary Data for Q15 Arithmetics (7 byte, compass_ops.asm, called from C) | 1421 ;---- temporary Data for Q15 Arithmetics (7 byte, compass_ops.asm, called from C) |
1313 compass_a res 2 ; | 1422 compass_a res 2 ; |
1314 compass_b res 2 ; | 1423 compass_b res 2 ; |
1315 compass_r res 3 ; | 1424 compass_r res 3 ; |
1334 time_last_1st res 2 ; last pressure reading time in seconds | | 1443 time_last_1st res 2 ; last pressure reading time in seconds | |
1335 time_last_2nd res 2 ; last pressure reading time in seconds | | 1444 time_last_2nd res 2 ; last pressure reading time in seconds | |
1336 ENDIF | 1445 ENDIF |
1337 | 1446 |
1338 | 1447 |
1339 ; 166 byte used, 90 byte free | 1448 ; 156 byte used, 100 byte free |
1340 | 1449 |
1341 | 1450 |
1342 ;----------------------- Bank 2 General Purpose Buffer ------------------------- | 1451 ;----------------------- Bank 2 General Purpose Buffer 1 ----------------------- |
1343 ; Reserved for general purpose buffer (strings, images, etc). | 1452 ; general purpose buffer no.1 |
1344 ; NOTE: Needs to be aligned with a bank (LOW(buffer)==0). | 1453 ; |
1454 ; NOTE: needs to be aligned with a bank (low(buffer)=0) | |
1345 | 1455 |
1346 buffer udata_ovr 0x200 | 1456 buffer udata_ovr 0x200 |
1347 | 1457 buffer res .256 ; buffer 1 - string buffer, etc. |
1348 buffer res .256 ; used for string assembly / display output | 1458 |
1459 | |
1460 ;----------------------- Bank 11 General Purpose Buffer 2 ---------------------- | |
1461 ; general purpose buffer no. 2 | |
1462 ; | |
1463 ; NOTE: needs to be aligned with a bank (low(buffer)=0) | |
1464 | |
1465 ; Remark: this memory block is already allocated in shared_definitions.h for | |
1466 ; use while in dive mode, so we need to make a hard reference here | |
1467 ; | |
1468 ;buffer2 udata_ovr 0xB00 | |
1469 ;buffer2 res .256 ; buffer 2 - backtracking, flash mirror, etc. | |
1470 | |
1471 #DEFINE buffer2 0xB00 | |
1349 | 1472 |
1350 | 1473 |
1351 ;---------------------- Bank 14 Options Table --------------------------------- | 1474 ;---------------------- Bank 14 Options Table --------------------------------- |
1352 opt_table equ 0xE00 ; Alias for "banksel opt_table" | 1475 opt_table equ 0xE00 ; Alias for "banksel opt_table" |
1353 opt_table udata_ovr opt_table ; Bank 14 options table | 1476 opt_table udata_ovr opt_table ; Bank 14 options table |
1373 ;---- custom Text | 1496 ;---- custom Text |
1374 #DEFINE opt_name_length .60 ; custom text string 5 rows with 12 chars | 1497 #DEFINE opt_name_length .60 ; custom text string 5 rows with 12 chars |
1375 opt_name res opt_name_length | 1498 opt_name res opt_name_length |
1376 | 1499 |
1377 ;---- various other Settings | 1500 ;---- various other Settings |
1501 opt_fw_version_major res 1 ; firmware version, major | use read-only! | |
1502 opt_fw_version_minor res 1 ; firmware version, minor | | |
1503 opt_fw_version_beta res 1 ; firmware version, beta | | |
1378 opt_surface_interval res 1 ; surface interval, used by deco calculator | 1504 opt_surface_interval res 1 ; surface interval, used by deco calculator |
1379 opt_brightness res 1 ; =0: Eco, =1:Medium, =2:Full | 1505 opt_brightness res 1 ; =0: Eco, =1:Medium, =2:Full |
1380 opt_salinity res 1 ; 0-5% | 1506 opt_salinity res 1 ; 0-5% |
1381 opt_language res 1 ; current language: 0=EN, 1=DE, 2=FR, 3=SP | 1507 opt_language res 1 ; current language: 0=EN, 1=DE, 2=FR, 3=SP |
1382 opt_units res 1 ; 0:m/°C, 1:ft/°F | 1508 opt_units res 1 ; 0:m/°C, 1:ft/°F |
1389 opt_enable_aGF res 1 ; =1: aGF can be selected underwater | 1515 opt_enable_aGF res 1 ; =1: aGF can be selected underwater |
1390 opt_compass_gain res 1 ; 0-7 (230LSB/Gauss to 1370LSB/Gaus) | 1516 opt_compass_gain res 1 ; 0-7 (230LSB/Gauss to 1370LSB/Gaus) |
1391 opt_sampling_rate res 1 ; =1: 10s, =0: 2s | 1517 opt_sampling_rate res 1 ; =1: 10s, =0: 2s |
1392 opt_dive_color_scheme res 1 ; 0-3 | 1518 opt_dive_color_scheme res 1 ; 0-3 |
1393 opt_pressure_adjust res 1 ; SIGNED char (two's complement), -20/+20mbar max. | 1519 opt_pressure_adjust res 1 ; SIGNED char (two's complement), -20/+20mbar max. |
1394 opt_enable_safetystop res 1 ; =1: a safety stop is shown | 1520 opt_safetystop res 1 ; =1: a safety stop is shown |
1395 opt_calibration_O2_ratio res 1 ; %O2 of calibration gas | 1521 opt_calibration_O2_ratio res 1 ; %O2 of calibration gas |
1396 opt_x_s1 res 2 ; calibration factor (Not stored in EEPROM) | 1522 opt_x_s1 res 2 ; calibration factor (Not stored in EEPROM) |
1397 opt_x_s2 res 2 ; calibration factor (Not stored in EEPROM) | 1523 opt_x_s2 res 2 ; calibration factor (Not stored in EEPROM) |
1398 opt_x_s3 res 2 ; calibration factor (Not stored in EEPROM) | 1524 opt_x_s3 res 2 ; calibration factor (Not stored in EEPROM) |
1399 opt_sensor_fallback res 1 ; NOT USED ANY MORE, KEPT FOR COMPATIBILITY WITH EEPROM IMAGE | 1525 opt_sensor_fallback res 1 ; NOT USED ANY MORE, KEPT FOR COMPATIBILITY WITH EEPROM IMAGE |
1400 opt_flip_screen res 1 ; =1: flip the screen | 1526 opt_flip_screen res 1 ; =1: flip the screen |
1401 opt_cR_button_left res 1 ; left button sensitivity (cR hardware) | 1527 opt_cR_button_left res 1 ; left button sensitivity (cR hardware) |
1402 opt_cR_button_right res 1 ; right button sensitivity (cR hardware) | 1528 opt_cR_button_right res 1 ; right button sensitivity (cR hardware) |
1403 opt_modwarning res 1 ; =1:do a red blinking warning, =0:default behavior | 1529 opt_depth_warn res 1 ; =1:do a red blinking warning, =0:default behavior |
1404 opt_vsitextv2 res 1 ; =1:use the depth dependent ascend rate limits | 1530 opt_vsitext res 1 ; =1:use the depth dependent ascend rate limits |
1405 opt_vsigraph res 1 ; =1:draw the graphical VSI bar | 1531 opt_vsigraph res 1 ; =1:draw the graphical VSI bar |
1406 opt_showppo2 res 1 ; =1:always show the ppO2 value in the warning position | 1532 opt_showppo2 res 1 ; =1:always show the ppO2 value in the warning position |
1407 opt_temperature_adjust res 1 ; SIGNED char (two's complement), -2.0/+2.0 °C max. | 1533 opt_temperature_adjust res 1 ; SIGNED char (two's complement), -2.0/+2.0 °C max. |
1408 opt_safety_stop_length res 1 ; [s] | 1534 opt_safety_stop_length res 1 ; [s] |
1409 opt_safety_stop_start res 1 ; [cbar] | 1535 opt_safety_stop_start res 1 ; [cbar] |
1410 opt_safety_stop_end res 1 ; [cbar] | 1536 opt_safety_stop_end res 1 ; [cbar] |
1411 opt_safety_stop_reset res 1 ; [cbar] | 1537 opt_safety_stop_reset res 1 ; [cbar] |
1412 opt_diveTimeout res 1 ; timeout for dive mode [min] | 1538 opt_diveTimeout res 1 ; timeout for dive mode [min] |
1413 opt_sim_setpoint_number res 1 ; setpoint to use for deco calculation | 1539 opt_sim_setpoint_number res 1 ; setpoint to use for deco calculation |
1414 opt_calc_asc_gasvolume res 1 ; calculate OC gas volume needs for ascent | 1540 opt_calc_gasvolume res 1 ; calculate OC gas volume needs for ascent |
1415 opt_sim_use_aGF res 1 ; =0: use GF, =1: use aGF for deco calculation | 1541 opt_sim_use_aGF res 1 ; =0: use GF, =1: use aGF for deco calculation |
1416 opt_enable_IBCD res 1 ; enable IBCD warning | 1542 opt_enable_IBCD res 1 ; enable IBCD warning |
1417 opt_sat_multiplier_gf res 1 ; Buhlmann safety factor for GF deco | 1543 opt_sat_multiplier_gf res 1 ; Buhlmann safety factor for GF deco |
1418 opt_desat_multiplier_gf res 1 ; Buhlmann safety factor for GF deco | 1544 opt_desat_multiplier_gf res 1 ; Buhlmann safety factor for GF deco |
1419 opt_sat_multiplier_non_gf res 1 ; Buhlmann safety factor for NON-GF deco | 1545 opt_sat_multiplier_non_gf res 1 ; Buhlmann safety factor for NON-GF deco |
1420 opt_desat_multiplier_non_gf res 1 ; Buhlmann safety factor for NON-GF deco | 1546 opt_desat_multiplier_non_gf res 1 ; Buhlmann safety factor for NON-GF deco |
1421 opt_ZfactorUse res 1 ; =1: figure in compression factor Z when converting gas volume <-> gas pressure | |
1422 opt_ZfactorTemp res 1 ; temperature setpoint for compression factor Z | |
1423 opt_2ndDepthDisp res 1 ; =1: show average depth instead of max depth | 1547 opt_2ndDepthDisp res 1 ; =1: show average depth instead of max depth |
1424 opt_max_depth res 1 ; depth at which a warning will be given | 1548 opt_max_depth res 1 ; depth at which a warning will be given |
1425 opt_store_apnoe_dive res 1 ; =1: store dives in apnoe mode into logbook | 1549 opt_store_apnoe res 1 ; =1: store dives in apnoe mode into logbook |
1426 opt_tissue_graphics res 1 ; =0: show N2 and He pressures, =1: show pressures and saturations | 1550 opt_tissue_graphics res 1 ; =0: show N2 and He pressures, =1: show pressures and saturations |
1427 opt_logoffset_step res 1 ; step size when adjusting log offset | 1551 opt_logoffset_step res 1 ; step size when adjusting log offset |
1428 opt_layout res 1 ; initial layout of dive mode screen | 1552 opt_layout res 1 ; initial layout of dive mode screen |
1429 opt_extended_stops res 1 ; =1: place gas switches also below 1st stop depth | 1553 opt_ext_stops res 1 ; =1: place gas switches also below 1st stop depth |
1554 opt_s8_mode res 1 ; S8 mode - analog / digital | |
1555 opt_gas_contingency_sim res 1 ; =1: deco calculator: switch to alternative gas if best gas is used up | |
1556 opt_gas_contingency_dive res 1 ; =1: real dive mode: switch to alternative gas if best gas is used up | |
1557 opt_cave_mode res 1 ; =1: cave mode switched on | |
1430 | 1558 |
1431 ;---- RX Function Settings | 1559 ;---- RX Function Settings |
1432 opt_transmitter_id_1 res 2 ; 16 bit transmitter ID for Gas 1 | 1560 opt_transmitter_id_1 res 2 ; 16 bit transmitter ID for Gas 1 |
1433 opt_transmitter_id_2 res 2 ; 16 bit transmitter ID for Gas 2 | 1561 opt_transmitter_id_2 res 2 ; 16 bit transmitter ID for Gas 2 |
1434 opt_transmitter_id_3 res 2 ; 16 bit transmitter ID for Gas 3 | 1562 opt_transmitter_id_3 res 2 ; 16 bit transmitter ID for Gas 3 |
1442 opt_TR_mode res 1 ; TR functions - mode | 1570 opt_TR_mode res 1 ; TR functions - mode |
1443 opt_TR_1st_pres res 1 ; TR functions - 1st pressure assignment | 1571 opt_TR_1st_pres res 1 ; TR functions - 1st pressure assignment |
1444 opt_TR_2nd_pres res 1 ; TR functions - 2nd pressure assignment | 1572 opt_TR_2nd_pres res 1 ; TR functions - 2nd pressure assignment |
1445 opt_TR_Bail_pres res 1 ; TR functions - bailout pressure assignment | 1573 opt_TR_Bail_pres res 1 ; TR functions - bailout pressure assignment |
1446 | 1574 |
1447 ; ==> 187 bytes used - 57 bytes free (244 usable bytes only in bank 14 as the upper 12 | 1575 ; ==> 190 bytes used - 54 bytes free (244 usable bytes only in bank 14 as the upper 12 |
1448 ; bytes may be used for SFRs on some PIC devices) | 1576 ; bytes are reserved for special function registers) |
1449 | 1577 |
1450 ;----------------------------------------------------------------------------- | 1578 ;----------------------------------------------------------------------------- |