Pickit 3 clock signal quick check? are my signals ok? - Page 1
Forum section: electronics / general

author: jon6123
author_rank: Contributor
timestamp: February 24, 2017, 02:45:46 pm
content: Hi all,trying to program a PIC24FJ128GC010http://www.microchip.com/wwwproducts/en/PIC24FJ128GC010however no dev boards (or PIM dev mounts) available so quickly made my own rig seen belowI am struggling to get the two to communicate at all, MPLAB IPE keeps giving metarget ID 0x0which says to me there is no connection to the device3.3v is present(externally not through pickit 3),100nf capis present over Vdd-GND,10k resistor between MCLRand Vdd is there anything else I need? :SI have double/triplechecked connectivity under a microscopeon the exact pins so i know theres no problems therewhy won't she talk to me?I have checked on an oscilloscope looking at MCLR and CLK/DATA pins what I see is below:CLKDATAthis is the same whether my rig is connected or not which I find strange?should there not be a clock signal after the MCLR blip? or does the pickit programmer wait for some sort of response from the device before starting the clock?looking at the programmer documentation (from the specific device webpage "documentation" tab)http://ww1.microchip.com/downloads/en/DeviceDoc/39970e.pdffigure 3-4shows a clock pulse after the MCLR blip?from dataasheetcould someone who knows a bit more about PIC programmer signals confirm whether my signals are correct?pulling my hair out at the momentCheers allJono

author: JPortici
author_rank: Super Contributor
timestamp: February 24, 2017, 02:53:04 pm
content: clk/data are the same pictureso you confirm that you made the connections at page 33 of the datasheet? (for now you don'tneeda 100n cap at every vdd/vss pair, but at least one. and VCAP is required of course)

author: Ian.M
author_rank: Super Contributor
timestamp: February 24, 2017, 03:49:43 pm
content: *ALL* Vdd pins must be connected in parallel, as must all Vss (Gnd) pins. When bringing up a chip for the first time its advisable to include AVdd with Vdd and Avss with Vss etc.The PICkit 3 Vdd pin must be connected even if it isn't supplying power, as its used as a reference supply to the level-translating buffers.Does the breakout board have the Vdd to Vss decoupling caps, and the Vcap core decouplinc cap mounted directly on it? If not the odds aren't good . . . .

author: hans
author_rank: Super Contributor
timestamp: February 24, 2017, 05:44:42 pm
content: Don't forget VCAP.Place 100nF on the breakout board, not on the adapter board. You could maybe solder them between the TH holes, because usually they are right next to each other.Also apply VDD/GND on every VDD/GND pin pair.

author: jon6123
author_rank: Contributor
timestamp: February 24, 2017, 08:28:06 pm
content: Hi guys,thanks for your replies,JPortici they aren't the same picture they are just almost identical, not sure if they are correct signals for a no-pic-connected situation?The breakout was made up by me, no caps involved. I was unable to find a VCAP capacitor for now, was under the impression it wasnt critical, perhaps I was wrong?I will try applying Vdd and gnd to all pins(&AVdd,AVSS), get hold of a VCAP and also put 100nf across VDD gnd on ONE pair and get back to you, otherwise its going in the bin unfortunately >:C fast running out of time on this university projectThanks again

author: bktemp
author_rank: Super Contributor
timestamp: February 24, 2017, 08:43:25 pm
content: Quote from: jon6123 on February 24, 2017, 08:28:06 pmThey shouldn't look identical, both look like MCLR or maybe PGD signal. Check your wiring if all 5 signals from PICkit are connected correctly.QuoteVCAP is for the core voltage regulator. The CPU does not work correctly without a stable core voltage. It is very important.If you don't have 10uF MLCC, you can also use 100nF + 10uF electrolytic capacitor. This is not the best solution, but works if you don't have anything better.

author: Ian.M
author_rank: Super Contributor
timestamp: February 24, 2017, 09:02:31 pm
content: Long skinny Vdd and Vss traces have too much self-inductance for decoupling caps at the far end of them, away from the chip to be effective for high frequencies. Microchip recommend a maximum trace length of 6mm between the pin and the cap.The easiest fix would be to stick a square of copper foil tape to the top of the chip with enough margin round the edges to solder SMD caps to it at their inner end without their outer end overhanging. Tie all Vss pins to the foil with strands of tinned copper wire. Add a SMD 0.1uF decoupling cap above each Vdd pin and tie the outer ends together, each to the next with Knynar wirewrap wire. Link each decoupling cap to its Vdd pin. Add the Vcap cap for the core and tie it to the pin. If you don't have a 10uF MLCC handy, a 10uF Tantalum will work, or you *may* be able to get away with 0.1uF right at the pin + 10uF low ESR electrolytic at your breakout header. *DO* *NOT* tie Vcap to the linked Vdd pins.Double-check ICSPCLK connects to PGEC2 (pin 26), annd ICSPDAT to PGED2 (pin 27). If youv'e mixed them up it wont work. Nor will it work if you split programming pin pairs. i.e. the PGECn and PGEDn pins must have the same n.

author: JPortici
author_rank: Super Contributor
timestamp: February 25, 2017, 01:01:01 am
content: I've always found pic24 to be a great pain in the ass to work with. every PIC24 i have had to deal with needed special attenction.. dspics aren't this picky. they will work at room temperature in the lab with all the abuse they can take and then some. but pic24? they won't.so: set up the minimum circuit from the datasheetthen, ok you have a 2 chan scope but it's more important to see PGD/PGD than MCLR/PGD(or)PGC, once you have verified that the MCLR timing is correct

author: hans
author_rank: Super Contributor
timestamp: February 25, 2017, 11:00:44 am
content: Let's not make things more complicated or ranty than they are. Connecting a PIC24 should be just as trivial as connecting a PIC16, an ATMEGA or even most of the newer ARM cortex m-series microcontrollers.You need to apply VDD/GND on every pair.Place a 100nF cap close by. Do your best effort, but I would take manufacturers recommendation with a grain of salt if this is for hobby. I've had horrible prototyping setups on breadboards with capacitors that untrimmed leads & unknown sources, and it works.VCAP is absolutely necessary. It's for the core regulator and it wont work without it. I guess this is at fault and needs to be fixed first. 10uF aluminum always worked fine with me. On PCBs I usually stick on ceramic though, because of available sizes.Also a 10uF on VDD is not a bad idea.1 or 10k pull-up to VDD on MCLR pin. Connect directly to PICKIT. No diodes, caps, etc.Connect ICSP PGC/PGD pins without any caps, resistors, etc.Connect VDD/GND ot PICKIT3.Even a PICKIT3 should be able to power this circuit itself. Just make sure you don't try to power external and PICKIT3 both at once (it could damage the PICKIT3).

author: snarkysparky
author_rank: Frequent Contributor
timestamp: February 25, 2017, 08:27:07 pm
content: Once had a driver glitch in my pickit 3. Actually the driver in the new MPLAB was bad and the fix was to download an older mplab and connect with it. It was giving wrong device ID error.

author: jon6123
author_rank: Contributor
timestamp: February 27, 2017, 03:19:42 pm
content: Hi all,thanks again for your input on this noobie topicI have updated my setup to include:- the 100nf as close to the chip as possible- a tantalium 10uf VCAP to ground- applied 3.3v and GND to all Vdd and Vss and AVdd and AVss pinshowever still no response, just the ID = 0x0 error again.Can anyone confirm that the readings from the two osc screenshots are correct?Yellow = MCLRBLUE = PGCYellow = MCLRBLUE = PGDThese screenshots were taken WITHOUT the PIC24F connected, I am surprised that there are no signals coming from the pickit 3 after the MCLR drop??Can someone confirm that this is what the Pickit 3 should be doing?Also, this specific devicePIC24FJ128GC010doesnt have a PIM dev board mount (which is why i decided to make my own) and the only dev board is £150+, how is one supposed to develop for this chip without shelling out for thechip specificdev board?? this device isnt new its a fair few years old, i find it surprising how little support there is for it...

author: bktemp
author_rank: Super Contributor
timestamp: February 27, 2017, 03:39:48 pm
content: PGC, PGD and MCLR should have 3.3V levels.MCLR looks ok, but PGC and PGD look more like 300mV.Is one probe (for PGC/PGD) set to 10:1 and the other one (for MCLR) to 1:1?If not, check if 3.3V is connected correctly to PICkit and verify there is no short on PGC and PGD to GND.

author: jon6123
author_rank: Contributor
timestamp: February 27, 2017, 03:51:58 pm
content: Hi bktemp,Yes actually you are correct the probe was set to 10x..new images with 1x..MCLR/PGD:MCLR/PCG:this screenshot seems more appropriate for data line, thanks for your comment now I can rule out the pickit programmer as the issue

author: bktemp
author_rank: Super Contributor
timestamp: February 27, 2017, 03:59:51 pm
content: Both signals look ok now.If they are connected to the correct pins, the PIC should be detected by MPLAB.

author: NivagSwerdna
author_rank: Super Contributor
timestamp: February 27, 2017, 05:14:15 pm
content: I had the same issue a while back..... VCAP was the answer to my problems. Programming wouldn't work at all without it. Totally undocumented as far as I could see.

author: JPortici
author_rank: Super Contributor
timestamp: February 27, 2017, 06:00:53 pm
content: capacitor on vcap is required for stabilization of core voltage say the datasheet... if it's not enough the programmer should also give a warning of insufficient vcap capacitance

author: 22swg
author_rank: Frequent Contributor
timestamp: March 15, 2017, 08:51:24 pm
content: Quote from: JPortici on February 25, 2017, 01:01:01 amI don't know why, I've Never had " special attentions" ? with any of the PIC24 devices FV, F, H, or E any package... just follow the data sheet power requirements to the letter. all the Vcaps, caps all the Vdd Vss pin connects include USB 3.3v if provided. Run the mclr via a 100R to the pin and pull up with a 10k . power device externally always.. don't have long ICSP wires or other possible interference, ICSP no voltages on pin 6. PK3 load the latest FW.(1-44-26) Use a USB cable with a ferrite block on it.