P59 PCM with AMD Flash

This talks about BDM used on card Engine computer
Post Reply
DavidBraley
Junior Member
Posts: 4
Joined: Thu Jul 05, 2018 5:53 pm

P59 PCM with AMD Flash

Post by DavidBraley »

I've been following bubba2533's thread on getting the P59 PCM that uses the Intel AB28F800 flash chip working with the USB BDM NT device:

https://www.usbjtag.com/phpbb3/viewtopic.php?f=22&t=9560

This "New" TP59.xml file that you created for bubba2533 does not work with my 1 Meg P59 PCM that uses the AM29F800BB flash chip and I was hoping you could help me too.

After connecting everything and before I press the "ID" button on the tool bar, I look in the lower right corner of the software it says: "USB Connected" and "BDM ON"

Here is the output from the USBJTAGNT software when I press the "ID" button on the toolbar:

Copyright (C) 2010-2015
USB BDM NT 0.84
Target: P59
-speed 0
-speed 1
-reset 1
unknown flash type!
Report these values http://www.usbjtag.com/vbforum 0001,2258

I then read the contents of the AMD AM29F800BB flash using the TP59.xml file, and the bin file it created is attached below.

I compared the bin file created by the USB BDM NT device with a known good bin file from the same P59 PCM, and the two bins are identical. So I know that the TP59.xml file is correctly reading the memory contents of the AMD AM29F800BB flash memory using the USB BDM NT device.

I hope what I said makes sense. I'm very new to using the BDM device to read and program these PCM's.

Let me know if there is anything else you might need.

Thanks in advance for your help with this.

David
You do not have the required permissions to view the files attached to this post.
NSFW
Junior Member
Posts: 5
Joined: Mon Feb 18, 2019 6:15 pm

Post by NSFW »

Did you make any progress with this?

If you need help getting the flash chip into command mode, this C code worked for me:

#define COMMAND_REG_AAA (*((volatile uint16_t*)0xAAA))
#define COMMAND_REG_554 (*((volatile uint16_t*)0x554))


// Switch to flash into ID-query mode.
COMMAND_REG_AAA = 0xAAAA;
COMMAND_REG_554 = 0x5555;
COMMAND_REG_AAA = 0x9090;

// Read the identifier from address zero.
//flashIdentifier = FLASH_IDENTIFIER;
uint16_t manufacturer = FLASH_MANUFACTURER;
uint16_t device = FLASH_DEVICE;
uint32_t id = ((uint32_t)manufacturer << 16) | device;




The data sheet was not clear at all. That code was mostly based on existing code that I found in a GM ECU, and code that someone else showed me from a Lotus ECU.


I think I accidentally erased my ECU's boot block, so I'm working on getting the BDM NT set up to fix it. I'm hoping you guys can get writing to work by the time I get mine wired up. :)
usbbdm
Junior Member
Posts: 8962
Joined: Mon Jul 18, 2005 9:33 pm

Post by usbbdm »

I can help you to program the flash. The AMD flash support is not an issue. Simply need to add the flash into the definition.
DavidBraley
Junior Member
Posts: 4
Joined: Thu Jul 05, 2018 5:53 pm

Post by DavidBraley »

usbbdm wrote:I can help you to program the flash. The AMD flash support is not an issue. Simply need to add the flash into the definition.
That would be fantastic! Any help would be very much appreciated. Not just for me, there are many that could benefit from this working. Let me know if I provided enough information in my first post.

I attached a file in my first post from reading the contents of the AMD flash using the USB BDM NT device that I bought from you. Please let me know if there is anything else I can do.

Oh, I also wanted to thank you for the help you gave me regarding the wire length on the header for the USB BDM NT device. I have managed to keep the total length to less than 6 inches (~152mm). It works much better that way. :)

Take care,

David
DavidBraley
Junior Member
Posts: 4
Joined: Thu Jul 05, 2018 5:53 pm

Post by DavidBraley »

NSFW wrote:Did you make any progress with this?

If you need help getting the flash chip into command mode, this C code worked for me:

#define COMMAND_REG_AAA (*((volatile uint16_t*)0xAAA))
#define COMMAND_REG_554 (*((volatile uint16_t*)0x554))


// Switch to flash into ID-query mode.
COMMAND_REG_AAA = 0xAAAA;
COMMAND_REG_554 = 0x5555;
COMMAND_REG_AAA = 0x9090;

// Read the identifier from address zero.
//flashIdentifier = FLASH_IDENTIFIER;
uint16_t manufacturer = FLASH_MANUFACTURER;
uint16_t device = FLASH_DEVICE;
uint32_t id = ((uint32_t)manufacturer << 16) | device;




The data sheet was not clear at all. That code was mostly based on existing code that I found in a GM ECU, and code that someone else showed me from a Lotus ECU.


I think I accidentally erased my ECU's boot block, so I'm working on getting the BDM NT set up to fix it. I'm hoping you guys can get writing to work by the time I get mine wired up. :)
Thank you so much NSFW for the reply! I think we are going to get this going. :) I also have a bunch of bin files if you need anything to get that ECU going again.

I will be very interested in seeing the programming fixture you are about to build that uses the USB BDM NT device. Let me know too if you need anything. I have a machine shop here at home and I've been cranking handles now for over 40 years...
NSFW
Junior Member
Posts: 5
Joined: Mon Feb 18, 2019 6:15 pm

Re: P59 PCM with AMD Flash

Post by NSFW »

I was able to reflash an AMD-based P59 ECU just now. The ECU4111M.xml file works with no modifications. The thing I was missing was a flash chip definition for the chip in my ECU. After configuring the new chip, reflashing just works.

All credit belongs to the guy who made this post:
https://ls1tech.com/forums/pcm-diagnost ... st20172737
NSFW
Junior Member
Posts: 5
Joined: Mon Feb 18, 2019 6:15 pm

Re: P59 PCM with AMD Flash

Post by NSFW »

..and there are a couple pictures of my reflash fixture here:
https://www.thingiverse.com/thing:3565197

I also posted OpenScad and STL files there, so anyone with a 3D printer can make one.

It works with both P01 (aka 411, 512kb) PCMs and P59 PCMs (various part numbers, 1mb).

(David gets credit for the reflash fixture, I made it based on dimensions in a CAD file that he sent me a while back.)
usbbdm
Junior Member
Posts: 8962
Joined: Mon Jul 18, 2005 9:33 pm

Re: P59 PCM with AMD Flash

Post by usbbdm »

GOOD WORK. The 3D design is great!!
I have a 3D printer, Will try to print one
DavidBraley
Junior Member
Posts: 4
Joined: Thu Jul 05, 2018 5:53 pm

Re: P59 PCM with AMD Flash

Post by DavidBraley »

NSFW wrote: Tue Nov 19, 2019 1:04 am I was able to reflash an AMD-based P59 ECU just now. The ECU4111M.xml file works with no modifications. The thing I was missing was a flash chip definition for the chip in my ECU. After configuring the new chip, reflashing just works.

All credit belongs to the guy who made this post:
https://ls1tech.com/forums/pcm-diagnost ... st20172737
Thank you NSFW! I too got this to work. 8)
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests