Posted on 21 Comments

ULNs, and pullups, and launch… Oh, my.

We get a lot of questions regarding the installation of a ULN chip (uln2803, or uln2003) in the proto area, clutch switch inputs, and tach pullup resistors for the Speeduino v0.4 boards. This should clear some of that up:

The stock v0.4 boards control signals for the proto output pins right from the MEGA2560. They aren’t suited for relay control as they sit, and need some extra oomph to handle grounding a relay coil. The ULN chips are a series of darlington pairs in one chip that streamlines installation of drivers for our proto outputs.

The basic proto layout is:

proto1- unassigned (pin 43)
proto2- Fan (pin 47)
proto3- Fuel pump (pin 45)
proto4- Tach (pin 49)
proto5- Clutch switch input (pin 51)

#1-3 are standard outputs from the Speedy, and will be handled through the ULN, #4 is the tach output and will typically need a 1K-10K pullup resistor between the output pin of the ULN and a 12v source to drive most tachs. Proto 5 is an input pin, and will not be routed through the ULN.

The first order of business is to clip 4 of the pins off of the uln chip itself. We don’t want to foul the A15 row, and don’t need uln control on the clutch input row. We also want to lift the 12v input leg of the ULN so that we can power it without fouling the ground plane of the proto area. The ground leg is left alone and will ground through the proto ground row.

The next step is to gently widen the footprint of the ULN to fully bridge the proto holes, and insert it into the proto area with the lower left pin (ground) in the ground row. Make sure the 12v leg is lifted and not touching anything.

With the ULN mounted go ahead and solder up most of the pins, but leave the pin49 row open so we can add the tach pullup later. The 12v leg of the ULN will need run to a 12v source, I prefer to route it though the hole by c24 and run it directly to the bottom of the 12v input terminal.

The clutch switch jumper just needs to be run from one side of the proto area to the other. This will tie the IDC40 pin, to the Mega2560 pin and allow the clutch switch to signal on/off.

The final part of ULN install is to add a pullup resistor for the tach output. The speeduino provides a grounding pulse as the output, and for most tachs we will need a pullup resistor (1K-10K, start with 10K) between the 12v rail and the tach output to create the proper signal. This is as simple as putting one leg of the resistor into the same proto area hole as the ULN tach output pin, and the other leg of the resistor to a 12v source. Since we brought 12v to the ULN, we already have a perfect spot to tie in.

 

With these all wired up, your speedy now has all of the available proto outputs, and clutch input wired up. Set up your fans, fuel pump, tach, and launch in software, and there you go.

 

21 thoughts on “ULNs, and pullups, and launch… Oh, my.

  1. Hello !, I’m interested in knowing how to connect a fuel pump and a cooling fan and make it work, can you explain how to make the connections and how to make them work? Thank you!.

    1. Hi Carlos!

      The fuel pump and cooling fan circuits require a relay. Without a relay, the Speeduino will burn bright like the sun, for a very short amount of time.

      Simply wire the trigger side of the relay to a fused source, and ground through the appropriate pin on the speeduino. In this case it would be the fuel pump pin/fan pin supplying ground to turn the relay on.

      Then hook a large gauge wire from 12v power to the COM or pin 30 on your automotive relay, then the load on pin 87a or 87 depending on how you want it to react.
      relay

      1. jajajaj ouuu yeaaaah,
        I need it for my end-of-course project, could you on an image of the speeduino circuit draw the connections of the fan and the 12v gasoline pump? are the pins 45 and 47 of the proto area I think I remember :), I’m a bit lost, I have no notions of electronics and I want to make a model that runs injectors, spark plugs and some sensors. Thank you!!

        1. jajajaj ouuu yeaaaah,
          I need it for my end-of-course project, could you on an image of the speeduino circuit draw the connections of the fan and the 12v gasoline pump? are the pins 45 and 47 of the proto area I think I remember :), The fan is going to be a small one computer and the fuel pump 12v and 1.5 amps maximum a bit lost, I have no notions of electronics and I want to make a model that runs injectors, spark plugs and some sensors. Thank you!!

          1. Go back and reread the ULN post you are commenting on, with the knowledge gained there, and a google search of how to wire a relay, all the secrets will be revealed. You appear to be looking for someone to do your homework for you, and that isn’t what we do here…

        2. Arduino is only 40mAh per pin. A relay draws about 200mAh. You will need a transistor to pull the relay. Or a solid state relay.

          1. You could also use something like an 2n2222 to drive the relay.

          2. Yes, absolutely! This application was designed to use the ULN, but you could use a 2n2222 or a tip120, or any transistor/FET of your choice.

          3. ULN drivers have flyback diodes, and series base resistors.
            If you are using discrete NPN like 2N222, you need to use a good, fast rectifier like 1N4001 so that the inductive flyback from the relay coil doesn’t fry your transistor.
            Strictly speaking, you should also use a resistor in series with the transistor base too.

  2. Thanks for the excellent guide

  3. Hi,
    I have no notions of eletronics and I have a doubt about the pullup resistor for the tach output: how many watts and the tolerance??? Ex: 10k Ohm 1/4w 1%, is the resistor mentioned in this article?

    1. Tolerance doesn’t matter. 10% resistor would be fine, you could get away with anything from about 5k to 10k, as long as it’s bigger than 1/8th watt.

      Are people still building v4’s?
      The fishdogs all have the pull up built in.

      1. Thanks for your attention!!!

  4. We have a 4 cylinder engine we want to run the injector sequential can you tell us which 4 injector pin to use, on our Speeduino 0.4.3c board we have 2 injector Ground in our Harness but on the Speeduino Board we do not see we where to connect can you send us a diagram showing where.

    1. Depending on the car, you will likely have to add wiring in order to run full sequential. I left my crystal ball at home so I cannot see what car you are trying to wire.

      1. Thanks for your comments. We have a Honda K20A we have a Vtec so we would like you to label Proto area pin we already know about the wiring is just the labeling of the proto Area Pin we also so notice there us no Vtec connection so can you help us to connect the Vtec to the Speeduino.

        Nadalyn Mcneil
        SMA

        1. Wire the injectors inj1 to injector 1, inj2 to injector 3, inj3 to injector 4 and inj4 to injector 2.

          The drivers fire in order, 1234, but the engine needs them in the firing order to get fuel at the appropriate intake valve, and then you’ll need to play with Injector Timing to get full advantage of the sequential injection.

          As for vtec, wire it to the ULN, and set it to the appropriate pin via the ULN as a driver, and use the VVT output in tunerstudio in on/off mode.

          We stopped selling the v4 speeduino boards because of the customer support requirements and people asking us to hold their hand through wiring their car. Which is why we designed and built the Fishdog boards. On the fishdog, you would simply just wire it to the VVT wire.

  5. for speeduino 0.4.4B broad how do i connect uln2086?

    1. We don’t carry the 0.4.4B, its all surface mount. If you cant figure it out from diagrams, contact whoever you bought it from.

  6. Hi, I have done everything like the guide says. Question – what will happen to the output when fuel pump will be engaged – it will get 12v or will be grounded? Im making it for subaru and as I remeber fuel pump relay will work when grounded.

    1. Yes, our ecu’s fuel pump output is a ground.
      Hook your fuel relay to it, and the ecu will apply ground to turn it on.

Leave a Reply

Your email address will not be published. Required fields are marked *