Hi JohnYou have overfilled the PIC memory and it has two solutions one is to use same pin-configuration PIC with large memory (easy but money consuming solution); the other is to customize the code to fit in the memory but that will be bit tough as 24% extra bit you have to modify or removed. So you can now choose which one you like to do..

As you can see the order shown is in order of memory size.The only way of know how much memory code uses is do what you have already done..Compile to hex.Then rom usage is displayed as you have highlighted.Just remember to divide value of rom shown by 1024 to convert to kbytes.Taking your Flowchart and an example: ROM used = 2539.= 2539/1024= 2.48KAccording to datasheet for your device ROM =2KTherefore you will require a ROM size of 4K minimum (Kwords).

There are ways of reducing code. E.g use local variables. Place frequently used calculations within a macro and so each time calculation is required, just use call macro function. use a Temp variable for several comparisons.instead of oldVar1= NewVar1NewVar1 = inputIf oldVar1 <> NewVar1 then variable has changed.

This information is like finding the pot of gold at the end of the rainbow.

Pot of Gold.jpg (1.96 KiB) Viewed 1678 times

I was on the Digkey site trying to find a chip I did not try Microchip. I will follow your information and see if I need a new chip.

I have been trying to strip down and redesign my project and see if I can get it to fit.

So I suspect this coming week between setting up for Xmas I will be trying to clean up my code.

I see the heavy part is sending out the display. I was reading over the OLD design and they used a Table for On state and a Table for off state but in "C' it use the IF then and I think it takes a little more RAM.

Martin seeing I have switches and Led in the Project Panel does that add into the RAM calculation for HEX ?