# Making a change from TI MSP430 to PIC

#### StrongPenguin

Joined Jun 9, 2018
287
I've just ordered a PICkit 3 (which I found out became non supported in June..) because I thought I would like to give PIC a go.

Along with that I ordered a PIC16F877A-I/P DIP-40 and a PIC16F1615-I/P, because Google told me to. Am I missing something to get the same coding experience I got with my MSP430G2 board using Code Composer Studio? I REALLY liked that program, such a treat to watch all the registers change, when you are still trying to learn the MCU.

#### BobTPH

Joined Jun 5, 2013
3,319

Bob

#### StrongPenguin

Joined Jun 9, 2018
287
Ok, so I don't need a Curiosity board to get the same debugging experience as I had with CCS? I'm thinking setting breakpoints, watching registers, timers, ect.

#### BobTPH

Joined Jun 5, 2013
3,319
MPLAB can do that. When you make your board, include an ICSP header and this allows you to debug through the PICkit.

Bob

#### JohnInTX

Joined Jun 26, 2012
4,447
Rather than bare chips, consider the Curiosity HPC. It comes with an PIC16F18875 MCU and has a built-in debugger equivalent to the PK3 all ready to go - just add a USB cable. MPLAB-X / XC8 provide native support. The board has headers for pinning out IO and also for Mikro Electronica's mikroBus modules for comms and other functions.

If you must use the PIC16F1615 or are wanting to develop on small footprints, consider the smaller Curiosity board. It also has the debugger built in and is a few bucks cheaper.

Starting with Curiosity avoids all of the issues with setting up ICSP, power supplies etc. Just plug in the USB and get busy. You can deal with all of that other stuff later.

PK3 is obsolete. It likely won't support the latest stuff and eventually will be dropped from the IDE as well. I don't have any inside information to support this assertion except that I have many \$ worth of emulators and programmers and have scrapped many more that are no longer supported by the latest IDEs.

Note that the Microchip debuggers use debug hardware that is resident in the chip. The later 16F1xxx parts have at least 3 hardware breakpoints and some have software breakpoint capability for even more. How much debugging capability you get depends on the target chip you're using. Indecently, this is why the smallest PICs like the 10F stuff have their own 'header' boards for debugging. The actual chips are too cheap/small/low pin count to incorporate resident debuggers so Microchip provides special headers that recover the debug pins and add enough silicon to support debugging.

SCRAP the 16F877A. That is an old midrange part that just is not worth the trouble to use when compared to newer devices. Its sole debug capability is ONE breakpoint. That's it. Trust me. It's not worth the trouble. When you get done with getting around all of the midrange limitations, you'll have spent more time and money than you would have on a current chip and still be at a development dead-end. This from a guy who developed extensively on midrange, but a decade or two ago. Move on.

Good luck and have fun learning.

Last edited:

#### StrongPenguin

Joined Jun 9, 2018
287
Thanks for the replies and sorry for the late reply.

@JohnInTX I took your advice and bought a Curiosity Hpc, because I don't want to fiddle with the "other stuff" yet. And I don't want to spend my time on something that was in fashion 10 years ago, like I did with the MSP430G2553, though it was a good learning experience.

Do you know if the board will be compatible with newer types of the same PIC family, or is it just the one it's born with? Granted that Vcc, Gnd and Program pins stay the same.

#### JohnInTX

Joined Jun 26, 2012
4,447
Do you know if the board will be compatible with newer types of the same PIC family, or is it just the one it's born with? Granted that Vcc, Gnd and Program pins stay the same.
It should handle any 28 or 40 pin PIC that is capable of LVP (Low Voltage Programming) and that would include most if not all of the recent stuff. To know for sure you can 1) select the PIC of interest in MPLABX and the Curiosity HPC target (PKOB) and see if it's supported. 2) Go to the PIC's page on Microchip.com and look in the development tools/evaluation board section. If you see the HPC, you're good to go. You can also try the DTS (development tool selector) app on the web but I find it flaky at times.

Since the Curiosity uses only low voltage programming, you MUST enable LVP in the #pragmas / chip configuration. If you program one with your PK3 without LVP enabled, it won't work in the HPC until you erase it and enable LVP using the PK3 or another programmer. The HPC user's manual covers this.

I find the Curiosity boards useful for all sorts of quickie projects. They're cheap enough to just use as is in small qty projects.

Have fun!