CODE
; mptest.asm
title “mptest.asm”
list p=18f452, f=inhx32
#include <p18f452.inc>
stores equ h’00’ ; the value of stores
storee equ h’01’
count equ d’04’
org 0x00 ; reset vector address
goto start
org 0x1C ; Program start address
start
movlw count; move count as a number to WREG
movwf count; move the data in WREG to f Register count
movlw stores
movwf storee
test
movlw stores
movwf stores
movf storee, w; move the data in f Register store to WREG
incf stores, f; increase the data in f Register stores
incf storee, f
decfsz count; decrease the data in f Register count. If it
goto test ; equal to 0, jump next instruction
loop
goto loop
end
Hey Ive done this code in the mplab programme but I dont know how to find the values stored in count, stores and storee. Could someone please help me find the values. All help is much appreciated. Thanks
This post has been edited by NickDMax: 3 Jun, 2008 - 07:35 AM