CLRW command in PIC Assembly language

Status
Not open for further replies.

creative_35

Full Member level 1
Joined
Apr 10, 2006
Messages
95
Helped
9
Reputation
18
Reaction score
3
Trophy points
1,288
Location
Under Mango Tree
Activity points
2,032
Hi friends
I am confused with the clrw command in pic assembly language,

If I need to clear "w" Register in a program,
I can use movlw 0h
then why microchip added an instruction CLRW in their instruction set?
is it an extra command or it has any special need? 'Z' flag is affected by both movlw and clrw !!!
 

Re: CLRW

No, they are not the same.

CLRW affects the Z flag, MOVLW does not.

Cheers,
 
Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…