Helpful ReplyHot!Warning "hex file has the debug bit set" with MPLAB V3.61

Author
PhilipJ
Junior Member
  • Total Posts : 80
  • Reward points : 0
  • Joined: 2010/07/06 06:14:40
  • Location: 0
  • Status: offline
2017/06/26 08:50:53 (permalink)
0

Warning "hex file has the debug bit set" with MPLAB V3.61

Hi,
 
I've just started a new Harmony V1.10 project using MPLAB.X V3.61 and I've noticed that every time I do a build I get the following in the Output window:
 
Warning: The hex file has the debug bit set.  The debug bit has been cleared during load to memory.  The original hex file has not been modified.
 
Anybody else seeing this?
Anybody know what is causing it?
 
Thanks
PhilipJ
#1
CinziaG
mind power
  • Total Posts : 3144
  • Reward points : 0
  • Joined: 2016/12/07 14:20:36
  • Location: Wien
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2017/06/26 09:17:31 (permalink)
+1 (1)
You may have some #pragma DEBUG directive somewhere in your code... (am not a big expert of Harmony so can't help)

in 2018 you signed for your annihilation. in 2019 it will come ;) I promise
#2
GeorgePauley
Moderator
  • Total Posts : 1041
  • Reward points : 0
  • Joined: 2009/12/01 13:59:30
  • Location: Chandler AZ
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2017/06/26 09:57:28 (permalink)
+3 (3)
Not sure why you have the debug bit set (in configuration memory).  Cinzia's suggestion that you have the bit set in your code is likely correct.
 
In the past, customers have inadvertently had the debug bit set, particularly in hex files.  This is problematic as the device will probably not work correctly in "normal", free-running, mode without a debugger.  So MPLAB X gives the warning that it has detected the debug bit was set.
#3
RISC
Super Member
  • Total Posts : 5369
  • Reward points : 0
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2017/06/30 14:58:02 (permalink) ☄ Helpfulby PhilipJ 2017/07/11 04:51:37
+1 (1)
Hi,
In Harmony you can define configuration bits in MHC configuration central window, "options" tab and then expand the "Device & Project Configuration" > expand "PIC32xxxxxxxxx Device Configuration" > expand "DEVCFG0" and you should see somewhere DEBUG which you need to set to OFF (it might be in another configuration register DEVCFGx depending upon your PIC)
Regards
 
#4
PhilipJ
Junior Member
  • Total Posts : 80
  • Reward points : 0
  • Joined: 2010/07/06 06:14:40
  • Location: 0
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2017/07/07 02:18:18 (permalink)
0
Thanks RISC, it is exactly as you said, find DEVCFG0 and set Background Debugger Enable to OFF.
I'm still getting used to Harmony and it's way of setting things.
I think the warning message may be new because I don't ever remember seeing it in earlier versions of MPLAB.X
 
Anyway thanks
PhilipJ
 
#5
RISC
Super Member
  • Total Posts : 5369
  • Reward points : 0
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2017/07/11 05:18:14 (permalink)
+2 (2)
Hi,
This is not a new warning message but you won't see it until you set debug to ON.
Same is true for watchdog enable bit. It must be off for debugging
Actually the DEBUG bit should always be off when you create a project.
It is needed by the debugger (pickit3, ICD3, ....) and should not be set by the user.
Regards
 
#6
nilp
New Member
  • Total Posts : 2
  • Reward points : 0
  • Joined: 2018/11/18 11:36:36
  • Location: 0
  • Status: offline
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2019/02/13 18:22:08 (permalink)
0
I am using MikroC to program dspic33ep512mpu. Everything was perfectly working fine but suddenly it starts to give me error while i am trying to program MCU. 
 
 
 
Warning: The hex file has the debug bit set.  The debug bit has been cleared during load to memory.  The original hex file has not been modified.
#7
qhb
Superb Member
  • Total Posts : 8712
  • Reward points : 0
  • Joined: 2016/06/05 14:55:32
  • Location: One step ahead...
  • Status: online
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2019/02/13 18:31:29 (permalink)
0
A "warning" is not an "error".
Have you read the previous advice in this topic? Presumably MikroC has some facility for setting the config bits. You should make sure it is not setting the DEBUG bit to "ON".
 
#8
NKurzman
A Guy on the Net
  • Total Posts : 16886
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: online
Re: Warning "hex file has the debug bit set" with MPLAB V3.61 2019/02/13 19:37:36 (permalink)
0
Is the Message No Clear?  The Debug Bit can NOT Be set unless you Plan to Run a Debugger.
#9
Jump to:
© 2019 APG vNext Commercial Version 4.5