It is currently Wed Jun 19, 2013 4:05 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: A9L discrepancy
PostPosted: Sat Jun 12, 2010 11:50 pm 
Offline
BIN Hacker
User avatar

Joined: Tue Apr 20, 2004 1:50 pm
Posts: 802
Location: Bethesda, Maryland
here is an excerpt from an A9L disassembly I have.
Code:
...
  A1F00018    8762 L84F5 ld    REG_18,#$00F0
  B30120201A  8763       ldb   REG_1A,$2020[Zero]
  A2151C      8764 L84FE ld    REG_1C,[REG_14]+
  C2191C      8765       st    REG_1C,[REG_18]+
  E0E01A      8766       djnz  REG_1A,L84FE
...

FWIW, REG_14 is set to #$2022 just before this code, and address $2020 is 8. essentially, it is copying 8 values from $2022 to $00F0.

so it makes perfect sense that at line 8766, it would decrease REG_1A and jump back to line 8764 if not ZERO (what the DJNZ means). so it would do that 8 times before the DJNZ would not branch, because REG_1A would then be ZERO.

now here is my problem ... in the A9L bin I have though, the location where the above is E0E01A, my binary has E01AF7. the discrepancy is at address $8504 (decimal 34052)

so it becomes
Code:
...
  A1F00018    8762 L84F5 ld    REG_18,#$00F0
  B30120201A  8763       ldb   REG_1A,$2020[Zero]
  A2151C      8764 L84FE ld    REG_1C,[REG_14]+
  C2191C      8765       st    REG_1C,[REG_18]+
  E01AF7      8766       djnz  REG_F7,L8522
...

which makes no sense. this is the first discrepancy i have come across between the disassembly and my actual binary. and my binary appears to be the problem.

any thoughts?

_________________
95 GT Vert, TwEECer R/T v1.30A9
1970 block, 410ci, 10.27:1 CR, 42#, LMAF, CBAZA/T4M0, AOD, 2500 Stall, Custom Cam

1967 Fairlane Vert, 390FE, C6, 100% stock


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun Jun 13, 2010 1:05 am 
Offline
BIN Hacker

Joined: Tue Jul 12, 2005 5:10 am
Posts: 1481
The first code extract you have is incorrect, the dnjz line should be E01AF7 as per your binary.

You are getting the register and jump offset the wrong way around in the second code extract (also the jump offset is signed).


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun Jun 13, 2010 8:14 am 
Offline
BIN Hacker
User avatar

Joined: Tue Apr 20, 2004 1:50 pm
Posts: 802
Location: Bethesda, Maryland
thanks. i guess the byte dump of the disassembly cannot always be trusted.

_________________
95 GT Vert, TwEECer R/T v1.30A9
1970 block, 410ci, 10.27:1 CR, 42#, LMAF, CBAZA/T4M0, AOD, 2500 Stall, Custom Cam

1967 Fairlane Vert, 390FE, C6, 100% stock


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun Jun 13, 2010 9:01 pm 
Offline
Amateur Tooner
User avatar

Joined: Fri Jan 16, 2009 11:45 am
Posts: 5951
Location: New Orleans, LA
which disassembler are you using?


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun Jun 13, 2010 10:05 pm 
Offline
BIN Hacker
User avatar

Joined: Tue Apr 20, 2004 1:50 pm
Posts: 802
Location: Bethesda, Maryland
i'm not sure as the listing is old. but i have the disassembler from bill lawrence, so i bet it was from that

i would love to get a cleaner, more accurate disassembly

_________________
95 GT Vert, TwEECer R/T v1.30A9
1970 block, 410ci, 10.27:1 CR, 42#, LMAF, CBAZA/T4M0, AOD, 2500 Stall, Custom Cam

1967 Fairlane Vert, 390FE, C6, 100% stock


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun Jun 13, 2010 10:10 pm 
Offline
Amateur Tooner
User avatar

Joined: Fri Jan 16, 2009 11:45 am
Posts: 5951
Location: New Orleans, LA
too bad those disassembler's are ancient. else if you want to step your game into the millennium you can get a Motorola disassembler and do what Adam's doing with the 2010 mustang ecu :shock:

those ecu's are like a mini apple :lol:

with 4 timing tables per camshaft (16 total) you really got some control there, you can tune one of those bastards till your blue in the face :lol:

_________________
http://www.efidynotuning.com/ford/


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Mon Jun 14, 2010 6:41 am 
Offline
BIN Hacker
User avatar

Joined: Tue Apr 20, 2004 1:50 pm
Posts: 802
Location: Bethesda, Maryland
who is adam and what is he doing?

_________________
95 GT Vert, TwEECer R/T v1.30A9
1970 block, 410ci, 10.27:1 CR, 42#, LMAF, CBAZA/T4M0, AOD, 2500 Stall, Custom Cam

1967 Fairlane Vert, 390FE, C6, 100% stock


Last edited by TripleBlackVert on Mon Jun 14, 2010 6:05 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Mon Jun 14, 2010 6:54 am 
Offline
Administrator
User avatar

Joined: Fri Jun 24, 2005 4:54 am
Posts: 9397
Location: Acworth, Ga (Metro Atlanta)
It seems like dyno time just went up with all the controls that are now available. As you said, 4 tables per cam. That's a lot to tune for. Add to that, you even have separate cylinder controls. So you can optimize the spark advance on a per-cylinder basis. Although I think that's only a single offset adder, but I can't remember. In anycase, the number of things you can change and test for just seems like it is growing out of control.

Now the big question is how Ford is setting the tune up? Obviously while cruising, there's a fuel economy and emissions focus. But I have to believe that at some point, emissions starts to intrude on fuel economy. So is there the chance that an extra MPG can be squeezed out if you accept a slightly higher NOx or HC emission? If there are fuel economy improvements to be made, even if emissions has to take a back seat I think I'd take it in a heartbeat. And on performance, was Ford focused more on getting the engine through the warranty period or is performance pretty much maxed out with very little that can be improved upon without swapping out hardware?

_________________
...Always Somethin'

89 Ranger Supercab, 331 w/GT40p heads, ported Explorer lower, Crane Powermax 2020 cam, 1.6RRs, FMS Explorer (GT40p) headers, Slot Style MAF, aftermarket T5 'Z-Spec', 8.8" rear w/3.27s, Powertrax Locker, Innovate LC-1, GUFB, Moates QuarterHorse tuned using BE&EA

Member V8-Ranger.com


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sat May 14, 2011 11:18 pm 
Offline
Regular

Joined: Sat May 14, 2011 10:41 pm
Posts: 117
Location: New Zealand
My copy of A9L code looks like this....with extra comments


Code:


84f5: a1,f0,00,18       ldw   R18,f0          R18 = 0xf0;
84f9: b3,01,20,20,1a    ldb   R1a,[2020]      R1a = [2020];
84fe: a2,15,1c          ldw   R1c,[R14++]     R1c = [R14++];
8501: c2,19,1c          stw   R1c,[R18++]     [R18++] = R1c;
8504: e0,1a,f7          djnz  R1a,84fe        R1a--;
                                                         if (R1a != 0) goto 84fe;      # loop back


This actually sets up the registers f0 to f8 as 'base' pointers. these are used all over the
place as 'base+dispacement' addresses

(yeah OK you probably know this already.... just in case !!)

[ oops - why do spaces get messed up in display - help anyone ?) - FIXED !!
A.

_________________
TVR Tasmin 280, TVR Tuscan 2.8 Efi (EEC IV), various kit cars, IT code geek....
Crusty old Classic car freak.


Last edited by tvrfan on Sun May 15, 2011 3:46 pm, edited 2 times in total.

Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun May 15, 2011 6:45 am 
Offline
Administrator
User avatar

Joined: Fri Jun 24, 2005 4:54 am
Posts: 9397
Location: Acworth, Ga (Metro Atlanta)
Use the code tags to get text to display in fixed-width font.

_________________
...Always Somethin'

89 Ranger Supercab, 331 w/GT40p heads, ported Explorer lower, Crane Powermax 2020 cam, 1.6RRs, FMS Explorer (GT40p) headers, Slot Style MAF, aftermarket T5 'Z-Spec', 8.8" rear w/3.27s, Powertrax Locker, Innovate LC-1, GUFB, Moates QuarterHorse tuned using BE&EA

Member V8-Ranger.com


Top
 Profile  
 
 Post subject: Re: A9L discrepancy
PostPosted: Sun May 15, 2011 3:44 pm 
Offline
Regular

Joined: Sat May 14, 2011 10:41 pm
Posts: 117
Location: New Zealand
Duh.....stupid of me not to see that.... Thanks !!!

Amended above post......

_________________
TVR Tasmin 280, TVR Tuscan 2.8 Efi (EEC IV), various kit cars, IT code geek....
Crusty old Classic car freak.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group