PCMHammer P04

Post Reply
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

Bum deal ... All that work for not!

Unfortunately folks I have sold you a bill of goods, for the P04 is not as close as hoped ... Sorry!

That's what I get for opening my mouth and proving up the Assembly Kernel, I should have kept it to myself and kept working on it by myself quietly, I would not of gotten hopes up, and I wouldn't have to apologize, lesson learned.
But it would also NOT be this far along without antus's help, most specifically the CRC code, that is something I doubt I could have accomplished on my own anytime soon.
He also helped me solve an AMD erase bug that was very damaging to AMD chips, it destroyed them ...
So there are good sides and bad sides to it ... I just hate getting hopes up then having to deflate them.

It'll happen ... PCMHammer just needs some heavy changes!

Unfortunately there just is not enough contiguous memory (that I can find) to get a full Kernel on board, I can get ~1450 bytes up before it takes a shit, the full Kernel is ~2k (Last time I looked it was 1971 bytes).
I've tried many many addresses ...

So, I '#if defined' it down to 3 Kernels, 1. Read Kernel, 2. AMD Write Kernel, 3. Intel Write Kernel, but not any two, and Intel is still shaky at best, it bit me, I now need to BDM my Intel P04.
The AMD Kernel came out to 1443 bytes, the Intel Kernel was 1487 bytes ... They can be divided a bit more, but it's getting pretty damn ugly to do so!
I have also trimmed it down by ~20 bytes since.

The full Kernel works awesome on all others ... P01, P10, P12, P12b, P59 (Both AMD and Intel) plus the E54.

But the split up technique was ugly so I ripped it out to rethink it ... The challenge is to not triplicate the code, especially code that is already duplicated between the Loader and Kernel.

I'm drained, I need to take a break!

I've failed!
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
kur4o
Posts: 1044
Joined: Sun Apr 10, 2016 9:20 pm

Re: PCMHammer P04

Post by kur4o »

You can use some other technique to free up some contiguous space.

Get loader loaded, than relocate loader by uploading new loader at end of usable ram. Than you can use almost all space between ff8000-ffc000.

I don`t thinkthere is locked up memory range, at least on the p04, If you can read the address, than you can use it..
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

kur4o,

Have you actually done this in practice, or just theory ??

Because I assure you I have tried nearly every address starting at FF8000 and up, either the PCM reject's the mode 34, or the Mode 36, or either the Loader or Kernel crashes depending on what address pairs are used.

Reduce the size, and it works ... At specific addresses!

We are already loading the Loader where the Kernel can use the Loader's space, thus not wasting space!

-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
User avatar
antus
Site Admin
Posts: 9008
Joined: Sat Feb 28, 2009 8:34 pm
cars: TX Gemini 2L Twincam
TX Gemini SR20 18psi
Datsun 1200 Ute
Subaru Blitzen '06 EZ30 4th gen, 3.0R Spec B
Contact:

Re: PCMHammer P04

Post by antus »

I think you need to write a new stack address to sp to get it out of the middle of ram. I think that'll work on p08 too and we might as well bake the address for stack in to all of them incase some os we havnt hit yet does something screwey with locating it. We can get this branch in now and fix p04/08 next. Ive tested p01 intel and p59 amd, as expected worked perfect, but ive been out of town for a bit and didnt have time for p12 yet. does anyone have a p10/p12b/e54 who can test gampys merge request (which is against the public repo here https://github.com/LegacyNsfw/PcmHacks/pull/326 )? then we can put it in develop and look at p04/p08. I also want to read through this one because its big rather than just skim it and merge.
Have you read the FAQ? For lots of information and links to significant threads see here: http://pcmhacking.net/forums/viewtopic.php?f=7&t=1396
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

Remember if you are a Github member, you can get a pre built version from the Github Action Artifacts.

Or see here: PCMHammer Github Action Artifacts

-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

Antus ... You are my HERO!

It worked ... Relocating the Stack solved the problem!

I just used a FULL Kernel to Write an AMD P04!
Testing Intel now ...

Do NOT merge that PR yet, I suspect I'll be updating it before the night is over, I'm go to work straight through and test ALL PCM's again.

Edit; Intel Loads the full Kernel and does everything but Erase/Write ... Odd, it used to work, and same code, It's like IntelUnlock is not working now.

-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
User avatar
antus
Site Admin
Posts: 9008
Joined: Sat Feb 28, 2009 8:34 pm
cars: TX Gemini 2L Twincam
TX Gemini SR20 18psi
Datsun 1200 Ute
Subaru Blitzen '06 EZ30 4th gen, 3.0R Spec B
Contact:

Re: PCMHammer P04

Post by antus »

Glad it worked. I reckon it'll work for P08 as well. I think I must have half bricked my P12 and forgotten about it because I cant read the vin properly on anything and commercial software is having trouble with it too. And this is before I can test that branch on my hardware. Maybe I should leave P12 and get on to P08 before you do everything lol.
Have you read the FAQ? For lots of information and links to significant threads see here: http://pcmhacking.net/forums/viewtopic.php?f=7&t=1396
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

You asked me to leave the P08 to you ... I said I would, and I will!

This Intel P04 failure has me buggered, it worked previously, with the same code ...

As for P12 properties ...
P12-Properties.png
P12-Properties.png (14.61 KiB) Viewed 1827 times
-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
User avatar
antus
Site Admin
Posts: 9008
Joined: Sat Feb 28, 2009 8:34 pm
cars: TX Gemini 2L Twincam
TX Gemini SR20 18psi
Datsun 1200 Ute
Subaru Blitzen '06 EZ30 4th gen, 3.0R Spec B
Contact:

Re: PCMHammer P04

Post by antus »

BDM for P12... here we go again... https://www.usbjtag.com/phpbb3/viewtopic.php?t=9882
Except they're potted arnt they. I unbolted and it didnt open, so I drilled a small hole to look and yeah that does not look easy. Maybe this P12 goes in the bin.
Have you read the FAQ? For lots of information and links to significant threads see here: http://pcmhacking.net/forums/viewtopic.php?f=7&t=1396
User avatar
Gampy
Posts: 2332
Joined: Sat Dec 15, 2018 7:38 am

Re: PCMHammer P04

Post by Gampy »

I have not actually ripped one apart, but I don't think they are potted, I think the cover is just glued.

I think Darkman5000 posted a pic in the P12 thread.

Edit: I think (my brain is getting pretty foggy) the P12 and the E40 share BDM ... I have E40 BDM Pinout.

-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
Post Reply