Bootloader pic16f1825 @32mhz pll


Closed Thread
Results 1 to 11 of 11

Hybrid View

  1. #1
    Join Date
    May 2013
    Location
    australia
    Posts
    2,397

    Default Bootloader pic16f1825 @32mhz pll

    MY bootloader config.ini is as follows but I cannot get it to work . in fact pll and bootloader seems to always give me grief
    any ideas ?



    Code:
    ; optional path information - default output folder is 
    ; user documents -> umcbuild... 
    [PATH] 
    Output=C:\MYBOOTLOADER
    [TEMPLATE] 
    ;PIC18=..\src\18F\umc_loader.asm 
    PIC16=..\src\16F\umc_loader.asm 
    ; device name and OSC... 
    [MCU] 
    Device=16F1825 
    OSC=32000000 
    ;[USART] 
    BAUDRATE = 19200 ; initial startup baudrate (default is 19200) 
    BRGH16 = 1 ; 16 bit SPBRG support (default is OFF) 
    ; device configuration settings... 
    [CONFIG] ;----- CONFIG1 Options -------------------------------------------------- 
    __config        _CONFIG1,    _FOSC_INTOSC & _CP_OFF & _WDTE_ON  &  _PWRTE_ON  &  _MCLRE_ON  & _CLKOUTEN_OFF
    __config      _CONFIG2, _PLLEN_ON & _LVP_OFF
    ; place startup code in here... 
    [USERCODE] 
    ;banksel APFCON0 
    ; you need this as APFCON0 is at banked address. 
    ;bSf APFCON0,7 ;bSf APFCON0,2 
    banksel ANSELC ; you need this as ANSELA is at banked address. 
    clrf ANSELC
    banksel OSCCON ; you need this as OSCCON is at banked address. 
    movlw 0xf0 ; 8 mhz, pll enabled 
    movwf OSCCON
    banksel OSCSTAT
    btfss OSCSTAT,6
    goto $-1
    Warning I'm not a teacher

  2. #2
    Join Date
    Aug 2011
    Posts
    419


    Did you find this post helpful? Yes | No

    Default Re: Bootloader pic16f1825 @32mhz pll

    I don't have a chip to try it on, but off the top of my head that looks ok.

    Are you sure it's not the _config _WDTEN_ON that's fouling things up?
    Try _WDTEN_OFF or _WDTE_SWDTEN (if you want it programmable) and see what happens.

  3. #3
    Join Date
    May 2013
    Location
    australia
    Posts
    2,397


    Did you find this post helpful? Yes | No

    Default Re: Bootloader pic16f1825 @32mhz pll

    didn't help

    last effort
    Code:
    ; optional path information - default output folder is 
    ; user documents -> umcbuild... 
    [PATH] 
    Output=C:\MYBOOTLOADER
    [TEMPLATE] 
    ;PIC18=..\src\18F\umc_loader.asm 
    PIC16=..\src\16F\umc_loader.asm 
    ; device name and OSC... 
    [MCU] 
    Device=16F1825 
    OSC=8000000 
    [USART] 
    BAUDRATE = 19200 ; initial startup baudrate (default is 19200) 
    BRGH16 = 1 ; 16 bit SPBRG support (default is OFF) 
    ; device configuration settings... 
    [CONFIG] ;----- CONFIG1 Options -------------------------------------------------- 
     __config        _CONFIG1,    _FOSC_INTOSC & _CP_OFF & _WDTE_OFF  &  _PWRTE_ON  &  _MCLRE_ON  & _CLKOUTEN_OFF
     __config      _CONFIG2, _PLLEN_OFF & _LVP_OFF
    ; place startup code in here... 
    [USERCODE] 
    ;banksel APFCON0 
    ; you need this as APFCON0 is at banked address. 
    ; bCf APFCON0,7 
    ; bCf APFCON0,2 
    ; banksel ANSELC ; you need this as ANSELA is at banked address.
     movlb 3
     BCF ANSELC,5
     BCF ANSELC,4
     movlb 1
     BSF TRISC,4
     BSF TRISC,5
     ;movlb 1
     movlw 0x70 ; 8 MHz
     movwf OSCCON
    ; btfss OSCSTAT,6
    ; goto $-1
    Warning I'm not a teacher

  4. #4
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: Bootloader pic16f1825 @32mhz pll

    The attached is what I use when using the ccp on portc. It places com on porta.
    Attached Files Attached Files
    Dave Purola,
    N8NTA
    EN82fn

  5. #5
    Join Date
    May 2013
    Location
    australia
    Posts
    2,397


    Did you find this post helpful? Yes | No

    Default Re: Bootloader pic16f1825 @32mhz pll

    tried that dave , still no go

    query this though I say It places com on portc


    what I use when using the ccp on portc. It places com on porta.

    banksel APFCON0 ; you need this as APFCON0 is at banked address.
    movlw b'00000000' ; ALL PORTS TO DEFAULT
    ;movlw b'10000100' ; COM PORT TO RA0:RA1
    movwf APFCON0
    not sure where i'm going wrong
    Warning I'm not a teacher

  6. #6
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: Bootloader pic16f1825 @32mhz pll

    You are right Richard, I had the wrong file on the wrong computer. Try this one. I really need to watch what I'm doing....
    Attached Files Attached Files
    Dave Purola,
    N8NTA
    EN82fn

Similar Threads

  1. Pic16f1825 adcon0
    By nobner in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 19th May 2014, 09:41
  2. PIC16F1825 unable to Light an LED
    By Lestat in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 16th March 2013, 18:38
  3. Replies: 5
    Last Post: - 10th April 2011, 12:48
  4. Using INTOSC 32Mhz as RF Radio Control and Data Communication
    By rayzrocket in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 13th January 2011, 12:10
  5. Hs Pll
    By Ron Marcus in forum Off Topic
    Replies: 2
    Last Post: - 21st February 2006, 00:34

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts