16f628a mclr pin turn off

Discussion in 'Programmer's Corner' started by Dodgydave, Jul 1, 2012.

  1. Dodgydave

    Thread Starter AAC Fanatic!

    Jun 22, 2012
    6,600
    1,060
    Hi how do you assign the mclr pin as an input and not as a reset pin,
    i have tried these lines and none of them work>>

    __CONFIG _CP_OFF & _WDT_OFF & _PWRTE_ON & _INTOSC_OSC_NOCLKOUT & _LVP_OFF &_MCLRE_OFF
    .............................................................................
    __CONFIG _CP_OFF & _WDT_OFF & _PWRTE_ON & _INTOSC_OSC_NOCLKOUT & _LVP_ON &_MCLRE_OFF

    ............................................
    CFG_MCLRE_OFF
    ............................

    pragma_CFG_MCLRE_OFF

    ..................................:confused::confused:
     
  2. Dodgydave

    Thread Starter AAC Fanatic!

    Jun 22, 2012
    6,600
    1,060
    DONT REPLY , i HAVE FIXED IT
     
  3. nerdegutta

    Moderator

    Dec 15, 2009
    2,650
    884
    For future references and other searching: How did you fix it, and what did you do?
     
  4. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,224
    Code ( (Unknown Language)):
    1.  
    2. _MCLRE_OFF EQU H'3FDF' ; RA5/MCLR/VPP pin function is digital input, MCLR internally tied to VDD
    So you have done it correct. Do you know that the PICKIT 2 (and 3) take control of this line then the PICKIT is used to power the chip.
     
  5. Dodgydave

    Thread Starter AAC Fanatic!

    Jun 22, 2012
    6,600
    1,060
    i had a duplicate asm file opened at the same time, so iwas editing the wrong file.. I did it with _Mclre_off
     
Loading...