完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
我编译了一个程序,并尝试使用MPLAB X IDE V3.30通过PICtiT3下载到芯片。PICkit3识别它,但是没有正确地编程。配置位在头文件中:MCU由外部5V供电。除了从MCLR到5V的10k上拉外,没有其他电路连接。此时,我怀疑它是一个坏芯片(可能是坏闪存?)还有什么我应该尝试的吗?谢谢您。
以上来自于百度翻译 以下为原文 I compiled a program and tried downloading to the chip via PICkit3 using MPLAB X IDE v3.30. PICkit3 recognizes it but fail to program it properly. Connecting to MPLAB PICkit 3... Currently loaded firmware on PICkit 3 Firmware Suite Version.....01.46.14 * Firmware type..............Midrange Target voltage detected Target device PIC10F322 found. Device ID Revision = 2 The following memory area(s) will be programmed: program memory: start address = 0x0, end address = 0x1ff configuration memory Device Erased... Programming... program memory Address: 0 Expected Value: 29fe Received Value: 0 Failed to program device The configuration bits are in a header file: #include #pragma config FOSC = INTOSC // Oscillator Selection bits (EC: CLKIN function enabled) #pragma config BOREN = OFF // Brown-out Reset Enable (Brown-out Reset enabled) #pragma config WDTE = OFF // Watchdog Timer Enable (WDT enabled) #pragma config PWRTE = OFF // Power-up Timer Enable bit (PWRT disabled) #pragma config MCLRE = ON // MCLR Pin Function Select bit (MCLR pin function is MCLR) #pragma config CP = OFF // Code Protection bit (Program memory code protection is disabled) #pragma config LVP = ON // Low-Voltage Programming Enable (Low-voltage programming enabled) #pragma config LPBOR = ON // Brown-out Reset Selection bits (BOR enabled) #pragma config BORV = LO // Brown-out Reset Voltage Selection (Brown-out Reset Voltage (Vbor), low trip point selected.) #pragma config WRT = OFF // Flash Memory Self-Write Protection (Write protection off) The MCU was powered from a external 5V. And there is no other circuitry hooked up except a 10k pull-up from MCLR to 5V. At this point I suspect it is a bad chip (bad flash perhaps?). Is there anything else I should try? Thank you. |
|
相关推荐
1个回答
|
|
你必须有一个旁路电容连接在Vdd和Vss之间,靠近你的PIC的引脚。你的配置位设置还不重要,编程在他们做任何事之前发生。
以上来自于百度翻译 以下为原文 You MUST have a bypass capacitor connected between Vdd and Vss, close to your PIC's pins. Your config bit settings do not matter yet, programming happens before they do anything. |
|
|
|
只有小组成员才能发言,加入小组>>
5171 浏览 9 评论
2001 浏览 8 评论
1931 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3176 浏览 3 评论
请问电源和晶体值之间有什么关系吗?PIC在正常条件下运行4MHz需要多少电压?
2228 浏览 5 评论
737浏览 1评论
622浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
509浏览 1评论
PIC Kit3出现目标设备ID(00000000)与预期的设备ID(02c20000)不匹配。是什么原因
635浏览 0评论
533浏览 0评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-26 05:04 , Processed in 1.021605 second(s), Total 49, Slave 42 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号