• slider image 442
  • slider image 483
  • slider image 484
  • slider image 485
  • slider image 486
  • slider image 487
:::


Browsing this Thread:   1 Anonymous Users






Re: PIC12F675 MCLR programming ERROR
#2
中級會員
中級會員


查看用戶資訊
在美國微芯網站有流傳着一則KB:

Why does MPLAB warn me about using internal MCLR and internal RC oscillator mode when I'm using an MPLAB ICD2 programmer?


Resolution: It is important to be very careful when using internal MCLR and internal RC oscillator mode on a device when using the ICD2. Since the ICD2 can not control the MCLR and it can not control the Vdd supply voltage of the part, a device programmed for internal MCLR and internal oscillator mode will often start running before the programming sequence begins. This can cause programming to fail, or in other cases, cause all manner of unusual behavior to be observed.

For example, one customer was using a PIC16F688 with an ICD2 and programmed the configuration bits to set the part to internal MCLR and internal oscillator mode. They also had code configured to write to the EEPROM memory on startup. The result was the EEPROM was written before the ICD2 could verify the EEPROM, and the device would appear to fail verify for what seemed like a mysterious reason. Disabling either or both internal options (setting them for external mode) cleared up the issue.

In other cases, a customer may find that the device can only be programmed with their code one time, and after that, the device will not respond to further programming attempts. Most likely they read an unusual target ID such as 0x0 or 0x3FF from the ICD2 unit. This is because when their code ran, it set the pins used for programming (usually GP0 and GP1 or RA0 and RA1) to outputs, and this conflicted with the programming sequence. The conflict occurs since the part start up faster than the programming sequence from the ICD2. The end result is the part can not be reprogrammed unless a different programmer, such as a PM3 is used. The other programmer is needed, since it can control Vdd directly and prevent the part from starting up before its programmed. As mentioned earlier, the ICD2 does not control Vdd directly, and even if it is programmed to supply Vdd, it does not control the time the Vdd appears to the device.

A good workaround to this is to either not use both internal MCLR and internal RC oscillator mode. However, if that is not a reasonable solution, than another good option is to simply program a small delay into the code that the PIC will run on startup. The delay will prevent the I/O lines from becoming outputs too soon after power-up and that will allow the ICD2 to still be able to reprogram the device. Finally, if that is also not an option for your design, use a production programmer such as a PM3. You can find out more about the PM3 at:
http://www.microchip.com/PM3

發表於: 2007/2/24 1:49
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


PIC12F675 MCLR programming ERROR
#1
中級會員
中級會員


查看用戶資訊
MPLAB ICD 2 does not support programming this device if both the internal oscillator and internal MCLR are selected. You may continue programming, but you are encouraged to cancel, reconfigure your device, and try again.
我有一個問題
因為我接腳不夠用,需要6個I/O
所以GP3也得使用
但是ICD2卻出現上方的錯誤
這是不是說,如果使用內部RC震盪就得同時啟用MCLR做RESTART?
要怎麼做才可以用6個I/O呢?

發表於: 2007/2/22 21:17
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部







You can view topic.
不可以 發起新主題
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create PDF files.
You cannot get print page.

[進階搜尋]


:::

Microchip連結

https://www.facebook.com/microchiptechnologytaiwan/
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=13
https://mu.microchip.com/page/tmu
http://elearning.microchip.com.tw/modules/tad_link/index.php?cate_sn=1
https://page.microchip.com/APAC-PrefCenters-TW.html
http://www.microchip.com/
http://www.microchip.com/treelink
http://www.microchipdirect.com/
http://www.microchip.com.cn/newcommunity/index.php?m=Video&a=index&id=103
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=2
http://www.microchip.com.tw/Data_CD/eLearning/index.html
http://www.microchip.com.tw/RTC/RTC_DVD/
https://www.microchip.com/development-tools/
https://www.youtube.com/user/MicrochipTechnology
[ more... ]

教育訓練中心

!開發工具購買
辦法說明 [業界客戶] [教育單位]
----------------------------------
!校園樣品申請
辦法說明 [教師資格] [學生資格]
----------------------------------