I have a WBX451, that's a BLE + blah module with a PIC32CX on it. I'm trying to program it with a PicKit4 using SWD. I have about 2 hour experience programming PIC controllers and 1.5 decade programming AVR controllers. This is where the module sits:
NMCLR, VDD, GND, SWO, SWCLK, NC, NC, SWDIO are the signals of the SWD_1 header. I stick it straight in the PicKit4 and go. It says "no good, you're trying at normal speed, why don't you try at low speed?". Well, because there's no such option. The speed (MHz) setting is simply ignored.
This is the logic analyser thing from what happens.
Hm. NMCRL should be active high. Here we see the exact opposite of it. I'm not sure why. The manual says that I may add a pullup. I may yes, like for the reset of an AVR. I have never in my life added a pullup and it has always worked. These things have an internal pullup. Then I have opened MPLAB IPE just to see if I find something useful there and I have found more confusion:
Program speed setting is there, but does this mean that I have to have the IPE open too just for this setting?? The speed in Mhz is there too, also ignored. But where the program speed setting is! What PGC? What PGD? These are signals of the ICSP! The PIC32CX has no ICSP! Or does it? There no sich pins in the datasheet. And what's about the pullup (or pulldown) resistors? The datasheet says nothing about resistors! Can I please get some directions with this thing!
Oh, I have nice 3.3V between the GND and the VDD pins. The GND and VDD pins of the header are connected to fills that you can't really see on the image. MPLAB actually says "Target voltage detected". What am I missing here?
Update: I have fixed a contact problem on the NMCLR. New logic trace:
So the NMCLR pulldown is there. From the duration of action I can tell that no matter what I do the programming speed stays the same.