Flash protection fuses

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I tried to search for this. I either got a blank screen or 380 pages of topics. When I clicked next or 2 for the second page I got the "No topics or posts met your search criteria" so search is not working today for me.

Anyway, I read the data sheet for mega128 regarding flash memory protection. If I program the fuses so Flash can not be read out, can the fuses be reset by using ISP to do a chip erase? I want to protect the flash contents from being read but do not want to render the chip unable to be erased and reprogrammed at a later time. Is this possible?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

can the fuses be reset by using ISP to do a chip erase?

Yes - that's how you clear the protection bits. It doesn't do the pirate any good because in the process he has to erase the code image you are trying to protect. By the way some folks are confused when ISP read of a locked chip appears to work - this is normal - study the data that's actually read it's just 00 00 01 01 02 02 03 03 and so on...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You can program lockbits so that flash cannot be read.

The punter can erase the chip via ISP, JTAG or HVPP.
This will clear the lockbits. However there is nothing to read in an erased chip !!

You can prevent the punter erasing the chip if you remove the SPIEN and JTAGEN fuses. (she can still use HVPP)

In practice, the lockbits are perfectly adequate protection.

Another approach is use an encrypted bootloader with SPIEN and JTAGEN removed.

This will enable you to upload anything that you want. But still have complete control on what you give the punter. i.e. she can upload the encrypted file, but she will not be able to decrypt the file herself.

If your IP is worth $millions, then someone will find a way of stealing your ideas. Most apps are cheaper to rewrite from scratch.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So for the Mega128 I would program both lock bits to zero?