diff code_part1/OSTC_code_asm_part1/simulator.asm @ 56:0338aac9a267

surfacemode
author heinrichsweikamp
date Wed, 04 Aug 2010 18:23:50 +0200
parents a63d63a8612e
children 2ff1b30b1bdf
line wrap: on
line diff
--- a/code_part1/OSTC_code_asm_part1/simulator.asm	Tue Aug 03 14:46:52 2010 +0200
+++ b/code_part1/OSTC_code_asm_part1/simulator.asm	Wed Aug 04 18:23:50 2010 +0200
@@ -206,10 +206,10 @@
 	clrf	xB+1
 	call	mult16x16	;xA*xB=xC			; Depth in m*100
 
-	movlw	LOW		d'1000'
+	movf	amb_pressure+0,W
 	addwf	xC+0,F
-	movlw	HIGH	d'1000'
-	addwfc	xC+1,F							; Add 1000mBar
+	movf	amb_pressure+1,W
+	addwfc	xC+1,F							; Add ambient pressure
 	
 	movff	xC+0,sim_pressure+0
 	movff	xC+1,sim_pressure+1