comparison code_part1/OSTC_code_asm_part1/simulator.asm @ 31:2b52a4a7dce6

preparations for new deco code...
author heinrichsweikamp
date Sun, 23 May 2010 22:13:25 +0200
parents 73014f788032
children a776039bda63
comparison
equal deleted inserted replaced
30:943dc3336f48 31:2b52a4a7dce6
237 WIN_INVERT .1 237 WIN_INVERT .1
238 DISPLAYTEXT .12 ;" Wait.." 238 DISPLAYTEXT .12 ;" Wait.."
239 WIN_INVERT .0 239 WIN_INVERT .0
240 240
241 simulator_calc_deco_loop1: 241 simulator_calc_deco_loop1:
242 movlw d'30'
243 movwf logbook_temp3 ; 30x/Minute
244 call PLED_simulator_data 242 call PLED_simulator_data
245 243
246 ; movlw .011 244 ; movlw .011
247 ; call PLED_SetColumn 245 ; call PLED_SetColumn
248 ; movlw .009 246 ; movlw .009
258 256
259 257
260 simulator_calc_deco_loop2: 258 simulator_calc_deco_loop2:
261 btg LED_red 259 btg LED_red
262 260
261 movlw d'1'
262 movff WREG,char_I_step_is_1min ; 1 minute mode
263
263 call divemode_check_decogases ; Checks for decogases and sets the gases 264 call divemode_check_decogases ; Checks for decogases and sets the gases
264 call divemode_prepare_flags_for_deco 265 call divemode_prepare_flags_for_deco
265 266
266 call deco_main_calc_hauptroutine ; calc_tissue 267 call deco_main_calc_hauptroutine ; calc_tissue
267 movlb b'00000001' ; rambank 1 selected 268 movlb b'00000001' ; rambank 1 selected
268 ostc_debug 'C' ; Sends debug-information to screen if debugmode active 269 ostc_debug 'C' ; Sends debug-information to screen if debugmode active
269 270
270 decfsz logbook_temp3,F
271 bra simulator_calc_deco_loop2
272 decfsz logbook_temp1,F 271 decfsz logbook_temp1,F
273 bra simulator_calc_deco_loop1 272 bra simulator_calc_deco_loop1
274 273
275 movff char_O_deco_status,deco_status ; 274 movff char_O_deco_status,deco_status ;
276 tstfsz deco_status ; deco_status=0 if decompression calculation done 275 tstfsz deco_status ; deco_status=0 if decompression calculation done
293 movlw d'1' 292 movlw d'1'
294 movwf logbook_temp1 ; Bottom time>0! 293 movwf logbook_temp1 ; Bottom time>0!
295 294
296 movlw d'5' ; Pre-Set Cursor to "Show Decoplan" 295 movlw d'5' ; Pre-Set Cursor to "Show Decoplan"
297 movwf menupos 296 movwf menupos
297
298 movlw d'0'
299 movff WREG,char_I_step_is_1min ; 2 second deco mode
300
298 bra menu_simulator1 ; Done. 301 bra menu_simulator1 ; Done.
299 302
300 simulator_calc_deco2: 303 simulator_calc_deco2:
304 movlw d'0'
305 movff WREG,char_I_step_is_1min ; 2 second deco mode
306
301 call divemode_check_decogases ; Checks for decogases and sets the gases 307 call divemode_check_decogases ; Checks for decogases and sets the gases
302 call divemode_prepare_flags_for_deco 308 call divemode_prepare_flags_for_deco
303 309
304 call deco_main_calc_hauptroutine ; calc_tissue 310 call deco_main_calc_hauptroutine ; calc_tissue
305 movlb b'00000001' ; rambank 1 selected 311 movlb b'00000001' ; rambank 1 selected