2004 R1150RT Wideband O2 Sensor Project (and AF-XIED for BMW)

Discussion in 'Vendors' started by roger 04 rt, Dec 13, 2011.

  1. Poolside

    Poolside Syndicated

    Joined:
    Apr 1, 2003
    Oddometer:
    11,887
    Location:
    Silicon Beach, CA
    <BR>Great job, Roger! :clap

    I'm going to read your posts over more carefully when I get a chance.


    You might try powering the heater in the LC-1 sensor from the ECU, you know, just like the narrow band heater. The ECU O2 sensor heater output is always on when the motor is running, and I don't recall but the heater may also be on whenever the ignition key is on.

    The LC-1 may have a PWM heater control. If so, use the ECU O2 heater output as the high current input to the LC-1 heater supply. Note: 'High current' is a relative term here. An O2 sensor heater only uses about 16-18W or 1.25-1.50A

    <BR>
    #21
  2. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Had a good look at running the LC-1 heater ground, which is separate, to the Motronic heater ground but decided against it. With a schematic of both the LC-1 and Motronic, I might try; but without those, I don't want to take the risks of: damage, noise and ground loops.

    The LC-1 may have a PWM (pulse width modulated) heater control.

    I'm thinking about a 10 ohm resistor but one kit I saw suggested 20 ohms would work--still deciding.

    Also working on some other circuit/wiring/filtering details on the Motronic's O2 sensor input.
    #22
  3. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Over the last two days I've put a few hours on the bike. I have to say, that the slight downward shift of Closed Loop Lambda (AFR) from 1.000 to 0.965, has made a remarkable change in smoothness and low-end power. There has not been any sense of hesitation, in fact quite the opposite. I'm now running RPMs between 2500 and 3500 around town, even in 5th gear.

    As far as the Motronic ECU is concerned the data looks like this:

    Total data points: 4,000
    Percent Closed Loop: 45% (same as before for the local conditions)
    Average Closed Loop Lambda Voltage: 410 mV (right where expected, indicating good loop closing)

    The new shift plots are looking the same as the earlier stock sensor plots. The big difference being the improved performance and the AFR meter reading 14.2:1 +/-. The above also indicates that the Motronic has been "convinced" to accept the programmable O2 setting and doesn't know that I've richened Closed Loop Lambda.

    The next tests will be on the highway.

    There are several variables still to tuned:

    High Lambda Voltage: (800 mV to 1V)
    Low Lambda Voltage: (0V to 200mV)
    Low Lambda Value: (how far below the 0.965 mid-point)
    High Lambda Value: (how much above the 0.965 mid-point)
    Target Lambda: (is there a better target that 0.965, implied AFR 14.2)

    Filter Sensor inputs?
    Monitor Sensor waveform.

    In spite of what needs to be evaluated still, it looks to me like a slightly lower Lambda target (richer AFR) makes a MUCH smoother bike.

    Will post up some charts later.
    #23
  4. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Here are some plots of several thousand data points acquired while running at 14.2 Air Fuel Ratio (AFR). The key observation is that the Motronic is operating normally, unaware that it has been spoofed to run at Lambda=0.965 which is an equivalent gasoline AFR of 14.2.

    This an acceleration through a couple of gears with a warm engine. Notice that just like the earlier chart (a few posts back), the Motronic goes into closed loop while the RPM is accelerating. The Motronic doesn't know the Closed Loop AFR is 14.2, but for the rider (me) the engine feels much stronger and smoother because the AFR is richer.

    [​IMG]


    The next two charts show a before (14.7 AFR with Stock Narrow Band O2 Sensor) and after (14.2 AFR with Wideband O2 Sensor and LC-1 connected to the Motronic in place of the Stock Sensor). Although the shapes of the curves are different due to how I have set up the hi/low transitions (something I will continue to experiment with) the key takeaway is that the Mean (average) and Median voltages are nearly identical (about 20 mV different). This suggests that the Motronic is controlling Closed Loop operation and is satisfied that it is in charge, producing the same average Lambda in Closed Loop.

    Stock O2 Sensor
    [​IMG]

    Wideband O2 Sensor
    [​IMG]

    Next I will get some highway riding time in.
    #24
  5. ROHrider

    ROHrider n00b

    Joined:
    Dec 20, 2011
    Oddometer:
    2
    Hi.
    Sounds like you've made a real improvement! Great work but it does seem like a lot of work. Why didn't you just install something like the Rhine West performance chip? Look forward to your reply.
    #25
  6. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Thank you. The design and testing has taken some effort.

    I see two choices for solving the "lean burn" Closed Loop weakness.

    1) Take out the O2 sensor and go Open Loop all the time. Or rechip or Powercommander or some other way to stay open loop.

    2) Put in an O2 sensor that can be reprogrammed to a different switching value than Lambda=1.

    I wanted to keep the Cat Converter and the standard Motronic so the choice was #2.

    It was a lot of work to figure it out. I don't think it will be a lot of work to implement a second time. My next efforts will be to determine the minimum change that will produce the desired results, and some fine tuning of the LC-1 parameters.

    My conclusion is that the Boxer engine in the R1150 was not really designed to operate with a 14.7:1 mixture (lambda=1). So my two fixes:

    1) A BoosterPlug to correct Open Loop for E10 fuel.
    2) A programmable Wideband O2 Closed Loop sensor to richen Closed Loop operation.

    Roger
    #26
  7. ROHrider

    ROHrider n00b

    Joined:
    Dec 20, 2011
    Oddometer:
    2
    Hello again Roger.
    I see from the screen shot above that you programed the Analog Out #1 lead as follows:
    1) clicked the box "use air fuel ratio,
    2) 0.9 volts at AF 13.7,
    3) 0.103 volts at AF 14.7.
    Is that correct?
    Did you use any of the "Advanced" programing features? Thanks for your reply.
    Robert
    #27
  8. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    I am still experimenting with all four numbers. Two voltages and two AFRs. Also trying different advanced filtering numbers.

    The main feature of the advanced tab is how fast the sensor responds. Nothing set there yet.
    #28
  9. Poolside

    Poolside Syndicated

    Joined:
    Apr 1, 2003
    Oddometer:
    11,887
    Location:
    Silicon Beach, CA
    It's really cool that you went for this, and especially cool that you posted up the data in this thread. Hats off to you for taking on this project!

    In sort of an aside, I've been wanting to ask you about the FI aircraft operation you spoke about in the MOA thread. (Since I'm not a member, I hope you'll excuse me asking it here.) You mentioned that you leaned the motor to a Best Power of <14:1 mixture, and also a >15:1 Best Economy mixture. Was the process to lean the mixture to peak EGT, then go a little richer for a cooler EGT? Did the motor have an EGT sensor on each exhaust port?


    p.s.: A -30°C offset in the Intake Air Temp sensor will better make up for open loop leanness when using E10 fuel. The IICE Air has a -30°C setting. If you want one send me a PM.

    <BR>
    #29
  10. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    If you want to skip the narrative, a direct answer is near the end. Will send you a PM about IICE AIR, thank you.

    The aircraft I operated for a couple decades had a 300 HP, six-cylinder horizontally-opposed engine (like three Boxer engines back to back to back ;) ). There were three main power management controls: throttle, propeller speed (think if it like the transmission), and fuel mixture. It was fuel injected in much the same manner as the R1150 engine, except there was no fuel computer (or O2 sensor!). Engine management was (and still is) a duty of the pilot in that aircraft (a Beech A36, kind of an R1150 of the air).

    Getting engine management right in an aircraft is a critical duty. Get it wrong and you: damage the engine, run out of fuel, travel more slowly and/or spend more money for the same trip--or all of the above. If you want to get anywhere in a hurry, you get to cruising altitude, set propeller speed and throttle for 75% of full power (where you will operate for a few hours) and lean the mixture.

    I had a single-probe EGT (exhaust gas temperature) system which I later upgraded to a 6 probe (one per cylinder) gauge.

    Here is how power is managed (from memory, not from my checklist):

    Annual Inspection: Full rich fuel-flow is checked and set to specification for full-power, mid-power and idle, at sea-level.

    Take-Off: Hold Brakes, Tank switch to fullest tank, mixture to Full Rich, propeller to full RPM, throttle to Wide Open, at full power, release brakes and take off. (If taking off at an airport above sea level, lean mixture to spec.)

    In flight leaning:
    Best Power Setting: from the Full Rich setting, lean mixture to peak EGT (first cylinder to peak in a 6 probe system), then richen mixture to 100 degrees F below peak EGT.

    Best Economy Setting: from the Full Rich setting, lean mixture to peak EGT (first cylinder to peak in a 6 probe system), then lean mixture to 100 degrees F below peak EGT.

    An interesting side note: the one place the engine was NEVER operated was at the Stoichiometric mixture of 14.7:1 as it is neither the Best Power point nor the Best Economy point.
    #30
  11. Poolside

    Poolside Syndicated

    Joined:
    Apr 1, 2003
    Oddometer:
    11,887
    Location:
    Silicon Beach, CA
    <table border="0" cellpadding="5" width="650"><tr><td>A36 = R1150 Sounds right to me. :D

    Good deal, you had the full 6cyl EGT system. Did you have the matched injector set as well?

    That's the thing about the 14.7 stoichiometric mixture, it isn't optimum. Electronic Fuel Injected and catalyst-equipped motors aren't operated at 14.7 either. Instead the mixture is cycled above and below stoichiometry. Which alternately creates an oxygen-rich, followed by an oxygen-lean, exhaust. The alternating oxygen-rich to oxygen-lean exhaust is necessary to operate the catalyst.
    </td></tr></table>
    <BR>
    #31
  12. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Yes, agreed it switches between something above the set point and something below it. When I use the term setting closed loop AFR to 14.2, I mean that's the center of a range, the average AFR. In the case of 14.2, I'm running 13.7 to 14.7 at the moment but am still conducting tests.

    Today I kept boosting AFR to see when the idle stumbled. Also noted that after a couple days of running 14.2 the bike is idling faster. Like it's cleaner. (?)

    Ciao
    #32
  13. Poolside

    Poolside Syndicated

    Joined:
    Apr 1, 2003
    Oddometer:
    11,887
    Location:
    Silicon Beach, CA
    <table border="0" cellpadding="5" width="650"><tr><td>The 14.7 ratio isn't a set point, it's a coincidental average of the Exhaust Oxygen swings. I know, it sounds like I repeated what you just said, but I didn't. The thing is, the ECU and the catalyst require the high and low cycling exhaust oxygen levels, not the average value. The oxygen-rich and oxygen-lean swings are for the catalyst to 'breathe' so to speak. The catalyst needs the high and low oxygen swings, not the average value.

    The modified O2 sensor signal from your LC-1 causes the ECU to alter the exhaust oxygen swings, which affects the chemical processes going on inside the catalyst. With the modified O2 sensor signal, the ECU feeds the catalyst more fuel, along with enough oxygen to complete the 'chemical combustion' (aka: oxidation) process going on inside the catalyst. This is dangerous.

    When the catalyst is provided a sufficient quantity of oxygen and fuel ingredients, the oxidation process in the catalyst becomes hot enough to turn the stainless steel exhaust components into solder. There is a way around this.
    </td></tr></table>
    <BR>
    #33
  14. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Thanks for the scare! ;)

    In the ranges I'm running, there has been a lot of data taken by others and it's not at all a concern to me. During warm up, my motorcycle runs in the 12s and low 13s. (Others have even disconnected the O2 entirely.) As I side note, I've been monitoring converter temperature and it hasn't risen or dropped noticeably. Interestingly, the temperature going into the Cat is much lower as the mixture is richened.

    A misfiring cylinder with raw fuel entering the converter could do a lot of damage, like you mention, especially if there is an air leak to provide the amounts of oxygen needed.

    Lastly on the issue of risk, the performance gains alone make a small risk (if it even exists) worthwhile. Flying is a risk, motorcycle riding is a risk, my age is a risk. I think I'll just find the best points (the high low limits of Lambda) and enjoy the smooth performance and riding when the spring comes to the Northeast. I should have things worked out by then!

    Happy Holidays to All,
    Roger
    #34
  15. Poolside

    Poolside Syndicated

    Joined:
    Apr 1, 2003
    Oddometer:
    11,887
    Location:
    Silicon Beach, CA
    <table border="0" cellpadding="5" width="650"><tr><td>I'm not talking about risk per se, more I'm talking about understanding the physical processes, and how and why the electronics control those processes.

    Happy Holidays to you as well!
    </td></tr></table>
    <BR>
    #35
  16. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    For those interested in the most arcane aspects of this project, might like to try it or who might offer some insight:

    --Both the heater and the sensor are isolated from the case (meaning they are not grounded to the exhaust) in this four wire sensor.

    --The wire called signal ground seems to have a 100 ohm source impedance (more to be confirmed), and the open circuit voltage is 140 mV. Since the sensor is isolated from the case, this strongly suggests that the entire sensor signal is offset by 140 mV. I have read that the reason for this offset is to allow shorted and open leads to be detected by the ECU--makes sense. Right now I may have the +Signal going negative relative to the -Signal.

    --I have also read that the ECU builds closed loop adaption tables so I should be doing a full reset of the ECU each time I change an LC-1 parameter.

    --This signal + side seems, from research, to be routed to a dual comparator circuit that creates a +/- 25mV hysteresis window.

    Although things are working really well, I am not convinced I am getting a perfect rich/lean toggle yet so I will probably go and get an oscilloscope so that I can look into all this with a bit more certainty.
    #36
  17. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    More measurements. It turns out that the sensor does float on a signal 140 mV above ground. Any O2 sims like mine have to add this to the lc-1 or other o2 computer. Although I'm still fine tuning, the bike is running strongly at 14.2:1 (13.7 to 14.7) Closed Loop. Will continue to report the clean-up work. The challenge is getting two sensitive computers, motronic and lc-1 to each love the new environment and for the motronic to be blind to it. I expect to refine:

    --Wiring length
    --Component positions
    --Motronic heater emulation
    --Electrical noise
    --Simulated o2 rise time.

    In spite of these planned improvements the bike continues to be smooth and powerful through all gears over a much wider RPM range.
    Roger
    #37
  18. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    In the photos below are the settings for the Innovate Motorsports LC-1 Wideband O2 Sensor that I used on my R1150RT to drive the stock, narrowband O2 sensor inputs to the Motronic. To summarize the project:

    --I wanted to smooth out the performance of my motorcycle at low RPMs and remove all sense of hesitation in the 2000 to 4000 RPM band, even though the bike had already been fully tuned and balanced and didn't seem to have any surging.

    --My test runs with the GS-911 showed that the R1150 spends almost half its time Closed Loop, meaning using the O2 sensor and toggling the Air Fuel Ratio (AFR) just above and just below 14.7:1. This is a leaner mixture than the so-called Best Power mixture for most engines, and I felt it likely the cause of a "holding back" or lean-ness that I felt in the 2000 to 4000 range.

    --I wanted to allow the Motronic to operate the bike as it was designed to do, including Closed Loop with an O2 sensor and CAT.

    --I replaced the stock O2 sensor which only allows Closed Loop AFR of 14.7:1 (gasoline) with a Wideband sensor who's AFR could be programmed to something between 13.0:1 and 15.0:1 so that I could find an AFR near 14.7:1 at which the bike ran its best. The product I chose is the Innovate Motorsports LC-1.

    At this point using a target AFR of 14.2:1 (actually Lambda = 0.97), the project seems successful. Now the bike seems smooth and powerful from 1,500 RPM to 6,000 RPM--no surge, no hesitation, no stumbling, no "holding back". I can easily drive local roads in 5th gear and now regularly run RPMs around town between 2,500 and 3,500.

    The installation is complete and stable but the LC-1 is not an easy Plug 'n Play solution. You have to connect it to power and ground, and have to connect it to the narrowband input wires of the stock O2 sensor. I did it quickly and left 5' of cable attached to the LC-1. I will cut that back, reroute the wires and check noise levels with an oscilloscope to determine the best wire routing. I will also rethink where the LC-1 (weatherproof) gets located.

    Below are some screenshots of the LC-1 software and also one from the GS-911 showing its reports of how the Motronic sees the voltage toggling. It looks pretty good.

    Thanks to everyone for the comments and support.
    Happy Riding in the New Year,
    RB

    Plots and Comments:

    The is the plot of the GS-911 toggling O2 around the setting of Lambda=0.97 or AFR 14.2:1. It goes solidly and regularly above and below the Motronic switching levels and produced a steady stream of cross-counts.
    [​IMG]

    This is the LC-1 first setup page. I left Stoichiometric at 14.7 (rather than adjust to 14.13 of E10 fuel) since it's easier to think in those terms. It only affects the display of operation, not the settings.
    [​IMG]

    Here are the voltage and Lambda settings that created the best O2 toggling waveform. They take into account a 140mV low side offset that I discovered in the Motronic, and produce a sharp change from Lambda=0.965 to 0.975.
    [​IMG]

    I selected updating 12 times per second as a way to keep the Motronic from over-responding to the very sensitive LC-1.
    [​IMG]


    Here are some usual plots with stock O2 sensors according to the GS-911 manufacturer. You can see that the usual plots are a bit jagged. This is because the GS-911 doesn't produce realtime data points, just every 200mS or so. If you go their site they also show some others, including bad plots.: http://www.hexcode.co.za/techinfo/lambda

    [​IMG]

    [​IMG]
    #38
  19. Andrew

    Andrew Optimus Primer Super Moderator

    Joined:
    Sep 25, 2001
    Oddometer:
    16,936
    Location:
    Eastbania
    What are the units of Time on that plot of lambda sensor voltage? The data seem severely under-sampled.
    #39
  20. roger 04 rt

    roger 04 rt Long timer

    Joined:
    Nov 9, 2011
    Oddometer:
    2,712
    Location:
    Massachusetts
    Hi Andrew,

    You've written like someone familiar with digital signal processing. The manufacturer of the GS-911 doesn't state the time interval, just says it's faster than logging to a file. I'm estimating 200-300 mS. There is also no indication that the sampling is at a steady frequency--so no assurance of coherence. If you look earlier in the thread, I think I've plotted a sequential distribution of voltages reported. They are fairly linearly distributed with no sampling "holes". I'm going to round up an oscilloscope sometime this winter and get some additional info.

    Bottom line is that the swings and crossings are good enough to satisfy the Motronic and they are very similar to how the stock sensor looks.

    Here are what they say are usual plots: http://www.hexcode.co.za/techinfo/lambda

    [​IMG]

    [​IMG]
    #40