完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
|
论坛上,PIC24FJ128GA202XC16调试了主板和子板一对一回。子板包含图片,母板包含女儿的标题以及SD和UART/USB收发器电路,所有IO都有跳线。第一组板工作得很好。必须对UART/USB收发器的IO参考如何供电做一些小调整,以及一些小事情。对两个板进行更新。新的子板仍然适合于原来的母板头,并且工作得很好,即所有的IO工作。问题:如果我在旧板或新子板上启用UART(UART到USBCOM)并在新的母板上运行它,那么调试停止。我的常规调试错误处理函数(见下文)没有被跳过。调试停止,虽然我不知道它在哪里停止,也不知道它为什么停止。注意:如果UART/USB收发器跳线连接与否,调试停止(UART管脚浮动)。有人能给我一些关于如何继续解决暂停问题的提示和提供id吗?关于我的新母亲董事会可能有什么问题?谢谢,Craig//Only支持DEBUG测试/*Primary Exception Vector处理程序:如果INTCON2bits.ALTIVT=0,则使用这些例程。该文件中的所有陷阱服务例程都只是确保设备在陷阱服务例程中持续执行代码。用户可以修改这里提供的基本框架以适应其应用的需要。*/void_.((中断,no_auto_psv))OscillatorFail(void){errLoc=getErrLoc();INTCON1bits.OSCFAIL=0;//清除陷阱标志,而(1)}//void_.(u inter._))_AddressError(void)voi(中断,no_auto_auto_psv)1_AddressErError(void){未签名的char ele(void){未签名的char(vo_ele___..{未符号._auto_auto_auto_auto_psv_vvvvvvvvvvvvvvvvvvvvvvvvvvvvv))AdAdAdAdAdAddressErErErErEr(无效)_Address.{._未签名的char char_ele(void..{__11ele___...ele 1111ele__.{1111ele____psv)_StackError(void){errLoc=GEtErErLoc();INTCON1bits.STKERR=0; ; //清除陷阱标志,同时(1);///清除陷阱标志,同时(1):}}///void_u.u._.(u_中断u_intergetintergetintergegetErErErErErErErErErErErLoc()INTCON1bits.STKEKERR=0;//void_att_._._._.u((u interu_inter_inter_inter_._._u interu_._u interu_.u_._u._u*备选异常向量处理ers:如果INTCON2bits.ALTIVT=1,则使用这些例程。该文件中的所有陷阱服务例程都只是确保device在陷阱服务例程内连续执行代码。用户可以修改这里提供的基本框架以适应其应用的需要。*/void_.((inter.,no_auto_psv))AltOscillatorFail(void){INTCON1bits.OSCFAIL=0;而(1);}void_.((inter.,no_auto_psv))_AltAddressError(void){INTCON1bits.ADDRERR=0;(1);}void_.((inter.,no_auto_psv))AltStackError(void){INTCON1bits.STKERR=0;而(1);}void_.((inter.,no_auto_psv))AltMathError(void){INTCON1bits.MATHERR=0;而(1);}
以上来自于百度翻译 以下为原文 Forum, PIC24FJ128GA202 XC16 Debugging Made mother board and daughter board pair a while back. The daughter board contained the pic and the mother board contained a header for the daughter along with SD and UART/USB transceiver circuitry with jumpers to all IO. The first set of boards work well. Had to make a minor tweak to how the IO reference for UART/USB transceiver was powered and a few minor things. Made an update to both boards. The new daughter boards still fit into the original mother board headers and work perfectly well i.e. all IO work. Problem: If I enable UART (UART to USB COMs) on either the old or new daughter board and run it on the new mother board then debugging halts. My normal DEBUG error handling functions (see below) are not tripped. Debugging halts though I can't tell where it is halting or exactly why it is halting. Note: debugging halts if the UART/USB transceiver jumpers are connected or not (UART pins floating). Would someone please provide me some pointers on how to move forward troubleshooting the halt issue and provide ideas as to what may be wrong with my new mother boards? Thank you, Craig // Only support DEBUG testing /* Primary Exception Vector handlers: These routines are used if INTCON2bits.ALTIVT = 0. All trap service routines in this file simply ensure that device continuously executes code within the trap service routine. Users may modify the basic framework provided here to suit to the needs of their application. */ void __attribute__((interrupt, no_auto_psv)) _OscillatorFail(void) { errLoc=getErrLoc(); INTCON1bits.OSCFAIL = 0; //Clear the trap flag while (1); } //void __attribute__((__interrupt__)) _AddressError(void) void __attribute__((interrupt, no_auto_psv)) _AddressError(void) { unsigned char ele; ele = 1; errLoc=getErrLoc(); INTCON1bits.ADDRERR = 0; //Clear the trap flag while (1); } //void __attribute__((__interrupt__)) _StackError(void) void __attribute__((interrupt, no_auto_psv)) _StackError(void) { errLoc=getErrLoc(); INTCON1bits.STKERR = 0; //Clear the trap flag while (1); } //void __attribute__((__interrupt__)) _MathError(void) void __attribute__((interrupt, no_auto_psv)) _MathError(void) { errLoc=getErrLoc(); INTCON1bits.MATHERR = 0; //Clear the trap flag while (1); } /* Alternate Exception Vector handlers: These routines are used if INTCON2bits.ALTIVT = 1. All trap service routines in this file simply ensure that device continuously executes code within the trap service routine. Users may modify the basic framework provided here to suit to the needs of their application. */ void __attribute__((interrupt, no_auto_psv)) _AltOscillatorFail(void) { INTCON1bits.OSCFAIL = 0; while (1); } void __attribute__((interrupt, no_auto_psv)) _AltAddressError(void) { INTCON1bits.ADDRERR = 0; while (1); } void __attribute__((interrupt, no_auto_psv)) _AltStackError(void) { INTCON1bits.STKERR = 0; while (1); } void __attribute__((interrupt, no_auto_psv)) _AltMathError(void) { INTCON1bits.MATHERR = 0; while (1); } |
|
相关推荐
3个回答
|
|
|
你给我们的信息太少了,没法猜出一个合理的猜测。所以我会反过来试试:如果硬件应该是相同的(同样的软件在两个板上都运行不变):检查你的“更正”!假设你只有一个“新母亲”:检查焊接!特别是对于短裤。如果硬件不兼容:在1做任何描述。然后继续检查你的软件“适应”。你很可能适应了一个bug。或者忘记适应某事。
以上来自于百度翻译 以下为原文 You're giving us too little information to wager a reasonable guess. So I'll try it the other way round:
|
|
|
|
|
|
1。SW完全一样,2。UART/USB接线略有变化,加上一些焊盘尺寸和位置改变。最初看起来没有短路。我会把每一根针从旧到新,看看有没有明显的东西。同时,关于如何确定“崩溃”的状态还有什么好的想法吗?例如,我能做些什么,或是看事件发生的地方。
以上来自于百度翻译 以下为原文 1. SW is exactly the same, 2. UART/USB wiring slightly changed plus a few pad sizes and locations changed. Initially appears to be no shorts. I will ohm out each pin from old to new to see if there is anything obvious. In the mean time any thoughts on how to determine the state of the "crash" a little better? For example is there anything else that I could enable or look into to see where the incident occurs. |
|
|
|
|
|
其他的东西都一样吗?包括组件(CAPS,电阻)值?很难相信。如果可行的话,尽量做侧面BA测量。可能是某种信号完整性或电源问题。或者没有ISR的中断,在旧板上不会发生。但电源将是我的下一个猜想。操作期间检查!
以上来自于百度翻译 以下为原文 Everything else is identical? Including component (caps, resistores) values? Hard to believe. If feasible try to make side-ba-side measurements. Could be some kind of signal integrity or power supply issues. Or an interrupt without ISR that doesn't occur on the old board. But power supply would be my next guess. Check during operation! |
|
|
|
|
只有小组成员才能发言,加入小组>>
MPLAB X IDE V6.25版本怎么对bootloader和应用程序进行烧录
475 浏览 0 评论
5794 浏览 9 评论
2334 浏览 8 评论
2224 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3530 浏览 3 评论
1124浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
1098浏览 1评论
我是Microchip 的代理商,有PIC16F1829T-I/SS 技术问题可以咨询我,微信:A-chip-Ti
873浏览 1评论
MPLAB X IDE V6.25版本怎么对bootloader和应用程序进行烧录
475浏览 0评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-2 13:59 , Processed in 0.960704 second(s), Total 75, Slave 59 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
496