USBDM for FXTH87xx11 ( security functions & download image )

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USBDM for FXTH87xx11 ( security functions & download image )

1,104 Views
marshuang
Contributor I

Dear All,

I have used FXTH87xx11 for couple month already.

The driver I used now is USBDM 4.10.6.250a.

I met a problem about setting of the security code @0xFFBF.

I can't update all the code by image file, because I need to keep the ID in the flash.

So, I choose FXTH87xx11 for device selection & Erase Selective for Erase option.

pastedImage_4.png

Put the code "const volatile char NOPT@0xFFBF = 0x00;" before Main().

When I try to update the code, there is a warning in the figure below.

I knew we set <memoryRange start="0x00C000" end="0xDFFF" /> for protect the default code.

I have no idea to change the value @0xFFBF.

Do any one know how to update it with security function?

For Example, update the address @0xFFBF only or put some commands in the code.

I also need to download the code from this chip, I can't get too much information on internet.

Please help me, thanks in advance.

Labels (1)
0 Kudos
5 Replies

709 Views
marshuang
Contributor I

um... I got the answer by myself.

<memoryRange start="0x00FFB0" end="0xFFBF" />

Add this to allow the writing in the code.

(const volatile char NOPT@0xFFBF = 0x00;)

0 Kudos

709 Views
pgo
Senior Contributor V

Hi Mars,

I would expect the change you made would cause the 512 byte sector containing that address to be erased since the Flash is being selectively erase before programming (using sector erase).

The sector would be from 0xFE00 0xFFFF.

Since this includes the reset vector I would expect problems.

What happens when you do this?

bye

0 Kudos

709 Views
marshuang
Contributor I

Hi pgo,

  ohhhh... thanks for your reply.

  After I did this, I have problem when it run in the freescale firmware.

  The code will stop in the address between 0xFE00 0xFFFF.

  Do you have any idea to setup security?

regards,

Mars

0 Kudos

709 Views
pgo
Senior Contributor V

Hi Mars,

The latest version of USBDM (V4.11.1.40) now includes a utility to read from an unsecured target.

You could you this to obtain a copy of the firmware from the FXTH81xx11 so that you can safely secure the device.

The method would be a bit complicated:

  • Use UsbdmMemoryDump to obtain a copy of the image from 0xC000 to 0xFFFF (please check this)
  • Using the standalone USBDM programmer :
    • Load the above image with the Incremental Load checkbox unselected
    • pastedImage_6.png
    • Select Incremental Load checkbox.
    • pastedImage_7.png
    • Load your image which should NOT overlap with the 1st loaded image.
    • Select the secured option
    • pastedImage_8.png
    • Program the device.
  • The above assumes that the Firmware doesn't do a checksum etc.

bye

0 Kudos

709 Views
pgo
Senior Contributor V

Hi Mars,

I'm sorry but the only way I could see to secure the target would be obtain a binary image of the Freescale code which could then be loaded into the programmer along with your code.  The security could then be set to anything you want in the programmer.

Otherwise I would expect the reset vectors to erased as above.

bye

0 Kudos