Set Configuration from code?


Closed Thread
Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2007
    Posts
    67

    Default Set Configuration from code?

    Is there a way to write the "meProg - Configuration" settings right in my code? Setting the Osc modes, Watchdog timer, Fail safe, etc - all the stuff that pops up in the Configuation window of the melabs Programmer?

    I once tried to do this with DEVICE in the code, but PB didn't like that. I don't think I can write to the Config registers in my code after it's already programmed and running - can I?

    I chased this once before and gave up, but now I'm using a big 18F for a project and it's got about 40 different Configs - each time I flash it in development, I have to go manually set them all each time. I'd like to flag it so they're automatically set properly from my code.

    ??

    Thanks!

  2. #2
    Join Date
    Apr 2006
    Location
    New Hampshire USA
    Posts
    298


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by kevj View Post
    Is there a way to write the "meProg - Configuration" settings right in my code? Setting the Osc modes, Watchdog timer, Fail safe, etc - all the stuff that pops up in the Configuation window of the melabs Programmer?

    I once tried to do this with DEVICE in the code, but PB didn't like that. I don't think I can write to the Config registers in my code after it's already programmed and running - can I?

    I chased this once before and gave up, but now I'm using a big 18F for a project and it's got about 40 different Configs - each time I flash it in development, I have to go manually set them all each time. I'd like to flag it so they're automatically set properly from my code.

    ??

    Thanks!
    http://www.picbasic.co.uk/forum/showthread.php?t=543:
    Ohm it's not just a good idea... it's the LAW !

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Dave
    Always wear safety glasses while programming.

  4. #4
    Join Date
    Sep 2005
    Location
    Campbell, CA
    Posts
    1,107


    Did you find this post helpful? Yes | No

    Default

    If you want to do it at runtime, check out

    http://www.picbasic.co.uk/forum/showthread.php?t=4093
    Charles Linquist

  5. #5
    Join Date
    Aug 2007
    Posts
    67


    Did you find this post helpful? Yes | No

    Default

    LOL. Thanks guys. That'll do it.

Similar Threads

  1. lumex 4 line display
    By glkosec in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 12th August 2009, 17:55
  2. 18f series chip locked up
    By glkosec in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 11th August 2009, 07:27
  3. Interruptus Frustratus
    By Byte_Butcher in forum General
    Replies: 16
    Last Post: - 17th April 2009, 20:36
  4. Reading in Manchester code
    By brid0030 in forum Code Examples
    Replies: 0
    Last Post: - 10th March 2009, 21:55
  5. Change On Interrupt, PIC16F884
    By elec_mech in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 14th November 2008, 17:25

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