There's so many things you can do, the limit is your own imagination...

If you have code protected your product, then it is reasonably safe as long as you don't have a bootloader installed and rely on ICSP or an external programmer to update your software. I use several methods depending on the value and copyability of the products by competitors...

Cheap products are code protected. They can only be code updated if the PIC is on a socket. We either send out a new PIC, or the product has to be returned to the factory for update.

Some high-risk products that need field updating have a specially written bootloader that will only work with our own host software. The PIC is usually surface mounted on the PCB and the PCB has liquid ceramic adhesive compound poured over it. You cannot get at the PIC or it's connections without destroying the device or the PCB.

Other products are fully copy protected and have ICSP circuitry on-board. They can be field upgraded the normal way using a programmer, although the code cannot be read back.

Some products also have the processor linked to an external Hardware device that will provide a Unique Serial Number. Only if your software matches that number then the software will run... this means that your PIC will ONLY function in the target PCB and nowhere else. The Dallas DS18S20 Temperature Sensor looks just like a Transistor... but contains a unique 64-bit Serial Number. If your software matches the number it runs, if it doesn't, then it won't. Some customers are not very trustworthy. They swap serial numbers between boards, then send old boards back 'under warranty'. The embedded serial number in hardware can prove those customers misbehaving.

Other products will stop working after a preset time and have to be reset by a field engineer.

Like I said... your imagination is your limit.

Melanie