Problem with 877

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 2 and 3.

Moderators: Benj, Mods

Post Reply
Billm
Posts: 8
Joined: Thu Sep 07, 2006 1:33 pm
Contact:

Problem with 877

Post by Billm »

I have been using version 2 for some time but have today tried to use an 16F887A no matter what code I write I have the same problem it runs fine in simulation, works OK in the programer board but when I try the chip in the target board it will run but with incorrect timings for a short while but then the Xtal clock stops and the chip seems blank. If I try the chip in the programmer the code does not run, I can then reprogam the PIC and it will run the code OK in the programer again. I Made a lash up to run the chip on veroboard and the same happens. I have written a simple loop to toggle 1 pin ad it also happens with this.. Have I missed something simple.... Clock is set to Xtal 4.0Mhz Mclr set Hi

Help......

Mark
Posts: 209
Joined: Thu Oct 19, 2006 11:46 am
Location: Bakewell, UK
Has thanked: 20 times
Been thanked: 16 times
Contact:

Post by Mark »

Billm,

All seems stange to me. However, self erasure of memory should not normally be possible, particularly if you are not using low voltage programming or any special on chip self programming code.

I suggest you check the clock circuit, put an oscilloscope or frequency meter (such as on a multimeter) on OSC1 and see if you are getting any oscillation.

Crystals usually use two low value capacitors, howerver, copper tracks can themselves act as low value capacitors and the track layout of you project board may play a role here (try a ceramic oscillator with in-built capacitors to minimise this). I asume from your post that you are using the Xtal configuration and not the HS configuration, 4MHz seems to be on the border of what HS can take.

Also for what it is worth, try another chip, it is possible that you have a faulty one.

Hope this helps,

Mark
Go with the Flow.

Billm
Posts: 8
Joined: Thu Sep 07, 2006 1:33 pm
Contact:

877

Post by Billm »

Thanks I found a similer fix on the Electro Tech site . I Disabled LVP on the configration screen and it seems to run OK now both in the lash up as well as the target board . The LVP setting is default enabled. Thanks for the help.

BillM...

muxer107
Posts: 8
Joined: Fri Apr 27, 2007 2:39 pm
Contact:

same!

Post by muxer107 »

Just wanna say I had the exact same problem, took me two hours of porlbem solving before I figured this out!

There really should be a note somewhere!
Muxer

Post Reply