|
|
View previous topic :: View next topic |
Author |
Message |
FUMIO
Joined: 25 Jan 2010 Posts: 1
|
ICD-U40 download error with OSC board |
Posted: Mon Jan 25, 2010 6:39 am |
|
|
Hello.
I have used PIC about 5 years with using CCS compiler, and
I have had this problem and tried to solve many times, but still can not.
So, would you give me advice?
<Problem is>
When I use crystal input hardware board (OSC1 & OSC2),
always ICD can download correctly, and it works well.
But, when I use CMOS OSC input hardware board (just use OSC1, open OSC2),
always CCS software shows the download error (can not find target device!!!).
This is not Hardware board issue, because my colleague develop the software with using ASM, and download it correctly with PIC writer. (http://akizukidenshi.com/catalog/g/gK-02018/)
Here, I inform you the test condition as below,
<Condition is>
ICD version:ICD-U40
CCS version:3.249
setting is as below,
#include <16F873A.h>
#fuses HS, NOWDT, NOPROTECT, PUT, BROWNOUT, NOLVP
#use delay (clock = 12000000)
... |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Jan 26, 2010 4:58 pm |
|
|
I don't have the ICD-U40, so I can't test this problem.
But let's think about it. What is the difference between a crystal and
an external oscillator ?
1. Is the oscillator running at +3.3v, but the PIC is running at +5v ?
That could cause a problem. The oscillator's high level output voltage
would not be within specification to work with the PIC.
2. Is the oscillator running at +5v, but is it only specified for TTL level
output levels ? (not CMOS). This could cause a problem. The oscillator
needs to be have +5v CMOS output levels. Sometimes oscillators
are called "TTL/CMOS compatible". That type will work.
3. The external oscillator has a "startup time" delay. In this ECS
data sheet, it shows the startup time for 12 MHz oscillator is 5 ms,
maximum:
http://www.ecsxtal.com/store/pdf/ecs-200x.pdf
The 16F873A data sheet says, in this section, that the typical duration
of the Oscillator Startup Timer (OST) is 1024 Tosc. For a 12 MHz crystal,
this is 85 usec.
Quote: |
17-5: RESET, WATCHDOG TIMER, OSCILLATOR START-UP TIMER,
POWER-UP TIMER AND BROWN-OUT RESET REQUIREMENTS
|
That's very quick, compared to 5 ms for the external oscillator.
It's possible that this is the cause of the problem.
Here is an idea. Set the 'PUT' fuse. This will cause a 28 ms minimum
delay before the PIC starts running. It's possible that the ICD-U40
will look at this fuse, and adjust its operation. I have no idea if this
will work. I don't have the ICD-U40 to test. It's just something to try.
Example:
However, I believe it's more likely that you are using a TTL output level
external oscillator, and that's the cause of the problem.
Notice that on this TTL compatible oscillator, the Voh is only 2.4 volts:
http://www.ecsxtal.com/store/pdf/ecs-100x.pdf
That's not high enough for reliable operation with the PIC.
But notice that on this TTL/HCMOS oscillator, the Voh level is 4.5 volts:
http://www.ecsxtal.com/store/pdf/ecs-200x.pdf
You must use the TTL/CMOS type of oscillator. (I am assuming that
you are running the PIC at +5 volts). |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|