Truncated match.
PICList
Thread
'How to know address assigned by "CBLOCK"'
1996\11\30@152714
by
Brooke
Hi:
In the following snipit how can I tell what address the CBLOCK
directive assigned to the "month". Currently I compile, look at
the listing, assign a value at label add_mo. Surley there is a
better way. Any ideas?
Thanks,
Brooke
lblm
cblock
month
day
yrmsb, yrlsb
hour
min
sec
endc
add_mo equ 0x16
movlw add_mo ; set up FSR with starting RAM address
movwf FSR ;
storedata
call uartrx ; Get a char from GPS
movf CHARBUF,W ; place into W reg
movwf INDF ; move data to RAM @ FSR address
incf FSR,F ; increment FSR to point to next address
movf FSR,W ; move FSR into W for done test
sublw add_mo+7 ; last ram location
btfss STATUS,Z ; done?
goto storedata ; loop untill 7 bytes read
1996\11\30@154545
by
fastfwd
Brooke <spam_OUTPICLISTTakeThisOuT
MITVMA.MIT.EDU> wrote:
> In the following snipit how can I tell what address the CBLOCK
> directive assigned to the "month". Currently I compile, look at the
> listing, assign a value at label add_mo. Surley there is a better
> way. Any ideas?
>
> lblm
> cblock
> month
> day
> yrmsb, yrlsb
> hour
> min
> sec
> endc
> add_mo equ 0x16
> movlw add_mo ; set up FSR with starting RAM
> movwf FSR ; address
Brooke:
You have two choices here:
1. Don't use the "add_mo" symbol AT ALL; you can just as easily
use "month".
or
2. Define "add_mo" as follows:
add_mo equ month
-Andy
=== Andrew Warren - .....fastfwdKILLspam
@spam@ix.netcom.com ===
=== Fast Forward Engineering - Vista, California ===
=== ===
=== Did the information in this post help you? Consider ===
=== contributing to the PICLIST Fund. Details are at: ===
=== http://www.geocities.com/SiliconValley/2499/fund.html ===
More... (looser matching)
- Last day of these posts
- In 1996
, 1997 only
- Today
- New search...