- Fri Jan 01, 2021 8:01 pm
#47408
This topic I start to document everything, or at least most of, what I did, am doing and will do to get my engine running, car driving and later turbo charged. I am only a hobbyist with some tinkering experience, no electronics experience and no EFI knowledge... Here we go.
I started this project in May 2018, buying a 1998 MX5 NB with an old worn out 1.6 engine. The car sat at a second hand car dealer specialising in recent small convertibles and this car stood out as an eye-soar between newer MX5s, MR2s and BMW Z3s and such. I got a great deal on the car. I also bought a 1.8 VVT engine from a 2004 NB a few months later. Then we moved house (which was planned), life changed in many ways and I drove the car but didn’t get ‘round to tinkering on it. I gathered some parts like an exhaust manyfold for the turbo, the GT2554S turbo itself and I started work on a DIY stainless 3” down-pipe. The new house did came with a large (for my standards) garage, but only in august 2020 I finally swapped the engine. The harness was a nightmare but mid-October I got the engine to start and made some attempts to drive. I am only now, end December 2020 and early January 2021, getting to the point of tuning the car and starting to understand what that means. But before I get deeper into that, let me tell you what I did to get it running on Speeduino. I bought a 0.4.4 board all soldered together, 'ready to go'. I won’t tell you all failed attempts, but I will tell you what works for me. No guarantees it will work for you…
First off, before the engine swap, I found the ECU of this engine requires a TE Connectivity connector, their part number 353830-5, here’s a link:
https://www.te.com/usa-en/product-353830-5.html
This is not available everywhere but if you search you can find them. Next I made a PCB connecting all connector pins to the Speeduino:
I am actually on version 3 of that PCB, now, which is fully functional. It does not include the extra features to drive a wideband controller, so I wired that up separately. Besides that, the original wiring does not include a boost control solenoid and the original Mazda ECU controls the field of the alternator, so its output voltage. All issues to be solved.
The alternator issue is the easiest. Just buy a controller, I bought this one:
https://westfieldmx5.wordpress.com/alternator-pcb/
I wired it in between the ECU connector and the big blue connector that connects the engine loom to the car loom (under the dash, close to the centre console, on the driver’s side). It’s pretty straight forward. The controller comes with 5 connections:
1) 12V. I spliced a white/red switched power wire to connect this.
2) Ground. I spliced the black-blue ground wire to connect this.
3) Field. This is the grey-red wire going to pin 3M of the ECU connector. I disconnected it from the connector and connected it to the controller.
4) Disable. You could wire this in with the crank signal from the ignition switch, but I left it open.
5) LowBatt. This will light the dash light when the battery is not charging. It connects to the brown/red wire of pin 3U of the connector. I disconnected that from the connector and connected it to the controller.
And done. The thing works, I adjusted it to about 14V and all is well.
The boost solenoid is not an issue that really needs solving now, but I did so anyway as I will need it in the future. When you implement the Speeduino, you don’t need the MAF sensor anymore. So you don’t need it’s wiring anymore, either. This connector houses three wires, black/blue for ground, whte/red a switched power and a pink wire. This pink wire I will use to send PWM signals to the boost solenoid. It reaches the connector on pin 4X. The PCB I made connects it to Speeduino pin 35, the boost control pin. I’ve not done anything more, here, yet, but it is prepared.
Wiring in the wide band O2 sensor controller and signal is done also by using existing wiring, like the boost control. The engine comes with EGR (exhaust gas recirculation) which I don’t use with Speeduino, as it doesn’t have a feature to control it. The EGR connector on the engine comes with 6 wires and the normal O2 sensor connector also comes with 3 wires. I used some of these wires to wire in the system I bought, a 14point7 Spartan2:
https://www.14point7.com/products/spar ... ntroller-2
This has 6 wires to connect. Here’s how I wired it up:
1) Green, the linear output. I used the blue shielded wire of the O2 connector to connect the signal from the controller to the ECU connector. This goes to connector pin 4W of the connector. The PCB connects that to the O2 pin of the Speeduino, pin 21.
2) Black, electronics ground. This I wired using the white/green wire of the EGR connector to pin 2F of the connector. The PCB is not prepared for anything more so I soldered a wire from pin 2F to ground on top of the PCB.
3) White, heater ground. This I wired with a new wire to the bolt holding in the cam sensor on the valve cover.
4) Brown, the simulated narrowband output. I didn’t connect this, I don’t use it.
5) Blue or orange, a wire to drive an LED. I used the pink wire of the EGR connector to get that signal from the controller to pin 2I of the connector. The PCB is not prepared for anything so I soldered a wire from pin 2I to the LED, and a ground wire from the LED to a ground point on the PCB.
6) Red, the power wire. This is a bit of a strange one. Some people just use the switched ground (white/red), for instance of the EGR connector. Some switch it with the fuel pump solenoid. I chose to wire it in more complicated, but more controlled. I mounted a solenoid next to the controller, receiving power from the white/red wires. One wire to the input of the solenoid, one to the coil. The output of the solenoid goes to the controller, the red wire. But now we need to ground the other side of the coil. For this I used the pink/black wire from the EGR connector to pin 2H of the connector. The PCB is not prepared for anything so I soldered a wire from 2H to Speeduino pin 36, which is normally used for a second idle control. The engine only has a two wire ICV (power and signal), so Speeduino pin 36 is not used. But Speeduino pin 36 is powered by Arduino Mega pin 6. And the Speeduino firmware keeps it dormant if not used, but does not allow us to use it for anything else. So I soldered a wire from Arduino Mega pin 23 to Arduino pin 6, as I can use Arduino pin 23 is not used by the firmware. This now allows me to define an additional output in TunerStudio, to control the wideband O2 controller. Here is what I have:
The rule is pretty simple; when the RPM goes over 500, a counter starts. When it reaches 20 seconds, it turns on the WB controller. Actually, it activates Arduino Mega pin 23, which is wired to Arduino Mega pin 6, which drives the MOSFET that could be used to PWM-ground a second signal wire on a 3-wire ICV, but in this case it grounds the solenoid which then powers the 14point7 Spartan2 controller. Done. Easy… I might add some pics, later.
With all the wiring done, I 3D printed a mount for the PCBs and one for the connector. I bought an aluminium housing on e-bay and mounted it all. This is a pic with the previous PCB version, which didn’t house the diodes properly, yet:
In this picture you can also see the addition MOSFET I used before someone recommended me to use the MOSFET for Idle2.
Next I installed firmware 202012 via Speedyloader and set up a project in TunerStudio with that same firmware, all like the Speeduino manual says. I downloaded a base tune called “NB8B PNP base tune” and loaded it in TunerStudio. Next I went through a lot of screens, adjusting settings and setting sensors, values, etc. The car now runs and drives, but with a lot of issues. The most important ones now:
- I have a weird spark table, which I believe came with the base tune, but it needs to be changed. I was recommended this site:
http://www.useasydocs.com/theory/spkta ... mCWZgx0twE
To generate a new one, and I will go from there… I also collected some reference tunes, but there is a lot of difference between references I found and some are plain wrong, but still work reasonably for their creator / user.
- The VVT control I have turned off at the moment. I need to tune it’s PID controls, but it is a nightmare. Reference tunes I was given / I found don’t make sense and don’t work.
- The car starts really bad, especially when cold. I am looking into the settings with help from the Facebook group.
- The closed loop idle is hunting like mad, so I set it to open loop for now. But I need to change this, as Idle is very high now. When I turn on the headlights, the interior heater fan and the coolant fan kicks in, the idle it just about 850 rpm. But without those users, idle is too high now.
- The car hesitates / leans out big time when I touch the throttle. It immdeiately corrects, it is as if the ECU is slow in responding. It is only in the first tenth of a second when starting to accellerate. Driveable but annoying.
So, that is where I am now. I will add some pictures soon as I was already asked for that on the facebook group. Tomorrow I hope to load a new spark table and re-start VE tuning.
Hugo
I started this project in May 2018, buying a 1998 MX5 NB with an old worn out 1.6 engine. The car sat at a second hand car dealer specialising in recent small convertibles and this car stood out as an eye-soar between newer MX5s, MR2s and BMW Z3s and such. I got a great deal on the car. I also bought a 1.8 VVT engine from a 2004 NB a few months later. Then we moved house (which was planned), life changed in many ways and I drove the car but didn’t get ‘round to tinkering on it. I gathered some parts like an exhaust manyfold for the turbo, the GT2554S turbo itself and I started work on a DIY stainless 3” down-pipe. The new house did came with a large (for my standards) garage, but only in august 2020 I finally swapped the engine. The harness was a nightmare but mid-October I got the engine to start and made some attempts to drive. I am only now, end December 2020 and early January 2021, getting to the point of tuning the car and starting to understand what that means. But before I get deeper into that, let me tell you what I did to get it running on Speeduino. I bought a 0.4.4 board all soldered together, 'ready to go'. I won’t tell you all failed attempts, but I will tell you what works for me. No guarantees it will work for you…
First off, before the engine swap, I found the ECU of this engine requires a TE Connectivity connector, their part number 353830-5, here’s a link:
https://www.te.com/usa-en/product-353830-5.html
This is not available everywhere but if you search you can find them. Next I made a PCB connecting all connector pins to the Speeduino:
I am actually on version 3 of that PCB, now, which is fully functional. It does not include the extra features to drive a wideband controller, so I wired that up separately. Besides that, the original wiring does not include a boost control solenoid and the original Mazda ECU controls the field of the alternator, so its output voltage. All issues to be solved.
The alternator issue is the easiest. Just buy a controller, I bought this one:
https://westfieldmx5.wordpress.com/alternator-pcb/
I wired it in between the ECU connector and the big blue connector that connects the engine loom to the car loom (under the dash, close to the centre console, on the driver’s side). It’s pretty straight forward. The controller comes with 5 connections:
1) 12V. I spliced a white/red switched power wire to connect this.
2) Ground. I spliced the black-blue ground wire to connect this.
3) Field. This is the grey-red wire going to pin 3M of the ECU connector. I disconnected it from the connector and connected it to the controller.
4) Disable. You could wire this in with the crank signal from the ignition switch, but I left it open.
5) LowBatt. This will light the dash light when the battery is not charging. It connects to the brown/red wire of pin 3U of the connector. I disconnected that from the connector and connected it to the controller.
And done. The thing works, I adjusted it to about 14V and all is well.
The boost solenoid is not an issue that really needs solving now, but I did so anyway as I will need it in the future. When you implement the Speeduino, you don’t need the MAF sensor anymore. So you don’t need it’s wiring anymore, either. This connector houses three wires, black/blue for ground, whte/red a switched power and a pink wire. This pink wire I will use to send PWM signals to the boost solenoid. It reaches the connector on pin 4X. The PCB I made connects it to Speeduino pin 35, the boost control pin. I’ve not done anything more, here, yet, but it is prepared.
Wiring in the wide band O2 sensor controller and signal is done also by using existing wiring, like the boost control. The engine comes with EGR (exhaust gas recirculation) which I don’t use with Speeduino, as it doesn’t have a feature to control it. The EGR connector on the engine comes with 6 wires and the normal O2 sensor connector also comes with 3 wires. I used some of these wires to wire in the system I bought, a 14point7 Spartan2:
https://www.14point7.com/products/spar ... ntroller-2
This has 6 wires to connect. Here’s how I wired it up:
1) Green, the linear output. I used the blue shielded wire of the O2 connector to connect the signal from the controller to the ECU connector. This goes to connector pin 4W of the connector. The PCB connects that to the O2 pin of the Speeduino, pin 21.
2) Black, electronics ground. This I wired using the white/green wire of the EGR connector to pin 2F of the connector. The PCB is not prepared for anything more so I soldered a wire from pin 2F to ground on top of the PCB.
3) White, heater ground. This I wired with a new wire to the bolt holding in the cam sensor on the valve cover.
4) Brown, the simulated narrowband output. I didn’t connect this, I don’t use it.
5) Blue or orange, a wire to drive an LED. I used the pink wire of the EGR connector to get that signal from the controller to pin 2I of the connector. The PCB is not prepared for anything so I soldered a wire from pin 2I to the LED, and a ground wire from the LED to a ground point on the PCB.
6) Red, the power wire. This is a bit of a strange one. Some people just use the switched ground (white/red), for instance of the EGR connector. Some switch it with the fuel pump solenoid. I chose to wire it in more complicated, but more controlled. I mounted a solenoid next to the controller, receiving power from the white/red wires. One wire to the input of the solenoid, one to the coil. The output of the solenoid goes to the controller, the red wire. But now we need to ground the other side of the coil. For this I used the pink/black wire from the EGR connector to pin 2H of the connector. The PCB is not prepared for anything so I soldered a wire from 2H to Speeduino pin 36, which is normally used for a second idle control. The engine only has a two wire ICV (power and signal), so Speeduino pin 36 is not used. But Speeduino pin 36 is powered by Arduino Mega pin 6. And the Speeduino firmware keeps it dormant if not used, but does not allow us to use it for anything else. So I soldered a wire from Arduino Mega pin 23 to Arduino pin 6, as I can use Arduino pin 23 is not used by the firmware. This now allows me to define an additional output in TunerStudio, to control the wideband O2 controller. Here is what I have:
The rule is pretty simple; when the RPM goes over 500, a counter starts. When it reaches 20 seconds, it turns on the WB controller. Actually, it activates Arduino Mega pin 23, which is wired to Arduino Mega pin 6, which drives the MOSFET that could be used to PWM-ground a second signal wire on a 3-wire ICV, but in this case it grounds the solenoid which then powers the 14point7 Spartan2 controller. Done. Easy… I might add some pics, later.
With all the wiring done, I 3D printed a mount for the PCBs and one for the connector. I bought an aluminium housing on e-bay and mounted it all. This is a pic with the previous PCB version, which didn’t house the diodes properly, yet:
In this picture you can also see the addition MOSFET I used before someone recommended me to use the MOSFET for Idle2.
Next I installed firmware 202012 via Speedyloader and set up a project in TunerStudio with that same firmware, all like the Speeduino manual says. I downloaded a base tune called “NB8B PNP base tune” and loaded it in TunerStudio. Next I went through a lot of screens, adjusting settings and setting sensors, values, etc. The car now runs and drives, but with a lot of issues. The most important ones now:
- I have a weird spark table, which I believe came with the base tune, but it needs to be changed. I was recommended this site:
http://www.useasydocs.com/theory/spkta ... mCWZgx0twE
To generate a new one, and I will go from there… I also collected some reference tunes, but there is a lot of difference between references I found and some are plain wrong, but still work reasonably for their creator / user.
- The VVT control I have turned off at the moment. I need to tune it’s PID controls, but it is a nightmare. Reference tunes I was given / I found don’t make sense and don’t work.
- The car starts really bad, especially when cold. I am looking into the settings with help from the Facebook group.
- The closed loop idle is hunting like mad, so I set it to open loop for now. But I need to change this, as Idle is very high now. When I turn on the headlights, the interior heater fan and the coolant fan kicks in, the idle it just about 850 rpm. But without those users, idle is too high now.
- The car hesitates / leans out big time when I touch the throttle. It immdeiately corrects, it is as if the ECU is slow in responding. It is only in the first tenth of a second when starting to accellerate. Driveable but annoying.
So, that is where I am now. I will add some pictures soon as I was already asked for that on the facebook group. Tomorrow I hope to load a new spark table and re-start VE tuning.
Hugo
Last edited by HugoW on Sun Jan 10, 2021 2:14 pm, edited 6 times in total.