完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
大家好几个月前,我试着启动PIC32 mm项目,但是在做Bootloader工作后停止工作。这些天,HTTP://www. McCHIP.COM/FUMMS/M1022247.ASPXI恢复了这个项目,我发现问题仍然在发生。我想知道为什么,我调查页面擦除时间,发现它需要16Ms!像MCU这样的擦除代码使用FRC PLL在24MHz下运行,通过USB进行自我调整,我调整PLLoDIV以在12MHz运行SysCLK,仍然是16Ms!我看一下数据表,上面写着4.26MS TYP。没有错误的说法是擦除时间的增加我想知道我是否做错了什么。有人能证实吗?
以上来自于百度翻译 以下为原文 Hello everyone Few months ago, i try to kick start PIC32MM project, but stop working on after fail to make bootloader work. http://www.microchip.com/forums/m1022247.aspx I resume the project these days, and i find the issue still happen. I am figuring out why. I probe the page erase time and found out it take 16ms! The erase code like this void NVMemDelay(volatile int i) { while(i > 0) i--; } uint32_t __attribute__((nomips16)) NVMemOperation(uint32_t nvmop) { LATASET = 0x8; // PIN RA3 rise __builtin_disable_interrupts(); DMACONSET = _DMACON_SUSPEND_MASK; NVMCON = nvmop; NVMCONSET = 0x4000 | nvmop; NVMemDelay(100); NVMKEY = 0xAA996655; NVMKEY = 0x556699AA; NVMCONSET = _NVMCON_WR_MASK; while(NVMCONbits.WR); NVMCON = 0; DMACONCLR = _DMACON_SUSPEND_MASK; __builtin_enable_interrupts(); LATACLR = 0x8; // PIN RA3 fall return NVMCON & 0x3000; } void NVMemWriteRow(uint32_t addr, uint32_t * row) { NVMADDR = KVA_TO_PA(addr); NVMSRCADDR = KVA_TO_PA(row); NVMemOperation(0x4003); } void NVMemEraseBlock(uint32_t progAddr) { NVMADDR = KVA_TO_PA(progAddr); NVMemOperation(0x4); } MCU is running at 24MHz using FRC PLL and self tuned by USB, I adjust PLLODIV to run SYSCLK at 12MHz, still 16ms! I look at the datasheet, it says 4.26ms Typ. And there is no errata saying the increase of erase time I would like to know if i have done anything wrong. Can anyone confirm it? |
|
相关推荐
1个回答
|
|
闪光灯的“磨损”越长,擦除时间越长。数据表说明马克斯擦除时间是什么?Ruben
以上来自于百度翻译 以下为原文 The more "worn" the flash becomes the longer it takes to erase. What does the datasheet says about Max erase time? /Ruben |
|
|
|
只有小组成员才能发言,加入小组>>
5234 浏览 9 评论
2026 浏览 8 评论
1950 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3201 浏览 3 评论
请问电源和晶体值之间有什么关系吗?PIC在正常条件下运行4MHz需要多少电压?
2253 浏览 5 评论
771浏览 1评论
659浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
588浏览 1评论
PIC Kit3出现目标设备ID(00000000)与预期的设备ID(02c20000)不匹配。是什么原因
670浏览 0评论
571浏览 0评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-20 09:19 , Processed in 2.747854 second(s), Total 75, Slave 59 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号