View previous topic :: View next topic |
Author |
Message |
shahs
Joined: 14 Oct 2009 Posts: 1
|
How to make the burned PIC16F unreadable ? |
Posted: Thu Oct 15, 2009 7:05 pm |
|
|
Hi guys..
I am using PIC16F as a controller to my project. Lately my project was copied illegally including the source code of the controller. Now I am doing a few more projects and using PIC16F as a controller. I appreciate very much if anybody can help me how to add some source code to prevent people copying the program from the PIC16F.
Thank you.
shahs _________________ PIC16F |
|
|
John P
Joined: 17 Sep 2003 Posts: 331
|
|
Posted: Fri Oct 16, 2009 7:13 am |
|
|
My understanding is that you can't do this just with software. If the thief can read your processor, he'll get all the code that's in it.
You have to go back to the programming algorithm and set the top bit of the configuration word to a 0. This causes readout of the program to fail. Then all a criminal would be able to do would be to wipe the memory, not read it. |
|
|
Jerson
Joined: 31 Jul 2009 Posts: 125 Location: Bombay, India
|
|
Posted: Fri Oct 16, 2009 10:10 am |
|
|
First of all, the copier cannot get your source code unless he has access to your PC. He CAN get the binary image of your program and reverse engineer it to get an ASM file. However to add features it will be difficult since most address branches are hard set in the image.
Now, to your question how to secure an ordinary controller.
To the best of my knowledge, every microcontroller that has security is NOT totally secure. You can see statements to that effect in almost every manufacturers' data sheet. It all comes down to the last lock bit that is put on the device. Similar to breaking into a house, once you break the lock on the main door, it is easy to break into the rest. There are some excellent articles on this on some Latvian / Russian sites. I do not have links since I read this long ago. There are people who break locks in under 5 mins but they need a minimum of 2 devices to do that.
From memory, these things can help you in the order of importance/safety
After programming your IC
1. blow out the MCLR pin
2. break it away
3. blow out or break the ISPDAT/ISPCLK pins
4. Encapsulate with hard epoxy your entire circuit with trick wires that get broken along with the epoxy.
Do let us know what works for you _________________ Regards
Jerson Fernandes |
|
|
Guest
|
|
Posted: Fri Oct 16, 2009 6:08 pm |
|
|
Good tips about breaking the MCLR pin - that will slow a bloke down a bit. As for Epoxy, that will slow down a fellow, but not a determined one. There are always solvents or just applying hot air and dental picks will make fast work of removing Epoxy.
I say - nothing is unbreakable - We all know that, so set the security bits on the device, program in some special codes in EEPROM so that the program won't run without them, break the MCLR pin if you want to.
Then sit back and work on the next project, and be happy.
Even Cisco Systems gets firmware images ripped off from them.
;-)
HTH - Steve H. |
|
|
SherpaDoug
Joined: 07 Sep 2003 Posts: 1640 Location: Cape Cod Mass USA
|
|
Posted: Sat Oct 17, 2009 7:15 am |
|
|
It comes down to the balance of the time and effort of the code you are protecting, verses the time and effort spent protecting it.
"Good ideas are worth their weight in gold. Unfortunately ideas don't weigh anything." _________________ The search for better is endless. Instead simply find very good and get the job done. |
|
|
|