18F Config fuses


Closed Thread
Results 1 to 21 of 21

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default

    Angus Anderson, Could you please send the statements for the configurations you are trying to set? I'm sure it will shed some light on the problem.

    Dave Purola,
    N8NTA

  2. #2


    Did you find this post helpful? Yes | No

    Default

    Hi Dave- As you requested, here are the 2 files:



    This is the source file config statements (at present commented out)
    '--------------------------- Set Processor options. THIS IS MPASM -----------------------
    'ASM
    ' CONFIG OSCS=OFF, OSC=HS
    ' ; Oscillator switchover disabled, HS Osc enabled
    ' CONFIG BOR=ON, PWRT=ON, BORV=27
    ' ; BOR on, BOR acts at 2.7v
    ' CONFIG WDT=ON, WDTPS=128
    ' ; WDT off
    ' CONFIG STVR=ON, LVP=OFF, DEBUG=OFF
    ' ; Stack over/underflow reset enabled
    ' ; LVP disabled
    ' ; Background debugger disabled
    'endasm

    This is the 18f452.inc file which, as mentioned, works

    ;************************************************* ***************
    ;* 18F452.INC *
    ;* *
    ;* By : Leonard Zerman, Jeff Schmoyer *
    ;* Notice : Copyright (c) 2004 microEngineering Labs, Inc. *
    ;* All Rights Reserved *
    ;* Date : 01/27/04 *
    ;* Version : 2.45 *
    ;* Notes : *
    ;************************************************* ***************
    NOLIST
    ifdef PM_USED
    LIST
    "Error: PM does not support this device. Use MPASM."
    NOLIST
    else
    LIST
    LIST p = 18F452, r = dec, w = -311, f = inhx32
    INCLUDE "P18F452.INC" ; MPASM Header
    ;__CONFIG _CONFIG1H, _OSCS_OFF_1H & _XT_OSC_1H
    ;__CONFIG _CONFIG2H, _WDT_ON_2H & _WDTPS_128_2H
    ;__CONFIG _CONFIG4L, _LVP_OFF_4L
    CONFIG OSCS=OFF, OSC=HS
    CONFIG BOR=ON, PWRT=ON, BORV=27
    CONFIG WDT=ON, WDTPS=128
    CONFIG STVR=ON, LVP=OFF, DEBUG=OFF
    NOLIST
    endif
    LIST
    EEPROM_START EQU 0F00000h
    BLOCK_SIZE EQU 8


    Any insight into the problem would be a help.
    BTW, PBPv2.46

    regards

    Angus

  3. #3
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    The new 18F config directive without the double underscore only works if you use it in the .inc file. They will not work when inserted directly in your code.

    If you comment out 18F config settings in the default PBP .inc file, then insert them directly in your code, you'll have to use the older __config directive.

    Newer versions of PBP include files now have the w = -230 option to suppress the deprecated warning message MPASM spits out when it sees the older __config directive, but it still doesn't allow inserting the new directives inline.
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Hey Bruce-

    Wow! Thanks for solving the problem. Reliable as ever!

    Just wish that it was easier to find documented answers to problems such as this.

    Regards

    Angus Anderson

Similar Threads

  1. A/D conversion with PIC18F67J50
    By ScaleRobotics in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 8th May 2009, 01:48
  2. 18F4550 Bootloader enter via eeprom setting
    By bradb in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 22nd November 2008, 23:51
  3. Error 0X0000008E when connecting a 18F2550 USB HID
    By FranciscoMartin in forum USB
    Replies: 8
    Last Post: - 16th October 2008, 17:20
  4. PortE problems (PIC18F4455)
    By RubenR in forum mel PIC BASIC Pro
    Replies: 15
    Last Post: - 12th July 2006, 15:26
  5. Installation sequence
    By Demon in forum General
    Replies: 23
    Last Post: - 11th July 2006, 03:56

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