Announcement

Collapse
No announcement yet.

Speeduino build for M20B25

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Speeduino build for M20B25

    Introduction:
    The reason I'm starting this thread because I don't see any other threads on here using Speeduino ECU for the M20B25. I am completely new to tuning/aftermarket ECUs, so I can pretty much guarantee that some of the info I will post in this thread will be completely wrong. After doing some research on aftermarket ECU options there really doesn't seem to be anything budget friendly other than reprogramming the ECU. The cheapest option(other than a Speeduino) seems to be a Megasquirt PnP which is ~$750. The Speeduino should be ~$150 in parts, so I decided to give it a try, and if I failed it wouldn't be a bad price for a good learning experience. I plan to update this post as I go along tuning and figuring out the correct setting for my car.

    Goal:
    I am building up my e30 and slowly getting it running NA. Eventually I want to turbo it, and do it on a budget. It's my first real project car and it isn't my daily so I'm ok with making some mistakes. The end goal for this thread is hopefully to gather enough information so people can have an easier time setting things up.

    Resources:
    I am using a custom Speeduino PCB designed to fit in the original ECU box designed by Raku on the Speeduino forums: https://speeduino.com/forum/viewtopic.php?f=16&t=2667
    Speeduino setup wiki: https://wiki.speeduino.com/
    Great writeup on MegaSquirt, but has tons of useful information for us about wiring: https://www.r3vlimited.com/board/for...ild-and-wiring
    Speeduino base tunes for M50TU engine, this is not a base tune for the M20: https://github.com/pazi88/Speeduino-...P/Base%20Tunes

    PCB Build:

    Had to order the custom PCB from JLPCB, the design for it can be found on the Speeduino forums, the specific board revision is 1.7 if anyone is following along. There was a minimum order quantity, so I ended up ordering 10 pcbs, if anyone needs a PCB pm me.
    Click image for larger version

Name:	35cUJ5B.jpg
Views:	5824
Size:	77.5 KB
ID:	9949647

    The parts can also be found on the Speeduino forums and can be ordered from multiple websites. I had issues finding all of the parts, and didn't want to wait a long time for some to come back in stock so I ended up ordering most of them from WTMtronics. Doing it this way is a little pricier, but helped me out a lot. I just sent the part list to the guy that owns WTMtronics and he sent me back a list of the parts he had in stock and which ones he was missing.

    Building the board was pretty straight forward, just pull up the BOM which tells you which parts goes to what location and just solder it in. A helpful tool when doing this is opening the PCB file in easyDEA and then you can ctrl + f and search for the part location to speed up the process of trying to find where to solder the specific parts. Be careful not to solder every single part on the board since there is a circuit on the board for the active low and active high clutch. You need to figure out which one your car has and solder that. Mine is not soldered because I don't have either since I did and auto to manual swap and never bothered installing a clutch switch. It's not needed unless you plan to do launch control or flat shift.

    When soldering the parts I like using a solder that has lead in it because it seems a lot easier to work with. If you don't have a soldering iron, I would recommend a TS100 soldering iron.

    If you want to use the stock Crank Position Sensor you will also need to buy a VR Conditioner. This converts the signal from our CPS to a signal that our ECU can read. You will need to solder SJ1 pin 2 and 3 on the board if using a VR Conditioner.
    Click image for larger version

Name:	g6TvDIG.jpg
Views:	4986
Size:	32.3 KB
ID:	9949646

    Here is the complete board, you can see that I have the clutch components missing, and I also have Q2 missing. The reason Q2 is missing is because I ended up burning up Q1 when I first plugged the board into my car because I had the spark output trigger as going high instead of going low. I didn't have extra parts so I removed Q2 and replaced Q1 with it. I don't think Q2, Q3, Q4, Q5, Q6 is needed unless you are running wasted spark. I am currently running the stock distributor and it seems to only use q1.
    Click image for larger version

Name:	6N20Ckt.jpg
Views:	5868
Size:	60.3 KB
ID:	9949644
    Click image for larger version

Name:	xODGGAK.jpg
Views:	5027
Size:	54.2 KB
ID:	9949645

    The only solder joint configurations that I have soldered for my setup are SJ1 pin 2 and 3. You would solder SJ1 pin 1 and 2, SJ4, and SJ3 if using a Hall-Effect CPS.
    Click image for larger version

Name:	k4ljQt6.jpg
Views:	5271
Size:	68.7 KB
ID:	9949643
    Last edited by sk8; 09-08-2020, 12:42 PM.

    #2
    Changes to the car needed:
    TPS
    The stock TPS on the e30 only has 3 modes, closed, open, and wide open. We need a TPS that reads throttle percentage. Most people use a TPS from an E36 and convert the wiring harness.
    You will need to fab up a bracket to adapt the e36 TPS to the e30, or order one online.
    There is a great writeup on this that has part numbers for the connectors and wiring in this thread https://www.r3vlimited.com/board/for...ild-and-wiring
    If you end up buying the connectors, make sure to buy the sockets with it, otherwise you will just get a connector and have to make another order for the sockets (Ask me how I know).

    IAT Sensor
    You can use the default one that is in the AFM, but I think it's better to use a GM open air sensor. What I did was removed the AFM, and used a PVC pipe in its place. I tapped a hole in the PVC pipe for the sensor. The new IAT sensor will still wire into the stock harness. It is the two outside pins, pin 1 and pin 4. I don't think orientation for this sensor matters since our ECU just measures the resistance to tell the temperature.
    Click image for larger version  Name:	IMG_20200908_121140 copy.jpg Views:	0 Size:	73.0 KB ID:	9949607

    Wideband
    You will need a wideband o2 sensor and a controller for the sensor. I ordered the SLC 2 Free from 14point7. Unfortunately I think I got a defective controller the readings don't change and the sensor doesn't heat up. I have a replacement on the way. For now I am borrowing a LC-2 wideband controller from a friend.
    The wiring for this is pretty straight forward. You will need to wire the positive lead from the controller to the fuel pump relay, or something that gets power when the key is turned to the on position, if anyone has better suggestions please let me know. The ground can go to the negative terminal on battery or a ground anywhere on the chassis. The wideband output will go to the bottom middle pin in the IO header on the Speeduino.
    Click image for larger version

Name:	TwWvUkT.jpg
Views:	4705
Size:	29.9 KB
ID:	9949636
    If you are using an LC-2 wideband controller and just bench testing it you may have issues reading the output in tuner studio if the Speeduino and wideband controller doesn't share a ground.

    Vacuum line for the MAP sensor
    I have a vacuum line running from the manifold to the fuel pressure regulator, so I just used a T fitting on that line and added a vacuum line from the T fitting to the Speeduino.
    Click image for larger version  Name:	IMG_20200908_121147 copy.jpg Views:	0 Size:	65.2 KB ID:	9949608
    Last edited by sk8; 09-08-2020, 12:19 PM.

    Comment


      #3
      TunerStudio Configuration:
      I can not find any M20B25 base tune for Speeduino. On the Speeduino forums there is a base tune for the M50TU so I took that as a base tune and started tweaking settings. I'm sure a lot of the following settings are wrong, but I was able to get the car to crank and "run" with these settings. I have never tuned a car before so I am very new to this. Please let me know if any of these are wrong and I will do my best to keep this post updated.

      Settings -> Engine Constants:
      Click image for larger version  Name:	EYQ3Ows.png Views:	451 Size:	317.3 KB ID:	9949624
      My engine has stock injectors which I think are 14.2, if you have different injectors you will want to update the Requried Fuel value.
      From documentation I read somewhere, you want to keep your (ms) in required fuel between 10-14 for best operation. You can change the Squirts Per Engine Cycle and Injector Staging which will change your ms value.

      Settings -> Injector Characteristics:
      Click image for larger version  Name:	Z7hZiHA.png Views:	441 Size:	126.8 KB ID:	9949625
      I didn't change these at all from the base tune provided for the M50TU engine. I don't know much about what is supposed to be here.

      Settings -> Trigger Settings
      Click image for larger version  Name:	Ywl6wf7.png Views:	436 Size:	306.7 KB ID:	9949626
      The crank has 60 teeth and 2 missing.
      Ran into a really weird issue with trigger angle, initially had 84 for the angle. Car would start up but definitely knocked and didn't run right. Bought a timing light and verified the trigger angle and 84 was not correct, the value needed was 50 for the trigger angle which is really weird, but car ran great. When I went to upgrade to wasted spark I was having issues with the car starting. Pulled my timing light out again and verified the trigger angle with wasted spark, and it changed from 50 to 276. Not sure why the trigger angle would be different when using the stock cap/rotor and going to wasted spark, but 276 lines up with what everyone else seems to be running on a m20.

      Spark -> Spark Settings
      Click image for larger version  Name:	TcYdIQV.png Views:	435 Size:	293.0 KB ID:	9949627
      For Spark Output Mode set it to Single Channel if you are using the stock distributor.
      With a Speeduino make sure you have the Spark Outputs Triggers set to Going Low.
      If it is set to going high, when you turn your ignition key to the on position you will start smelling burning plastic and Q1 on your board will get extremely hot and start smoking.

      Spark -> Dwell Settings
      Click image for larger version  Name:	kybx8mo.png Views:	447 Size:	243.0 KB ID:	9949628
      Last edited by sk8; 02-12-2021, 08:53 AM.

      Comment


        #4
        Sartup/Idle -> Cranking Settings
        Click image for larger version  Name:	l04IyLm.png Views:	467 Size:	230.1 KB ID:	9949630

        Tuning -> VE Table
        Click image for larger version  Name:	qlsBdht.png Views:	436 Size:	446.6 KB ID:	9949631
        This has not been tuned by a professional or anyone that knows what they are doing. I have changed some values around and the car cranks.
        It will run pretty rich ~11 AFR when idling at 1100 RPM.
        If anyone knows how to tune and has some time, reach out to me and we can connect and get a base tune setup.

        Tuning -> Spark Table
        Click image for larger version  Name:	SFlTIJ9.png Views:	445 Size:	547.8 KB ID:	9949632
        Same thing here, I left this alone. I'm sure most of these values are incorrect but it seems to work for just cranking the car.

        Startup/Idle
        Click image for larger version  Name:	EkUDW07.png Views:	444 Size:	219.4 KB ID:	9949633​
        Starting out I am using PWM Open Loop.
        After doing tons of digging I found a post somewhere saying it is 90hz.
        Setting the duty cycle to 38 seems to make the car idle ~1100 rpm.
        33 was about 800 rpm
        45 was about 1400 rpm
        I think you want to find the frequency that gives you the most adjustment, so I pulled the ICV off and played around with it.
        At 100hz the valve is fully open at duty cycle 70 and fully closed at 34
        At 80hz fully open at 84, fully closed at 33
        At 60hz fully open at 83, fully closed at 31
        I think the best value to use is probably a little lower than 90hz, but you should play around with your ICV to get the best settings.


        Before starting the car
        Make sure you have all of your sensors calibrated by going to Tools -> Calibrate {sensor}
        Your IAT and Coolant temp should be around the same temp before you first crank the car, if not the sensors might not be configured correctly.
        You may want to start by unplugging your ICV, setting the Idle Control type to none, and just adjusting how much air your engine gets by using the screw on the throttle body to open/close it.
        I'm sure there are many other things you want to check before cranking the car for the first time, this thread is still a work in progress.

        I will update this post with new information and update the things I have wrong once I figure this out. Hopefully this helps someone that is looking to build a Speeduino get started. If anyone knows how to tune and wants to contribute, reach out to me and we can get something set up, and if any of my settings look completely wrong please let me know and I will update them.
        Last edited by sk8; 02-12-2021, 09:01 AM.

        Comment


          #5
          Very cool, and great job documenting everything you are doing. Since the Speeduino platform seems to have a bunch of different MCU cores (Arduinos, Teensy boards, etc), which one are you running? I have seen a lot of guys starting to run the Teensy 3.x boards since they pack so much performance in, and now the Teensy 4.x ones are like >3x faster!

          Transaction Feedback: LINK

          Comment


            #6
            Originally posted by bmwman91 View Post
            Very cool, and great job documenting everything you are doing. Since the Speeduino platform seems to have a bunch of different MCU cores (Arduinos, Teensy boards, etc), which one are you running? I have seen a lot of guys starting to run the Teensy 3.x boards since they pack so much performance in, and now the Teensy 4.x ones are like >3x faster!
            I am running a Arduino Mega 2560, using it because that's what I had laying around. I think to run the Teensy boards you have to build an adapter and do some modifications to the Teensy (https://www.pjrc.com/teensy/external_power.html).

            Comment


              #7
              I am working on reprogramming the ECU with an Ostrich 2.0 emulator.
              The ignition table looks familiar.
              You could take the stock values for ignition. Using Tuner Pro and a definition file, and the BIN file, you can see the ignition advance. There are a number of tables. Idle, Low part throttle, High part throttle and WOT.
              If you don't want to install TunerPro, I can try to figure out how to convey the values. Either a screen shot, or a comma separated file...

              Comment


                #8
                Originally posted by Tinkerer007 View Post
                I am working on reprogramming the ECU with an Ostrich 2.0 emulator.
                The ignition table looks familiar.
                You could take the stock values for ignition. Using Tuner Pro and a definition file, and the BIN file, you can see the ignition advance. There are a number of tables. Idle, Low part throttle, High part throttle and WOT.
                If you don't want to install TunerPro, I can try to figure out how to convey the values. Either a screen shot, or a comma separated file...
                Unfortunately I don't have a windows machine to play around with Tuner Pro. I'm not sure if you can translate table values since mine are based off the map sensor.

                Comment


                  #9
                  Here isthe ignition Low Part Throttle timing map. You might be able to extrapolate values to your Map sensor values. And atleast the changed by RPM should be consistent.

                  RPM in the left column. AFM value in top row.
                  14 38 48 60 74 90 110 130
                  680 20 20 21 24 24 16 7 2
                  800 21 21 21 24 24 16 10 6
                  1120 22 22 22 24 24 18 15 10
                  1440 31 29 26 24 24 20 19 15
                  1760 39 37 33 30 29 25 25 20
                  2080 39 37 33 31 30 28 28 24
                  2680 39 37 34 31 30 30 30 30
                  2920 39 37 34 31 30 30 30 28
                  3620 35 33 32 30 28 26 24 19
                  4000 35 33 32 30 28 26 24 19
                  4520 33 32 31 30 30 28 25 23
                  4820 33 32 31 30 29 26 22 18
                  5000 33 32 31 30 29 25 21 16
                  5220 39 38 37 36 35 33 30 27
                  5520 39 39 38 37 36 36 34 31
                  6000 39 39 39 38 37 36 30 27

                  High part throttle goes from:
                  130 150 170 175 180 190
                  Let me know if these values would be interesting.

                  Here is the WOT map:
                  RPM Deg. Advance
                  800 1
                  1200 8
                  1800 17
                  2400 21
                  3000 30
                  3800 30
                  4200 18
                  4360 18
                  4520 22
                  4800 22
                  5040 15
                  5240 15
                  5480 24
                  5600 29
                  5840 29
                  6200 24

                  Comment


                    #10
                    Originally posted by Tinkerer007 View Post
                    Here isthe ignition Low Part Throttle timing map. You might be able to extrapolate values to your Map sensor values. And atleast the changed by RPM should be consistent.

                    RPM in the left column. AFM value in top row.
                    14 38 48 60 74 90 110 130
                    680 20 20 21 24 24 16 7 2
                    800 21 21 21 24 24 16 10 6
                    1120 22 22 22 24 24 18 15 10
                    1440 31 29 26 24 24 20 19 15
                    1760 39 37 33 30 29 25 25 20
                    2080 39 37 33 31 30 28 28 24
                    2680 39 37 34 31 30 30 30 30
                    2920 39 37 34 31 30 30 30 28
                    3620 35 33 32 30 28 26 24 19
                    4000 35 33 32 30 28 26 24 19
                    4520 33 32 31 30 30 28 25 23
                    4820 33 32 31 30 29 26 22 18
                    5000 33 32 31 30 29 25 21 16
                    5220 39 38 37 36 35 33 30 27
                    5520 39 39 38 37 36 36 34 31
                    6000 39 39 39 38 37 36 30 27

                    High part throttle goes from:
                    130 150 170 175 180 190
                    Let me know if these values would be interesting.

                    Here is the WOT map:
                    RPM Deg. Advance
                    800 1
                    1200 8
                    1800 17
                    2400 21
                    3000 30
                    3800 30
                    4200 18
                    4360 18
                    4520 22
                    4800 22
                    5040 15
                    5240 15
                    5480 24
                    5600 29
                    5840 29
                    6200 24
                    I think we can convert the WOT map, since at WOT we should be right at atmospheric pressure. I will play around with these values when I have a chance. I haven't went for a drive with the car yet as I have just been messing around with idle for now. Thank you for sharing! These are the stock tune timing values right?

                    Comment


                      #11
                      The "AFM" axis in the maps is actually "Load". The AFM is a primary input to the load variable, but the calculation also factors in intake air temp & coolant temp.

                      Transaction Feedback: LINK

                      Comment


                        #12
                        Originally posted by sk8 View Post

                        I think we can convert the WOT map, since at WOT we should be right at atmospheric pressure. I will play around with these values when I have a chance. I haven't went for a drive with the car yet as I have just been messing around with idle for now. Thank you for sharing! These are the stock tune timing values right?
                        Yes, these are from the stock 173 BIN.

                        Comment


                          #13
                          The AFM is more of a speed density (MAP) than it is mass air flow (MAF) in that it calculates the atmo pressure using the IAT, CTS and air vane position. So, punching in the stock numbers will get you close enough to run.

                          Aslo, here's a screenshot of the stock table to make things easier:

                          Click image for larger version  Name:	Stock 173 timing maps.jpg Views:	0 Size:	66.5 KB ID:	9950131

                          The WOT table is separated and is actiave when the WOT switch in the TPS is closed. This was done so that the ECU would revert to open loop and disregard the o2 feedback when in WOT.

                          EDIT: The MS kits are far less than the PnP's. The DIY kits are ~$200 for v2.2 and $250 for v3.0 MS1 boxes.

                          MegaSquirt 1 (MS1) offered a cost effective entry level to the aftermarket ECU market. These are now discontinued, but we still offer several accessories that work with both the MS1 and the newer ECUs in the MegaSquirt line. If you’re looking for more full featured engine management systems we suggest you look at our MegaSquirt 2 and MegaSquirt 3 kits which provide many more features but maintain an affordable price point for total fuel injection and ignition tuning.

                          Last edited by ForcedFirebird; 09-11-2020, 09:28 AM.
                          john@m20guru.com
                          Links:
                          Transaction feedback: Here, here and here. Thanks :D

                          Comment


                            #14
                            Hey guys,

                            Am new here and have been reading quite a bit on this, recently acquired an E30 couple months back and in the midst of converting it to manual. Am also very interested in tuning and have been looking at Speeduino vs tuning the EPROM chip (am aware there are readily available chips) but it's just fun to get started and learn, not so much about the cost but more on enjoying the process.

                            Speeduino seems the be the easiest way to get started, looking at the schematics done by Amila, I wonder if sk8 can share what are the things that will not work with this Speeduino? If i'm not mistaken, speeduino does not has CEL, am I right? so does that mean your Check Engine Light is always turned on? I believe the diagnostics and econometer will not work as well? Am hoping if you can confirm this and appreciate if you could share what other things that will not work with Speeduino.

                            Are there also any notable benefits of going wasted spark vs using the stock distributor?

                            Lastly, I am actually planning on making a M20b30 (starting with a block from M20b25 from a e34), with the increased stroke, are the base tunes for M20 engines the same across the different displacements?

                            Sorry if my questions sounds silly or have been asked before, but I have read as much as I could.

                            Thanks! :)

                            Comment


                              #15
                              Originally posted by ecnerettee View Post
                              Hey guys,

                              Am new here and have been reading quite a bit on this, recently acquired an E30 couple months back and in the midst of converting it to manual. Am also very interested in tuning and have been looking at Speeduino vs tuning the EPROM chip (am aware there are readily available chips) but it's just fun to get started and learn, not so much about the cost but more on enjoying the process.

                              Speeduino seems the be the easiest way to get started, looking at the schematics done by Amila, I wonder if sk8 can share what are the things that will not work with this Speeduino? If i'm not mistaken, speeduino does not has CEL, am I right? so does that mean your Check Engine Light is always turned on? I believe the diagnostics and econometer will not work as well? Am hoping if you can confirm this and appreciate if you could share what other things that will not work with Speeduino.

                              Are there also any notable benefits of going wasted spark vs using the stock distributor?

                              Lastly, I am actually planning on making a M20b30 (starting with a block from M20b25 from a e34), with the increased stroke, are the base tunes for M20 engines the same across the different displacements?

                              Sorry if my questions sounds silly or have been asked before, but I have read as much as I could.

                              Thanks! :)

                              Yes CEL will not work with the speeduino. If you are planning to mess around with tuning, but not planning to turbo the car I can't really recommend and aftermarket ECU. You can get an eprom burner and a few chips and tune that way. With chip tuning I don't think you can adjust fueling, so you will mostly be tuning the timing tables.

                              The benefits of a speeduino on an na engine, is getting rid of the afm so that may make the car a little more responsive. You can also adjust fueling, timing, burble tune, etc.. a lot easier. With a chip you have to take it out, flash, put it back in. You can also setup launch control with the speeduino and no lift shift.

                              If you go with the speeduino it won't be as fast or easy to get everything setup. Also I would recommend buying a timing light. The typical setting people use for trigger angle using a megasquirt is different from speeduino. When I tried to verify my timing with a timing light, tdc was at 50 deg.

                              I don't really have enough knowledge to answer your other questions.

                              Comment

                              Working...
                              X