This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Watchdog Timer

Hi,
I have the following questions:
1. - like I can make for not activating the watchdog timer?
Whenever I execute my code, the watchdog timer is activated and I cannot disable it, that is to say:
The SFR IEN1, in the bit 6 have the "watchdog timer start flag", which I don't have it seteado in my code (SWDT=0, bit 6 of IEN1), and however, the watchdog timer same is activated and me resetea the microcontrolador. !!!
It is a problem of the microcontrolador, of the card C509-L, of the program or of the debugger (Keil Software).

2.- Why Reason the compiler assmbly doesn't recognize me the numbers hexadecimals, ej:

IEN3 DATA BEH
MOV IEN3,#AAH

If it recognizes me:
IEN3 DATA 80H
MOV IEN3,#86H

That is to say, it doesn't recognize me the characters A,B,C,D,E and F in Hexadecimal.
That I should make?

Parents
  • I only have an answer for the second question:

    2.- Why Reason the compiler assmbly doesn't recognize me the numbers hexadecimals, ej:

    IEN3 DATA BEH
    MOV IEN3,#AAH

    If it recognizes me:
    IEN3 DATA 80H
    MOV IEN3,#86H

    That is to say, it doesn't recognize me the characters A,B,C,D,E and F in Hexadecimal


    In assembler, hex numbers MUST begin with the digits 0-9. Variable names MAY NOT begin with 0-9 but may begin with A-Z and a few other characters.

    So, AAH is a variables named AAH and not the hex number. To make it a hex number you must prefix it with 0 -- 0AAH.

    Jon

Reply
  • I only have an answer for the second question:

    2.- Why Reason the compiler assmbly doesn't recognize me the numbers hexadecimals, ej:

    IEN3 DATA BEH
    MOV IEN3,#AAH

    If it recognizes me:
    IEN3 DATA 80H
    MOV IEN3,#86H

    That is to say, it doesn't recognize me the characters A,B,C,D,E and F in Hexadecimal


    In assembler, hex numbers MUST begin with the digits 0-9. Variable names MAY NOT begin with 0-9 but may begin with A-Z and a few other characters.

    So, AAH is a variables named AAH and not the hex number. To make it a hex number you must prefix it with 0 -- 0AAH.

    Jon

Children