发 帖  
原厂入驻New
申请华秋企业认证 多层板首单免费打样!
30s提交资料,10分钟通过审核(免费赔付+顺丰包邮)>>立即报名
[问答] 怎么调试与生产构建与PIC配置寄存器
256 寄存器 PIC
分享
我有一些东西在挣扎。当我们处于“开发”模式时,我们构建调试。对于生产,我们使用标准的构建,但是如何在PIC配置寄存器中工作呢?PIC32,例如,有一个位启用调试。在构建生产时,这一位是否会自动禁用,或者我们应该手动操作,还是无关紧要?非常感谢,Stephane。

以上来自于百度翻译


      以下为原文

    Hello

There is something I am struggling with. When we are in "development" mode, we build for debug. For Production, we use standard Build.
But how this works in regards to the PIC configuration registers?
PIC32, for example, have a bit to enable debug. Is this bit automatically disabLED when building for production, or should we do it manually or it does not matter?

Thank you very much, Best Regards, Stephane.
0
2019-6-3 07:25:24   评论 分享淘帖 邀请回答

相关问题

19个回答
调试配置位通常由调试器处理,因此您不必“触摸”它。一些其他更改涉及具有模拟特性的PIN,只有在使用调试器时才自动设置为数字(至少在某些PICS上)。

以上来自于百度翻译


      以下为原文

    DEBUG config bit is usually handled by the debuggers, so you must not "touch" it.
 
Some other changes relate to pins with analog features that are automatically set as digital ONLY when using the debugger (at least on some PICs...)
2019-6-3 07:39:19 评论

举报

您好,谢谢。和谐地说,配置寄存器有这一点,它必须设置为调试工作。所以我们不应该只关心它?Stephane。

以上来自于百度翻译


      以下为原文

    Hello
 
Thank you.
 
In harmony, the Configuration Registers have this bit, it must be set for the debug to work.
So we should not just care about it?
 
Stephane.
2019-6-3 07:49:03 评论

举报

MPLABX处理调试位,而不是协调。

以上来自于百度翻译


      以下为原文

    MPLabX handles the debug bit, not Harmony.
2019-6-3 07:54:30 评论

举报

他看起来是个好消息。这是痛苦的和谐去改变这一点,每次我需要做一个生产建设!非常感谢你!Stephane。

以上来自于百度翻译


      以下为原文

    Hello
 
OK so good news. That was painful to go in harmony to change that bit each time I need to do a production build!
Thank you very much!
 
Stephane.
2019-6-3 08:13:57 评论

举报

HELLO似乎不那么透明,当我为生产而建造的时候,IPE说它已经调试了Stuff.斯蒂芬。

以上来自于百度翻译


      以下为原文

    Hello
 
Does not seem so transparent, when I build for production then IPE says it has debug stuff.
 
Stephane.
2019-6-3 08:23:09 评论

举报

配置寄存器中的调试位不止一个,对于生产来说,在调试构建与构建之间可以考虑不同。在调试构建中,除了清除配置寄存器中的调试器启用位之外,MPLAB还与链接器一起加载E程序图像,并介绍一些额外的变量。调试执行器提供与调试通信工具PICkit 3、ICD 3或类似的通信,设置和清除断点寄存器,并为调试器中的监视窗口提供更新的RAM和CPU寄存器值。编译器和链接器选项卡,在生产构建中是否包括符号信息。符号信息可用于提供回溯信息,当调试器不活动时,也可以用于提供回溯信息,并且在源代码和堆栈帧信息中包括一些关于行号的信息,这些信息可以被省略。在生产构建中。这些设置可能取决于是否要在生产构建中提供一些错误跟踪的可能性,或者您是否想使盗版或反编译尝试更加困难。

以上来自于百度翻译


      以下为原文

     
There is more than the debug bit in configuration register, that may be considered differently between debug build and building for production.
In a debug build, in addition to clearing the Debugger Enable bit in configuration register,
MPLAB together with the linker also load a Debug Executive in the program image and introduce some additional variables. The Debug Executive provide communication with the debug communication tool, PICkit 3, ICD 3 or similar, set and clear breakpoint registers, and provide updated RAM and CPU register values for watch window in debugger.
 
In addition to this, there are options in MPLAB Project Properties, assembler, compiler and linker tabs,
whether to include symbol information in production build, or not.
Symbol information may be used to provide traceback information, also when debugger is not active,
and include some information about line numbers in source code and stack frame information, that may be omitted in a production build.
 
These settings may depend upon ambitions about whether to make some possibilities for error tracing available in production build, or if you want to make attempts of piracy or decompilation more difficult.
 
Regards,
   Mysil
 
2019-6-3 08:40:44 评论

举报

最好的方法是不要对调试位做任何事情。如果你设置了它,它会影响你的产品构建。因为这些bug,即使你清除了它,也可能会破坏你的产品版本。

以上来自于百度翻译


      以下为原文

    The best way is not to do anything about the DEBUG bit. If you have it set, it'll screw up your production builds. Because of the bugs, it may screw up your production builds even if you have it cleared.
2019-6-3 08:57:36 评论

举报

HelloThank,你太好了!建立清洁生产结构的过程在哪里?有没有一种简单的方法来创建调试或生产版本,而不必修改大量的配置项?谢谢你,Stephane。

以上来自于百度翻译


      以下为原文

    Hello
 
Thank you very much!
Where is the process to create a clean production build documented?
Is there an easy way to create a debug or production build without having to modify plenty of configuration items?
 
Thank you Stephane.
2019-6-3 09:13:54 评论

举报

我不确定你在打什么。不要设置调试,而是在配置中设置。MPLabX照顾其余的人。如果运行调试器,则会进行调试生成。如果你只是编程,它会产生一个生产版本。

以上来自于百度翻译


      以下为原文

    I am not sure what you are fighting.
Do not set the debug but in Config.
MPLabX takes care of the rest.
If you run a debugger it makes a debug build. If you just program it makes a production build.
2019-6-3 09:31:07 评论

举报

HelloThanks NKurzman .你如何从MPLABX编程?我们需要使用IPE吗?可能是我错误地思考当我做一个不使用调试菜单的构建时,它是一个生产版本吗?Stephane。

以上来自于百度翻译


      以下为原文

    Hello
 
Thanks NKurzman.
How do you program from MPLABX? We need to use IPE?
May be I am wrongly thinking when I do a Build not using the Debug menu, it is a production build?
 
Stephane.
2019-6-3 09:37:51 评论

举报

如果右键单击项目树的顶部并选择clean and build,这将是生产版本。要进行编程,只需单击工具栏中的绿色向下大箭头。要进行调试构建,请选择Debug->debug main projectthis对设备进行编程,并加载调试器。

以上来自于百度翻译


      以下为原文

    if you right click the top of your project tree and select clean and build, it will be a production release.
 
To program just click the big green down pointing arrow in the tool bar.
 
 
To make a debug build, select Debug->debug main project
this programs the device and loads the debugger.
2019-6-3 09:43:43 评论

举报

我对这个问题也有点困惑。格林先生:但是我可以清理一下吗?DEBUG配置位由工具(例如,Real ICE、PICkit等)处理。您可以随意设置它,但是工具将在编程操作期间将其设置为适当的值。我们发现,有太多的客户给我们带来这样的错误,让客户选择。事实上,客户无论如何也不必担心这一点。很长一段时间,我们从数据表中擦除对该位的引用,以避免混淆。但是这个位子再次出现在数据表中,主要是为了帮助第三方工具开发人员。简而言之,你不必担心调试。告诫:我对IPE下的操作不确定。在IPE下,我们可以假设你知道你在做什么,只是按照你告诉我们的程序去做。(或者我们可能不会。)我会尝试找出。(编辑:我已经确认IPE还控制调试位。接下来,有人提到,有时MPLAB X、XCC等会在映像中添加额外的代码以进行调试。对于PIC32器件来说,这通常是不正确的。额外的代码仍然存在,但它被放置在PIC32设备上的一些“秘密”调试器内存中。这意味着无论是生产还是调试,PIC32设备的内置图像都是相同的。该工具(Real ICE,PICkit)在编程操作期间,只需将需要的调试执行程序等编程到专用内存中。其中一个例外是,如果使用明显的原因,您使用的是仪表跟踪特性。

以上来自于百度翻译


      以下为原文

    I am also a bit confused about what the issue is.  mr green:   But maybe I can clear up a few things?
 
The DEBUG configuration bit is handled by the tool (e.g. Real ICE, PICkit, etc.)  You can set it however you want, but the tool is going to set it to the appropriate value during the programming operation.  We found that way too many customers were getting this bit wrong for us to leave it up to customer selection.  And realistically the customer shouldn't have to worry about that bit anyway.  For a long time we scrubbed references to that bit from the datasheet to help avoid confusion.  But the bit has been showing up in datasheets again, primarily to help third party tool developers.  In short, you don't need to worry about DEBUG.

Caveat:  I am unsure about operation under IPE.  Under IPE we may assume that you know what you are doing and just program what you tell us to.  (Or we may not.)  I'll try to find out.
 
(Edit:  I have confirmed that IPE also controls the DEBUG bit.  So you should never have to worry about it.)

Next, it has been mentioned that sometimes MPLAB X, XCC, etc will put extra code in your image for debugging.  This is generally untrue for PIC32 devices.  The extra code is still there, but it is placed in some "secret" debugger only memory on the PIC32 devices.  This means that the built image for a PIC32 device is the same whether it is production or debug.  The tool (Real ICE, PICkit) will simply program the needed debug executive etc into the special memory during the programming operation.  The one exception to this is if you are using the instrumented trace feature, for obvious reasons.
2019-6-3 09:55:05 评论

举报

大家好,谢谢大家。很明显从一开始:-Productbuild:Run->Clean and Build Project-Debug build:Debug->Debug Project。我现在对调试位很清楚,非常感谢。但是,当我创建产品构建时,我猜调试位是否设置为Harmony,所以在Confi中guration Registers,生产构建似乎没有正确地管理那个位,然后IPE对此进行加热并删除它。非常感谢您的帮助Stephane。

以上来自于百度翻译


      以下为原文

    Hello
 
Thank you everyone.
Clearly from the beginning:
- Production build: Run->Clean and Build Project
- Debug build: Debug->Debug Project.
 
I am now clear about the debug bit, thank you very much.
But still, when I create the production build, I guess if the debug bit is set in Harmony, so in Configuration Registers, it seems the production build is not managing that bit correctly, then IPE warms about it and removes it.
 
Thank you very much for your help
 
Stephane.
2019-6-3 10:10:18 评论

举报

生产结构没有管理任何东西。它按照你所指定的来构建一切。

以上来自于百度翻译


      以下为原文

   


The production build does not manage anything. It builds everything as you have specified.
2019-6-3 10:29:45 评论

举报

嗨,NorthGuy,谢谢,上面的人似乎有不同的说法“我们不必关心”;)总之,我禁用了Harmony配置中的调试位,所以配置寄存器。我认为这是可行的,谢谢大家!Stephane。

以上来自于百度翻译


      以下为原文

    Hi NorthGuy,
 
Thank you, it seemed people above said differently "we do not have to care" ;)
As a conclusion, I disabled the debug bit from the configuration of Harmony so config registers. It works then I think as expected.
 
Thanks to all!
 
Stephane.
2019-6-3 10:44:00 评论

举报

如何禁用调试位?你不应该做任何事情。

以上来自于百度翻译


      以下为原文

    How are you disabling the debug bit?
You should not be doing anything with it.
2019-6-3 10:53:46 评论

举报

HeloIT是和谐的,看看在非常底部的配置寄存器。

以上来自于百度翻译


      以下为原文

    Hello
 
It is just in Harmony, look at the configuration registers at the very bottom.
 
Stephane.
2019-6-3 11:05:20 评论

举报

在MPLAX中构建,然后在IPE中编程是一个额外的复杂性。如果您在MPLAX中做了所有的事情,就不必担心它。

以上来自于百度翻译


      以下为原文

    Building in MPLABX, then programming in IPE was an extra complication.
If you did everything inside MPLAX you wouldn't have to worry about it.
2019-6-3 11:18:13 评论

举报

如果Oracle正在使用调试位,那么这将被视为一个bug。他们没有理由这样做。

以上来自于百度翻译


      以下为原文

    If harmony is playing with the debug bit then that would count as a bug. They have no reason to.
2019-6-3 11:23:32 评论

举报

只有小组成员才能发言,加入小组>>

57个成员聚集在这个小组

加入小组

创建小组步骤

关闭

站长推荐 上一条 /10 下一条

快速回复 返回顶部 返回列表