Announcement

Collapse
No announcement yet.

An Engine Simulator is Born - Part 1

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    I turned my attention tonight to the ECU again... I have lashed up something on the bench that allows me to simulate the RPM sensor (G28) by way of the 'crankwheel pulser' software that I used in the past. I had the emulator watching some code blocks as well to start to establish where it jumps around depending on what is going on.

    Some quick highlights --->

    G28 amplitude needs to be above 0.5V pk to pk before the ECU clears the 'no G28 fault'.

    The fuel pump relay is activated when RPM exceeds 13rpm (yes - thirteen).

    No injection or spark pulses are triggered when it receives healthy G28 input at nominal idle speed - as you would expect

    The RPM output from ECU is not activated in this 'G28 only' mode


    Next step is to build G4 and G40 simulators and fool the ECU into thinking it is attached to a real engine - moving into normal maps that can be traversed synthetically - I love it when a plan comes together, but I need to start making a proper box for this beast - I am drowning in spaghetti and running out of space to work in
    Paul Nugent
    Webmaster http://S2central.net
    Administrator http://S2forum.com

    1994 S2 Coupe ABY - aka Project Lazarus
    2001 A6 allroad 2.5TDi - family tank
    2003 S4 Avant 4.2 V8 - daily burble

    Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

    There are only 10 kinds of people that understand binary - those that do, and those that don't

    Comment


    • #32
      Hallelujah! This rocks! These details coming up - in addition to the understanding in general - will also be very helpful with reducing the trouble we all have with the niggles when some little thingy stops to cooperate. So please, keep on rockin
      '93 Audi S2 Avant panthero black, 412.000km
      '94 Audi S4 C4 Avant 303Tkm, KW, Brembos, BN-Pipes, Bose, S6 front (sold)
      '93 Audi S4 C4 Avant, 260Tkm
      '88 Audi 100 Avant turbo 44Q
      '84 Audi 80 quattro tornado red
      sigpic

      Comment


      • #33
        One annoying thing is that CWP package is very processor intensive - I can export the G28 WAV files into an old iPod and use that as the source instead - that will free up a lot of CPU power to run the emulator. I can create a number of G28 profiles - at idle or whatever sweep of revs... dunno how cleanly the ipod would loop them, but it takes me to the next logical thought...

        An iPhone application could be used to control the audio output - I have no skills in that area to build such a thing but it would be easy for a softie with the iPhone developers kit - it could easily be extended into a more generic signal generator program of course rather than 5cyl Audi flywheels. mmmmmmmmmmm

        In the middle of typing this I just looked on the app store and sure enough there is quite a range of generic sig-gen apps - some free, some not. I will have a look to see if any are worth any cop.
        Paul Nugent
        Webmaster http://S2central.net
        Administrator http://S2forum.com

        1994 S2 Coupe ABY - aka Project Lazarus
        2001 A6 allroad 2.5TDi - family tank
        2003 S4 Avant 4.2 V8 - daily burble

        Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

        There are only 10 kinds of people that understand binary - those that do, and those that don't

        Comment


        • #34
          Two free apps - Oscillator Free and FreqGen are definitely usable here for quick tests... But if any iphone developers are listening - send me a PM and we can discuss how to create a generic audio tone generator for a variety of flywheels. Oh there must be millions of potential customers - LOL !!!
          Paul Nugent
          Webmaster http://S2central.net
          Administrator http://S2forum.com

          1994 S2 Coupe ABY - aka Project Lazarus
          2001 A6 allroad 2.5TDi - family tank
          2003 S4 Avant 4.2 V8 - daily burble

          Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

          There are only 10 kinds of people that understand binary - those that do, and those that don't

          Comment


          • #35
            You will need two different synchronized asymmetric waves to simulate cam and hall sensor outputs on left and right channel perhaps - that's a challenge!
            '93 Audi S2 Avant panthero black, 412.000km
            '94 Audi S4 C4 Avant 303Tkm, KW, Brembos, BN-Pipes, Bose, S6 front (sold)
            '93 Audi S4 C4 Avant, 260Tkm
            '88 Audi 100 Avant turbo 44Q
            '84 Audi 80 quattro tornado red
            sigpic

            Comment


            • #36
              No that is easy... just using WAV to generate G28 on one audio channel... then I build some logic & counters to create G4 & G40 simulators that are synchronised to that as a clock input. HLD is complete on that - I will build a prototype for those soon.

              I need to collect some more data about pulse shapes from a real engine before I get into next level of detail on that but its just a matter of counting teeth. Watch this space
              Paul Nugent
              Webmaster http://S2central.net
              Administrator http://S2forum.com

              1994 S2 Coupe ABY - aka Project Lazarus
              2001 A6 allroad 2.5TDi - family tank
              2003 S4 Avant 4.2 V8 - daily burble

              Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

              There are only 10 kinds of people that understand binary - those that do, and those that don't

              Comment


              • #37
                FYI - tried the iphone audio apps for G28 simulation and they work fine. You need line level output of course - the headphone jack is a bit feeble. The line level output is approx 1V pk to pk and the ECU is happy enough - pretty impressive when it expects to get circa 15V pk to peak input from the real sensor.

                I have snagged some nice pics that will help me - and anyone else chasing timing / sync issues on their S2.

                To describe the important bits real quickly...

                G40 pulse is 16 flywheel teeth wide

                G4 crank pulse arrives twice as fast as G40 of course but when it overlaps you can see it is nominally in the centre of the G40 window. The -ve portion of pulse is about 2-3 teeth wide, as is the +ve portion... this could be trickiest one to simulate if ECU is fussy about pulse shape but I'll try simplest / cheapest approaches first to see what it can be fooled with.
                Paul Nugent
                Webmaster http://S2central.net
                Administrator http://S2forum.com

                1994 S2 Coupe ABY - aka Project Lazarus
                2001 A6 allroad 2.5TDi - family tank
                2003 S4 Avant 4.2 V8 - daily burble

                Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

                There are only 10 kinds of people that understand binary - those that do, and those that don't

                Comment


                • #38
                  Awesome stuff
                  1995 RS2 on Alcohol (6.8sec 100-200km/h)
                  1994 80E Avant
                  1986 2L Golf 2 on Alcohol

                  Comment


                  • #39
                    Three pics attached - from real ABY idling.

                    Yellow trace is G28 (RPM) - flywheel teeth

                    Blue trace is G4 (Crank Reference) - appears every 135 teeth

                    Green trace is G40 (Camshaft pulse) - every alternate crank rotation

                    Scales are visible at a number of resolutions so you can see what is happening. At idle you have to run scope in signal shot mode to capture like this due to low frequency of pulse arrival.
                    Attached Files
                    Paul Nugent
                    Webmaster http://S2central.net
                    Administrator http://S2forum.com

                    1994 S2 Coupe ABY - aka Project Lazarus
                    2001 A6 allroad 2.5TDi - family tank
                    2003 S4 Avant 4.2 V8 - daily burble

                    Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

                    There are only 10 kinds of people that understand binary - those that do, and those that don't

                    Comment


                    • #40
                      Well done mate...
                      I wish I had all the electronics lying around to do this, I have a spare ECU...
                      http://tuner.ee - http://www.facebook.com/tuner.ee

                      Comment


                      • #41
                        Bit of an update... I finally found some software that will let me simulate G4 & G28 signals AND let me synchronise them in a sweep as well. This saves me lots of faffing about with electronic parts to build stuff. All I need to build is a simple thing to emulate G40 - triggered by every other crank pulse. Hopefully I can find the time to move this forward at a decent pace.
                        Paul Nugent
                        Webmaster http://S2central.net
                        Administrator http://S2forum.com

                        1994 S2 Coupe ABY - aka Project Lazarus
                        2001 A6 allroad 2.5TDi - family tank
                        2003 S4 Avant 4.2 V8 - daily burble

                        Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

                        There are only 10 kinds of people that understand binary - those that do, and those that don't

                        Comment


                        • #42
                          Paul, have you worked on this at all?
                          I think I will continue where you stopped...

                          Need to get a 12 volt power supply... and other things.
                          Which pins of the ECU did you attach?

                          Besides the obvious ones, like the +12V and the sensor signals, there's a ton of grounds as well.
                          http://tuner.ee - http://www.facebook.com/tuner.ee

                          Comment


                          • #43
                            I havent done anything on this in ages... too much day job and family stuff takes priority unfort. I'm hoping to progress it sometime this year. Simulating the crank sensor signal is the hardest part - but I found good audio software for that. I did buy some counter chips and other logic but its all lying in a box somewhere
                            Paul Nugent
                            Webmaster http://S2central.net
                            Administrator http://S2forum.com

                            1994 S2 Coupe ABY - aka Project Lazarus
                            2001 A6 allroad 2.5TDi - family tank
                            2003 S4 Avant 4.2 V8 - daily burble

                            Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

                            There are only 10 kinds of people that understand binary - those that do, and those that don't

                            Comment


                            • #44
                              I can write software myself, it's not an issue.
                              I'm more interested in what is needed to have the ECU run IEX3 and IEX0.

                              From what I gather:
                              +12V
                              Grounds
                              G40 signal
                              G28 signal
                              G4 signal
                              MAF signal

                              Nice to have:
                              Diagnostics?

                              Anything that I am missing?
                              http://tuner.ee - http://www.facebook.com/tuner.ee

                              Comment


                              • #45
                                The MAF signal is probably not needed to make the ECU come alive - but a potential divider is dead easy way to simulate say idle voltage. It will throw up lots of faults for missing sensor inputs - and you can check those with OBD hooked up.

                                Why bother writing audio software when you can download 'DAQARTA' for free ?

                                Its easy to create the wave shapes and synchronise G4 with G28 - then you just need counter logic to simulate G40... You can use software to hold signals steady or sweep as required - nice for scanning across some maps.
                                Paul Nugent
                                Webmaster http://S2central.net
                                Administrator http://S2forum.com

                                1994 S2 Coupe ABY - aka Project Lazarus
                                2001 A6 allroad 2.5TDi - family tank
                                2003 S4 Avant 4.2 V8 - daily burble

                                Purveyor of HomeFries and Exclusive agent for Samco hose kits (S2/RS2)

                                There are only 10 kinds of people that understand binary - those that do, and those that don't

                                Comment

                                Working...
                                X