Fail to program FXTH87xx11 using USBDM

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

Fail to program FXTH87xx11 using USBDM

Jump to solution
10,836 Views
sunrme
Contributor III

Hi all,


I tried to use USBDM to program the FXTH87xx . But in the list of chips in Flash Programmer this MCU is absent. So, I insert this in the hcs08_devices.xml:

     <!ENTITY HCS08-alt-load-flash SYSTEM "HCS08/FXTH87xx11_Starter_Project_CW10.abs.s19">

     <flashProgram id="HCS08-alt-load-flash">

          &HCS08-alt-load-flash;

     </flashProgram>

     <device family="HCS08" name="FXTH87xx11">

          <memory type="ram">

               <memoryRange start="0x000090" end="0x00028F" />

          </memory>

          <memory registerAddress="0x1820" type="flash" securityAddress="0xFFB0">

               <securityEntryRef ref="HCS08-fnored-security"/>

               <memoryRange start="0x00C000" end="0x00DFBF" />

          </memory>

          <sdid value="0x002C" />

          <flashProgramRef ref="HCS08-alt-load-flash" />

     </device>

I'm not sure thay I use right values especially securityEntryRef section. But now flash Programmer detect my chip. But when I click Program Flash, on EraseMass status pop up error:

17375_17375.pngnew error 2.png

Hope someone can help me.

Regards

Labels (1)
Tags (3)
1 Solution
6,763 Views
pgo
Senior Contributor V

Hi Sunrme,

Could you change the end address in the XML file to 0xDFFF as it appears that there is a pseudo-vector table to be programmed as well.  Also remove the references to security - in other words use the following:

  <device family="HCS08" name="FXTH87xx11-Partial-Erase">
     <memory type="ram">
        <memoryRange start="0x000090" end="0x28F" />
     </memory>
        <memory registerAddress="0x1820" type="flash">
           <memoryRange start="0x00C000" end="0xDFFF" />
     </memory>
     <sdid value="0x002C" />
     <flashProgramRef ref="HCS08-alt-load-flash-program" />
     <note>Untested</note>
  </device>

Make sure you select EraseSelective when programming.

pastedImage_0.png

bye

View solution in original post

0 Kudos
47 Replies
2,378 Views
pgo
Senior Contributor V

Hi Sunrme,

I have ordered a chip and if (big IF) I can mount it properly I will experiment with programming it.

It should be possible to debug as well with  a bit of work - It may be necessary to add and image for the internal flash routines.

I will look at this in a while :smileyhappy:

bye

0 Kudos
2,378 Views
pgo
Senior Contributor V

Follow-up

OK my sample arrived and with access to this I am able to do a proper job.

The first thing I did was create an image of the chip contents.  This allows the chip to be returned to a "factory fresh" state if the firmware is accidentally erased.

Any way I have attached the following:

  • Image from a FXTH870511, FXTH870511_Image.sx  I hope this is OK. If not Freescale can feel free to delete with accompanying rude words.  I presume they won't object since the image is unprotected in the device and easily read.
  • Updated device file hcs08_devices.xml  This adds three devices FXTH870000, FXTH87xx11-Full-Erase and FXTH87xx11
    • FXTH870000 This is an alias for use with Codewarrior and doesn't appear in the stand-alone programmer.
    • FXTH87xx11-Full-Erase This is a device entry that allows completely unprotected programming of the device.  This can be used to re-program the device with the above image using mass-erase.
    • FXTH87xx11 This is an entry that only allows programming the intended user area of the Flash.  Due to limitations in the USBDM programmer it is not possible to prevent you from mass-erasing the device  - You have to manually select selective erase.

Further tips:

To restore an accidentally erase device

  • Load the above image FXTH870511_Image.sx
  • Select Image for security
  • Select EraseMass
  • Program and verify to check it's OK

pastedImage_29.png

To program a user program (restricted to user flash area)

  • Load the above image file .....
  • Select Image for security
  • Select EraseSelective
  • Program and verify to check it's OK

pastedImage_47.png

To use with Codewarrior

  • Create project in usual way with a USBDM target interface.
  • Modify the USBDM options as shown below
    • Security field from flash image (there won't be one)
    • Selective erase (by sector)
  • You should be able to debug in the usual fashion

pastedImage_48.png

PS.  Want to see the prototype?  I can't really see it lasting long inside a tyre!

pastedImage_0.jpg

bye

2,374 Views
xiaalina
Contributor I

Hi, pgo ,

            I read all your solution about  USBDM  failing to program FXTH87XX11,I want to know how  can i get the information about FXTH870000, FXTH87xx11-Full-Erase, FXTH87xx11 .

          I only have the data about FXTH87xx11 ,as follows

<device family="HCS08" name="FXTH87xx11-Partial-Erase">
    <memory type="ram">
       <memoryRange start="0x000090" end="0x28F" />
    </memory>
       <memory registerAddress="0x1820" type="flash">
          <memoryRange start="0x00C000" end="0xDFFF" />
    </memory>
    <sdid value="0x002C" />
    <flashProgramRef ref="HCS08-alt-load-flash-program" />
    <note>Untested</note>
</device>

  now I can not debug with usbdm,also I can not program my device with USBDM.

   when I program my project, I got this. please can you help me? I will be very grateful. thank you.

pastedImage_5.png

0 Kudos
2,374 Views
pgo
Senior Contributor V

Hi Xia,

Could you post your request to an entirely NEW thread - this one is a mess and it is very hard to follow (at least I find it so).

Please provide the following:

  • The exact part number of the device you are using
  • A link to the reference manual for that chip
  • Re-post the above information for completness

Thank you

0 Kudos
2,374 Views
xiaalina
Contributor I

hi, pgo

I have build a new request, click this :

https://community.freescale.com/message/596675#596675

0 Kudos
2,374 Views
xiaalina
Contributor I

hi

pgo,I have build a new request, click this :

https://community.freescale.com/message/596675#596675

0 Kudos
2,374 Views
xiaalina
Contributor I

Hi, pgo ,

            I read all your solution about  USBDM  failing to program FXTH87XX11,

0 Kudos
2,374 Views
jiangboli
Contributor I

Hi pgo,

Your answers are very helpful,But I still have some questions:

When I program my FXTH87,I Select the EraseMass by mistake,so I refer to your method that To restore an accidentally erase device.Now I want to know where did you get the image FXTH870511_Image.sx.

I need the FXTH870911_Image.sx because I am using the  FXTH870911DT1.I can't find it on the www.freescale.com,so i can't return to a "factory fresh" state(FXTH870911DT1).

Where can i get the FXTH870911_Image.sx?


Looking forward to your reply.

0 Kudos
2,374 Views
sakthivelkuland
Contributor III

Hi All together,

i'm also facing same kind of issue, with Debugger Mode .Firstly i'm working with FXTH870911 434Mhz TPMS Sensor.I have facing the problems like I not able to debug the Sample Code and no sample code executing int he EVB.

#1.I have downloaded Startup Code from free scale there i faced issue with Firmware JUMP Location (0XE003). This i have got clear SW not able to access the address location.

#2. Then i have downloaded the Sample code "FXTH87XXXX PERIODIC RF TRANSMISSION CW10" and flashed with EVB, I have selected FLASH_434_2_AXIS Vehicle Type .s19 file. Please note very first time FR DATA have been transmitted i have used Spectrum Analyzer to test the FR Signals. Then i have modified the transmitted Data size and flashed this time code not working no RF Data Transmission, then i have revert back to original code and flashed this time also no RF Data Transmission.

#3. Next i tried to debug the flashed code i got Debugger connection loss error as well the  Firmware Jump location error when i suspend the Debugging Progress.From this time onward no longer working with any of the sample code.

#4. If i try to reset the Target this will jump to the Firmware address 0xFFFF address instead to the vector address.

RF_Reset_In_Debug_Mode.jpg

#5 . I hope i have accidentally erased the  builtin Firmware data,but i don't have any idea how to restore my IC to normal working conditions.Please any can help me for the steps to resolve this issues.

#6. I have using CW10.6 with TPMS supported component installed. Please node this are the thing im using for my development (FXTH870911 and P&E Micro Cyclone Pro) Debugger.

Please this will be very great-full if any one help me out.

RF_Suspended_Mode.jpg

Thanks

Sakthivel K

0 Kudos
2,374 Views
pgo
Senior Contributor V

Hi Jiangbo,

I'm sorry I can't help with the image you need.  I obtained the FXTH870511 image by reading it from the chip before I tried programming :smileyhappy:.

bye

0 Kudos
2,374 Views
jiangboli
Contributor I

Hi pgo,

Thank you anyway!

I think I can only replace the bad chip with a new one.

I still want to know why don't freescale provide the image or method? Many users else have made the same mistake.

Best regards!

0 Kudos
2,378 Views
sunrme
Contributor III

Hi pgo,

Actually I don't know how to thank you. Everything works greate, devices alive, debug works correctly, so really big THANK YOU!

0 Kudos
2,378 Views
pgo
Senior Contributor V

You're  welcome sunrme,

Thanks for letting me know it works.

bye

0 Kudos
2,378 Views
razvanmorariu
Contributor I

Hi,

Do you by any chance have a working code for this chip? I am trying to use the example code provided by freescale but when I run it in debug mode it suddenly jumps into weird parts of memory and I get an error like this.Capture2.PNG.png

thank you,

Razvan

0 Kudos
2,378 Views
georgepeterson
Contributor II

Razvan,

If the starter code from Freescale does not work for you, my guess is that you have a problem in your setup. I've been using the starter code for a couple of months now, on both FXTH87xxx11 and FXTH87xxx02 devices and it works great.

Recheck your hardware. Make sure you have external pullups on both the BKGD and RST pins.

Do you have the FXTH87 update package installed?

0 Kudos
2,374 Views
王亚萍
Contributor I

I also want to work on the FXTH87, so I want to get a EVB for reference. You build the hardware circuit yourself or get it from Freescale? Look forward to your reply!

Thanks.

0 Kudos
2,374 Views
jiangboli
Contributor I

Hi Yaping Wang,

I design the PCB of FXTH87 by myself,and it works normally.But I think the RF antenna is not perfect.

By the way,Are you Chinese?

bye

0 Kudos
2,374 Views
王亚萍
Contributor I

Hi,jiangbo,

  May I contact with you and counseling some problems.

0 Kudos
2,374 Views
jiangboli
Contributor I

Hi Yaping,

Please leave your qq number,I will contact you.

I have sent you an email(20134228017@stu.suda.edu.cn),but you didn't reply me all the time.

0 Kudos
2,374 Views
王亚萍
Contributor I

my qq number is 929077591

0 Kudos
2,374 Views
王亚萍
Contributor I

Yes,I am Chinese student from Suzhou. I am designing the PCB these days. But ,with less experience ,very hard to do it,too much things unkown. May I contact with you in the following days?

在2015-04-21 21:50:41,王亚萍20134228017@stu.suda.edu.cn写道:

|

|

|

|

Re: Fail to program FXTH87xx11 using USBDM

reply from Jiangbo Li in OSBDM and TBDML - View the full discussion

Hi Yaping Wang,

I design the PCB of FXTH87 by myself,and it works normally.But I think the RF antenna is not perfect.

By the way,Are you Chinese?

bye

Did your question get answered? If so, say thanks by clicking Correct Answer in the community thread!

Reply to this message by replying to this email, or go to the message on Freescale Community

Start a new discussion in OSBDM and TBDML by email or at Freescale Community

Following Re: Fail to program FXTH87xx11 using USBDM in these streams: Inbox

|

|

0 Kudos