Guidance for developing for PIC16F15214 please

Enhanced mid-range devices. PIC12F1xxx and PIC16F1xxx

Guidance for developing for PIC16F15214 please

Postby electrotechie » Tue Nov 23, 2021 2:28 pm

Can someone guide me (or point me to the relevant doc) on my first development for PIC1F15214 please.
I found and bought a PIC16F15244 Curiosity Nano Evaluation Kit and have a the blinking demo program working and I can operate the debugger of MPLAB 5.5 on it. So far so good.

I was hoping that, because the PIC1F15214 looks like a subset of PIC16f15244 that I would be able to develop on the latter (obviously only using the subset of facilities) then deploy on the smaller chip.

I tried simply changing the chip id in MPLAB v5.5 but it simply generates lots of errors when I tried to build it, so it isn't that trivial.

So, is this strategy wise or should I wait and set my own debug system up with a a PIC1F15214 and buy the MPLAB PICkit 4?

I am feeling overwhelmed by the documentation at the moment. I know a reasonable bit about software and electronics but am new to Microchip and MPLAB.
If someone can point me to guidance docs about how to proceed, it would be much appreciated.

Thanks in advance, Ray
User avatar
electrotechie
 
Posts: 2
Joined: Tue Nov 23, 2021 1:22 pm
Location: Glasgow, sometimes France

Re: Guidance for developing for PIC16F15214 please

Postby ric » Tue Nov 23, 2021 8:31 pm

The PIC16F15244 and PIC16F15214 are very similar chips, so yes you can do your development on the bigger chip and just not use the extra pins.
The IDE will not program code into a different chip to what is specified, so you cannot pretend one chip is another during debugging.
How are you planning on programming the PIC16F15214? It would be easiest to provide an ICSP connector on whatever target board you design.
Once you have that, you can compile for PIC16F15214 and program normally.

It would be helpful to mention WHAT errors you got when you tried changing the chip name.
Latest test project, an LED matrix display made from one reel of addressable LEDs. here
User avatar
ric
Verified identity
 
Posts: 659
Joined: Sat May 24, 2014 2:35 pm
Location: Melbourne, Australia
PIC experience: Professional 5+ years with MCHP products

Re: Guidance for developing for PIC16F15214 please

Postby electrotechie » Thu Nov 25, 2021 8:30 pm

Thank you for replying Ric.

I realise that I would have to provide an ISCP link (probably pogo pins) on the target board in order to program the production chips.
What I will probably start with is the DIP version for the first prototype. A colleague is doing the hardware work; I am mostly just software. The final target board will be really small, around 10mm*15 and rather crammed so no real room for (or really the need for) a normal pin connector (I am told). The programming pins will be used as I/O on the target but will be disconnected from anything else for programming.

Thanks for confirming that my source code will run OK on the 14 as long as I stick to the limitations of the smaller chip.

Reading through some of the files, I now realise that MPLAB reconfigures all the software with different .h files (and I presume different libraries), for each type of PIC, even within a family. I think that the errors I caused by simply changing the PIC type in an already configured project are a bit of a red herring, there were hundreds - it is clearly not the way to go.
I guess what I will do is to configure a separate project for the PIC16F15214 and use the configuration tool to mimic the setup of the pins, timers and pwm module between the two projects synchronise the main.c file - basically try to keep two projects in sync. I had to do something like that between the nRF52 range of chips when developing in Segger.

I liked the Curiosity Nano Evaluation Kit because it is so elegant, just plug into usb and go, no need for wires, plugs, target power supplies etc. I am sure I will get to the stage where all that will be necessary, but meanwhile I will press on with the Curiosity Nano Evaluation Kit to familiarise myself with the PICs.
In due course I will buy a Snap-in or Pickit 4 tool to program the devices on the pre-production run.

The application is relatively trivial, just putting out a variety of pulses of different frequencies and m/s ratios depending on slow moving inputs on 3 pins. No great accuracy or responsiveness required.

Thanks once again for explaining - it is tricky when first starting in an unfamiliar development environment.

Ray
User avatar
electrotechie
 
Posts: 2
Joined: Tue Nov 23, 2021 1:22 pm
Location: Glasgow, sometimes France


Return to 14-Bit Core (enhanced)

Who is online

Users browsing this forum: No registered users and 8 guests