>I have four identical prototype boards with PIC16F877s and 4MHz ceramic >resonators (with built-in caps). Three of the four boards work great, but >the fourth has startup problems. And since oscillators and crystals are >still black magic to me, I'm a little clueless what to look for. > >Symptoms: sometimes it never comes to life at all when powered up, and >scoping the resonator shows me a flatline. Sometimes it does come up, but >usually after a delay. Sometimes just scoping the resonator, or touching >pins around the resonator, kicks it into life, at least momentarily. >(There's an led startup sequence so I can see it's progress, and >sometimes it gets part way through then freezes, other times it starts up >and keeps going.) Once it ran for a minute or so then just stopped in its >tracks. > >Thanks for any debugging suggestions, this is an area I need to learn >more about, obviously :-) > >Dave Johnson Dave: 1. Make sure you have CONFIG set to XT osc. 2. Put a 1 megohm resistor across the OSC pins and see if that makes a difference. 3. You DO have the middle (GND) pin of the resonator connected, right? It should go straight to the Vss pin of the device. 4. Look at your power supply filter cap size and its effect on Vdd ramp up time. Reg Neale