PBP3 Optimization & Peripheral Control Techniques on PIC16F/18F Devices
Hi all,
I’ve been actively working with PBP3 in several embedded control projects, mainly using PIC16F1939 and PIC18F26K22 MCUs. While I appreciate the cleaner syntax and broader device support in PBP3 compared to earlier versions, I’m now focusing on pushing performance and code efficiency — especially in timing-critical applications.
I wanted to discuss some tips:
Timers and PWM — I often need precise timer-based delays or PWM generation beyond what HPWM offers. Anyone using PBP3 with hardware timer overflow interrupts for finer control?
Integration with MPLAB X / Pickit 3 — I’ve kept using the stand-alone MicroCode Studio, but I’m wondering if anyone here has set up a clean workflow with MPLAB X for PBP3, including breakpoints and debugging?
Re: PBP3 Optimization & Peripheral Control Techniques on PIC16F/18F Devices
Quote:
Anyone using PBP3 with hardware timer overflow interrupts for finer control?
Yes, all the time and most times in conjuction with DT-Ints for PBP context save/restore. For periodic/cyclic interrupts using TMR2 (or one of the same type) is nice because you set it up once and then it takes care of itself while with TMR0 and TMR1 for example you need to reload it for the correct period each interrupt.
If the goal is to use timer interrupt for all sorts of delays then it doesn't really matter.
Quote:
Integration with MPLAB X / Pickit 3
Hate to say it but just forget about it. Apparently it used to kind of work, sort of, about a decade ago but Microchip has moved on an PBP hasn't kept up. I know I've tried several times but always went back to MicroCodeStudio.
PICKit3 on the other hand I still use with the MPLAB IPE software.
/Henrik
Re: PBP3 Optimization & Peripheral Control Techniques on PIC16F/18F Devices
Plus to what Henrik posted, if you want Pickit2/Pickit3 standalone software, there is also a (paid) version of the old stand alone but now developed and supported by Anobium https://pickitplus.co.uk/Typesetter/index.php/Software
Have used it for many years and it is updated frequently to support new chips (not that PBP will use it, but anyway).
Ioannis