Notices
ECU Flash

Knock control - load vs RPM table found

Thread Tools
 
Search this Thread
 
Old Nov 24, 2008 | 04:52 AM
  #46  
jcsbanks's Avatar
Thread Starter
Evolved Member
 
Joined: May 2006
Posts: 2,399
Likes: 6
From: UK
I found an upcounter to F0 in the knock noise filter, please tell me where you found the masked downcounter.
Reply
Old Nov 24, 2008 | 06:17 AM
  #47  
acamus's Avatar
Evolved Member
 
Joined: Mar 2008
Posts: 730
Likes: 3
From: Lattitude 48.38°, Longitude 17.58°, Altitude 146m = Slovakia, for common dude
Originally Posted by jcsbanks

The odd knock filter that Bez posted actually makes sense because there are two parts of it that are used - one has three times the gradient of the other, and depending on the background level of the noise the ECU switches an output to presumably a knock amplifier.
Ok what I have understood from
http://www.aktivematrix.com/forum/vi...=knock+filters

The knock sensor DSP is done within the ECU. The filters are linear. There is only one delay element for processing, i.e. previous value. There are two signal levels giving three possible filter constants and offsets.

jcsbanks, thanx for the hint for BEZ disassembly.

The filters seem to be of Kalman type.

http://www.elo.utfsm.cl/~ipd481/Pape...kalman1960.pdf
Reply
Old Nov 24, 2008 | 06:25 AM
  #48  
acamus's Avatar
Evolved Member
 
Joined: Mar 2008
Posts: 730
Likes: 3
From: Lattitude 48.38°, Longitude 17.58°, Altitude 146m = Slovakia, for common dude
Originally Posted by jcsbanks
I found an upcounter to F0 in the knock noise filter, please tell me where you found the masked downcounter.
sub C850:
sts.l pr, @-r15
mov.l r14, @-r15
mov r15, r14
mov.l r1, @-r15
mov.l @(h'300,pc), r10 ; SYSTEM_STATUS_STORE
jsr @r10 ; SYSTEM_STATUS_STORE
nop
mov.l @(h'120,pc), r1 ; Down_Count_Start_Register_DSTR
mov.w @r1, r1
mov.l @(h'128,pc), r10 ; SYSTEM_STATUS_RESTORE
jsr @r10 ; SYSTEM_STATUS_RESTORE
nop
extu.w r1, r1
shlr8 r1
shlr2 r1
mov r1, r0
and #h'F, r0 <-------------------------- here
mov.l @r15+, r1
mov.l @r15+, r14
lds.l @r15+, pr
rts
nop

search for RAM:FFFFF666 = Down_Count_Start_Register_DSTR usage to find the same routine, shall be same for all SH2.
Maybe one could fiddle also with
shlr8 r1
shlr2 r1
to divide it more agressively.

Last edited by acamus; Nov 4, 2009 at 10:53 PM.
Reply
Old Nov 24, 2008 | 09:59 AM
  #49  
jcsbanks's Avatar
Thread Starter
Evolved Member
 
Joined: May 2006
Posts: 2,399
Likes: 6
From: UK
I cannot find any connection between that masked downcounter and knock control. There is a routine that has an input of that masked downcounter that changes bit 1 in the same variable that is used as a flag for knock control, but bit 1 is not apparently used in knock control. Happy to be corrected if you find otherwise!

Re the filter that Bez posted about - it does not actually change the signal at all to introduce volatility like he thought. Whilst Bez's description of the calculations is correct, all it seems to do is to compensate for the switching gain on the knock signal before it enters the CPU. When the amp's gain is switched, all the variables are updated to match the new gain. The code re-references everything and looks after the gain switching and all its implications for us, so I think we can ignore all that stuff since it works well.

So far, out of what I've found the load vs RPM table I posted this thread about should be useful. On some ECUs below this level the knock control is turned off completely, in others it is about half.

The remainder of the puzzle is to work out the calculation of KNOCKBASE, the background noise level, so far it looks like it takes the old value and mulitplies it by 7, adds the latest knock free noise level, then divides by 8. So it would take 8 ignition events to fully update the KNOCKBASE. I think I'll be able to suggest two RPM vs noise maps that can be adjusted to influence this further. I have found these maps, and just need to follow their effects all the way through the code.
Reply
Old Nov 24, 2008 | 02:14 PM
  #50  
justboosted02's Avatar
Evolved Member
15 Year Member
Liked
Loved
Community Favorite
iTrader: (31)
 
Joined: Jun 2006
Posts: 1,926
Likes: 14
From: northeast
well ive been using this table for the past couple days and it has really let me drive the car again, i have the load threshold at 3500rpms up around 130 load. this greatly improves around town drivability. however when doing a full wot pull from 2k rpms i will pass 3500 rpms at about 250-280 load, this causes the ecu to pick up some knock although now the counts seem to be less than they were before.

ill post up some logs with my findings later
Reply
Old Nov 24, 2008 | 03:18 PM
  #51  
jcsbanks's Avatar
Thread Starter
Evolved Member
 
Joined: May 2006
Posts: 2,399
Likes: 6
From: UK
Here are the four knock control 2d maps, hopefully all we need...

Nice one, glad it works for you. I have no false knock to test, I just like logic puzzles

I have finished disassembling the knock routines They are sophisticated with adaptation and filtering techniques to develop a background noise level. In addition to the first table I posted as the subject of this thread, there are three other tables which we will be able to adjust. They are all RPM based. One is a multiplier and two are adders that udpate the background noise level as the engine speed changes. The two adding tables are doing the same thing just at different amplifier gain levels for the knock sensor. You will note that rounded off, the triple gain table entries are simply 3x the single gain table entries. Since the ECU can switch between amplifier gain levels mid pull, they should be kept scaled together like this. These three new tables you would expect to have to update on a noisy engine that suddenly increases in noise at say 3500 RPM... if you didn't the background noise estimation doesn't keep up, the ECU decides it is knock and then the background noise estimation is further stopped in its development. So once you reach a noise tipping point it all goes wrong! We should be able to log a knock free noise curve like say AEM to guide setting of these tables with a few calculations.

I will put together a description of the full knock control system soon (there are multiple levels of filtering and lots of switches and conditions, but I have disassembled them all now). Perhaps later we can put together a concise version once people have tested practically.
Attached Thumbnails Knock control - load vs RPM table found-knockcontrol.png  
Reply
Old Nov 24, 2008 | 03:23 PM
  #52  
MR Turco's Avatar
EvoM Staff Alumni
iTrader: (16)
 
Joined: May 2007
Posts: 3,233
Likes: 3
From: Massachusetts
This is some fabulous stuff and i think everyone has been aching to see this type of focus on this subject for a LONG time. With what you previously said about the 3d knock tables being wrong should we suggest that mrfred have them removed from ECUflash?
Reply
Old Nov 24, 2008 | 03:57 PM
  #53  
dan l's Avatar
Account Disabled
iTrader: (3)
 
Joined: Apr 2006
Posts: 1,029
Likes: 0
From: USA
AMAZING jcsbanks!!!!!!!!!!!!

I can say, that my practical experience mimics what you have found in the code. Nice job!
Reply
Old Nov 25, 2008 | 06:29 AM
  #54  
l2r99gst's Avatar
Evolved Member
iTrader: (2)
 
Joined: Mar 2004
Posts: 3,499
Likes: 4
From: CA
Awesome job, as always, John. When I have some time today, I will try to find those tables for my ROM and post them up.
Reply
Old Nov 25, 2008 | 09:02 AM
  #55  
l2r99gst's Avatar
Evolved Member
iTrader: (2)
 
Joined: Mar 2004
Posts: 3,499
Likes: 4
From: CA
Hmmmm....well, I can't find the maps for 96940011. I even searched the entire rom for all 2D maps referencing what I think is the correct RPM variable (02 00 FF FF 88 80) and I found tons of maps, but none that looked even remotely close to what was posted.

I found them right away for 88590015. They appear to be at:

669e
66b2
66c6


Maybe someone a little better at disassembly can take a look at 96940011. I'll look through the maps again...perhaps they are there, but have very different values.



Eric

Last edited by l2r99gst; Nov 25, 2008 at 09:05 AM.
Reply
Old Nov 25, 2008 | 09:52 AM
  #56  
lan_evo_mr9's Avatar
Evolved Member
iTrader: (10)
 
Joined: Feb 2006
Posts: 1,097
Likes: 2
From: MD
I can't wait for the 88590015 patch to be created! This is truly amazing what you guys are doing. I'm sure the whole community is very thankful for the time and effort you put into these solutions. All I can say is thank you very much for your hard work. I truly appreciate everything you guys have contributed.
Reply
Old Nov 25, 2008 | 10:22 AM
  #57  
jid2's Avatar
Evolved Member
iTrader: (62)
 
Joined: Feb 2004
Posts: 3,336
Likes: 6
From: Redmond - Lake Tapps ,WA
This is sweet.

This area of the forum is where all the good stuff is these days. The rest is what wheels are cool this week, and how much power does my dream build make.
Reply
Old Nov 25, 2008 | 10:31 AM
  #58  
travman's Avatar
Evolved Member
iTrader: (26)
 
Joined: Oct 2005
Posts: 1,712
Likes: 0
From: Pittsburgh
Originally Posted by jid2
This is sweet.

This area of the forum is where all the good stuff is these days. The rest is what wheels are cool this week, and how much power does my dream build make.

This forum has had the good stuff over the rest of evom since the day ecuflash was created......

Next best is "alternative fuels"
Reply
Old Nov 25, 2008 | 11:36 AM
  #59  
lan_evo_mr9's Avatar
Evolved Member
iTrader: (10)
 
Joined: Feb 2006
Posts: 1,097
Likes: 2
From: MD
Next best is "alternative fuels"

Couldn't agree with you more.
Reply
Old Nov 25, 2008 | 11:40 AM
  #60  
honki24's Avatar
Evolved Member
20 Year Member
iTrader: (23)
 
Joined: Apr 2003
Posts: 1,580
Likes: 0
From: Houston, TX
Very cool. I also want to give my thanks and appreciation for the hard work. Can't wait to see a concise explanation.
Reply



All times are GMT -7. The time now is 03:50 AM.