Hot!Configuration Bits

Author
tahoe
New Member
  • Total Posts : 5
  • Reward points : 0
  • Joined: 2018/01/30 11:27:12
  • Location: 0
  • Status: offline
2018/02/12 17:39:00 (permalink)
0

Configuration Bits

Hello,
 
Is it possible to access configuration bits through your main program?  Mainly the code protection configuration bit. 
 
-
#1

4 Replies Related Threads

    NKurzman
    A Guy on the Net
    • Total Posts : 15829
    • Reward points : 0
    • Joined: 2008/01/16 19:33:48
    • Location: 0
    • Status: offline
    Re: Configuration Bits 2018/02/12 19:51:36 (permalink)
    0
    Define access? Read? Write? The Answer is Yes for reading, it is in the Data sheet and the Chapter document. The Write depends on the Config bits.
     
    #2
    tahoe
    New Member
    • Total Posts : 5
    • Reward points : 0
    • Joined: 2018/01/30 11:27:12
    • Location: 0
    • Status: offline
    Re: Configuration Bits 2018/02/12 19:58:15 (permalink)
    0
    Thank you for you reply NKurzman,
     
    I would like to write to the code protect configuration bit.  To disable reading of the  device.
     
    I am currently using the PIC32MZ2048
    #3
    Larry.Standage
    Super Member
    • Total Posts : 804
    • Reward points : 0
    • Joined: 2011/12/30 09:50:47
    • Location: 0
    • Status: offline
    Re: Configuration Bits 2018/02/13 10:54:48 (permalink)
    0
    That should be done when the device is programmed. In other words, use
    #pragma config CP=ON

     
    Doing it when the program is running requires you to read the entire page of data, change the CP value, erase the page, then write each row.
    #4
    tahoe
    New Member
    • Total Posts : 5
    • Reward points : 0
    • Joined: 2018/01/30 11:27:12
    • Location: 0
    • Status: offline
    Re: Configuration Bits 2018/02/14 10:37:51 (permalink)
    0
    Larry,
     
    Thanks again.
    #5
    Jump to:
    © 2018 APG vNext Trial Version 4.5