user34371: With my team we constructed a circuit using Arduino. The circuit works on the Proteus simulator. It worked fine with LEDs connected directly to Arduino outputs.
However, when I used Arduino output to trigger a BC 337 transistor to try and actuate a 12 V DC coiled relay, it wouldn't trigger. I measured voltage across transistor collector and emitter, it reads 12 V, just like the source I gave... (The transistor is not switched on I guess).
Supply for the Arduino is a constant 5 V DC.
Where have I gone wrong? Picture as uploaded.

Furthermore, we are trying to build a controller for an ice making machine. The power circuit (12 V) is to be controlled by Arduino through the transistors.
I am uploading the codes we used and the full circuit diagram.
const int start = 13;
const int comp= 2;
const int cond=3;
const int hGas=4;
const int wbut=12;
const int watersol=5;
const int dumper=6;
const int iced=11;

int startButton=0;
int waterButton=0;
int dumperlimswitch=0;

void setup() {

  pinMode(start, INPUT);    
  pinMode(comp, OUTPUT);    
  pinMode(cond, OUTPUT);    
  pinMode(hGas, OUTPUT);    
  pinMode(wbut,INPUT);    
  pinMode(watersol, OUTPUT);    
  pinMode(dumper, OUTPUT);    
  pinMode(iced, INPUT);
}

void loop() {

startButton = digitalRead(start);
waterButton = digitalRead(wbut);

 if (startButton == HIGH) {

    digitalWrite(comp, HIGH);
    digitalWrite(cond, HIGH);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
     delay(800);
    digitalWrite(hGas,HIGH);
    digitalWrite(cond, LOW);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
    delay(500);
    digitalWrite(hGas, LOW);
    digitalWrite(dumper, HIGH);
    digitalWrite(cond, HIGH);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
    delay(800);
    digitalWrite(dumper, LOW);
  } 
else {
    digitalWrite(comp, LOW);
    digitalWrite(cond, LOW);
  }
}


user10394: This is not an answer but its too big to be a comment.  I can't solve your problem, but hopefully I can point you in the right direction.
I think the first problem you have is you have talked this problem in one chunk.  I think even some of the more experienced users would have a problem hitting this in one go.  You need to break it down into simple units (Functional decomposition if you want to be posh).
The problem you are asking about is why your transistor doesn't work.  You have used an LED and you think the correct signals are being sent.  
So Phase one, take the transistor and test it in isolation, then you know its working.  Secondly does it still work when the Uno is controlling it rather than just a battery?
Does the object you are powering via the transistor work on its own?
Does it work when you add it to the uno and transistor?
You get the idea.  To be honest I suspect it might be an issue with lack of power.

user4143: TL/DR: Your LEDs without resistors are diverting all the current away from the transistors so they are unable to switch.
In detail:
Let's take a quick look at just one small portion of your circuit in more detail:

simulate this circuit – Schematic created using CircuitLab
I have added an extra resistor into the circuit - Rw - which represents the resistance of the wires and pins of the LED, and I have given it a nominal 0.1Ω value. 
Now, let's say you set the GPIO HIGH, so it outputs 5V. The LED, D1, is a typical red LED with a forward voltage of, say, 2V.  Let's calculate the current through the LED.

I = (VCC - VF)/R = (5 - 2) / 0.1 = 3 / 0.1 = 30A

30A?! But the GPIO can't provide more than 40mA absolute maximum. So all that can come from the GPIO is being sent straight through the LED leaving nothing (much) for the transistor.
Oh and yes, all that current demand is doing unspeakable damage to the Arduino's GPIO pin.
The transistor's Base-Emitter junction has about a 0.7V drop across it, and, if it weren't for the LED, with the 1kΩ resistor that gives (5-0.7)/1000 = 4.3mA. Which with a hFE of around 100, would give a collector current of around 430mA. And that should be fine for most small relays.
But with all the current being dumped through the LED what can get through to the transistor won't be enough to turn on the relay. 
So increasing the resistance of the wire to the LED will decrease the current demands of the LED. And of course you do that by adding a resistor. So let's make that 1kΩ - a decent enough value for a simple indicator LED:

simulate this circuit
Now let's do the calculation for the LED's current:

I = (VCC - VF) / R = (5 - 2) / 1000 = 3 / 1000 = 3mA

Add that to the 4.3mA that wants to go through the transistor, and we have 7.3mA in total.
Now that is way below what the Arduino's GPIO can provide, so the IO pin is happy, the LED is happy and, most importantly, the transistor is happy.

34371: <p>With my team we constructed a circuit using Arduino. The circuit works on the Proteus simulator. It worked fine with LEDs connected directly to Arduino outputs.</p>

<p>However, when I used Arduino output to trigger a BC 337 transistor to try and actuate a 12 V DC coiled relay, it wouldn't trigger. I measured voltage across transistor collector and emitter, it reads 12 V, just like the source I gave... (The transistor is not switched on I guess).</p>

<p>Supply for the Arduino is a constant 5 V DC.</p>

<p>Where have I gone wrong? Picture as uploaded.</p>

<p><a href="https://i.stack.imgur.com/4jP54.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4jP54.png" alt="Full circuit"></a></p>

<p>Furthermore, we are trying to build a controller for an ice making machine. The power circuit (12 V) is to be controlled by Arduino through the transistors.</p>

<p>I am uploading the codes we used and the full circuit diagram.</p>

<pre><code>const int start = 13;
const int comp= 2;
const int cond=3;
const int hGas=4;
const int wbut=12;
const int watersol=5;
const int dumper=6;
const int iced=11;

int startButton=0;
int waterButton=0;
int dumperlimswitch=0;

void setup() {

  pinMode(start, INPUT);    
  pinMode(comp, OUTPUT);    
  pinMode(cond, OUTPUT);    
  pinMode(hGas, OUTPUT);    
  pinMode(wbut,INPUT);    
  pinMode(watersol, OUTPUT);    
  pinMode(dumper, OUTPUT);    
  pinMode(iced, INPUT);
}

void loop() {

startButton = digitalRead(start);
waterButton = digitalRead(wbut);

 if (startButton == HIGH) {

    digitalWrite(comp, HIGH);
    digitalWrite(cond, HIGH);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
     delay(800);
    digitalWrite(hGas,HIGH);
    digitalWrite(cond, LOW);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
    delay(500);
    digitalWrite(hGas, LOW);
    digitalWrite(dumper, HIGH);
    digitalWrite(cond, HIGH);

    waterButton = digitalRead(wbut);
    if (waterButton == HIGH){
      digitalWrite(watersol,HIGH);
      }
    else{
      digitalWrite(watersol,LOW);
      }
    delay(800);
    digitalWrite(dumper, LOW);
  } 
else {
    digitalWrite(comp, LOW);
    digitalWrite(cond, LOW);
  }
}
</code></pre>
 10394: <p>This is not an answer but its too big to be a comment.  I can't solve your problem, but hopefully I can point you in the right direction.</p>

<p>I think the first problem you have is you have talked this problem in one chunk.  I think even some of the more experienced users would have a problem hitting this in one go.  You need to break it down into simple units (Functional decomposition if you want to be posh).</p>

<p>The problem you are asking about is why your transistor doesn't work.  You have used an LED and you think the correct signals are being sent.  </p>

<p>So Phase one, take the transistor and test it in isolation, then you know its working.  Secondly does it still work when the Uno is controlling it rather than just a battery?</p>

<p>Does the object you are powering via the transistor work on its own?
Does it work when you add it to the uno and transistor?</p>

<p>You get the idea.  To be honest I suspect it might be an issue with lack of power.</p>
 4143: <p><strong>TL/DR:</strong> Your LEDs without resistors are diverting all the current away from the transistors so they are unable to switch.</p>

<p><strong>In detail:</strong></p>

<p>Let's take a quick look at just one small portion of your circuit in more detail:</p>



<p><img src="https://i.stack.imgur.com/ZQGhK.png" alt="schematic"></p>



<p><sup><a href="/plugins/schematics?image=http%3a%2f%2fi.stack.imgur.com%2fZQGhK.png">simulate this circuit</a> &ndash; Schematic created using <a href="https://www.circuitlab.com/" rel="nofollow">CircuitLab</a></sup></p>

<p>I have added an extra resistor into the circuit - Rw - which represents the resistance of the wires and pins of the LED, and I have given it a nominal 0.1Ω value. </p>

<p>Now, let's say you set the GPIO HIGH, so it outputs 5V. The LED, D1, is a typical red LED with a forward voltage of, say, 2V.  Let's calculate the current through the LED.</p>

<ul>
<li>I = (V<sub>CC</sub> - V<sub>F</sub>)/R = (5 - 2) / 0.1 = 3 / 0.1 = 30A</li>
</ul>

<p>30A?! But the GPIO can't provide more than 40mA <em>absolute maximum</em>. So all that <em>can</em> come from the GPIO is being sent straight through the LED leaving nothing (much) for the transistor.</p>

<p>Oh and yes, all that current demand is doing unspeakable damage to the Arduino's GPIO pin.</p>

<p>The transistor's Base-Emitter junction has about a 0.7V drop across it, and, if it weren't for the LED, with the 1kΩ resistor that gives (5-0.7)/1000 = 4.3mA. Which with a h<sub>FE</sub> of around 100, would give a collector current of around 430mA. And that should be fine for most small relays.</p>

<p>But with all the current being dumped through the LED what can get through to the transistor won't be enough to turn on the relay. </p>

<p>So increasing the resistance of the wire to the LED will decrease the current demands of the LED. And of course you do that by adding a resistor. So let's make that 1kΩ - a decent enough value for a simple indicator LED:</p>



<p><img src="https://i.stack.imgur.com/eYeG4.png" alt="schematic"></p>



<p><sup><a href="/plugins/schematics?image=http%3a%2f%2fi.stack.imgur.com%2feYeG4.png">simulate this circuit</a></sup></p>

<p>Now let's do the calculation for the LED's current:</p>

<ul>
<li>I = (V<sub>CC</sub> - V<sub>F</sub>) / R = (5 - 2) / 1000 = 3 / 1000 = 3mA</li>
</ul>

<p>Add that to the 4.3mA that wants to go through the transistor, and we have 7.3mA in total.</p>

<p>Now that is way below what the Arduino's GPIO can provide, so the IO pin is happy, the LED is happy and, most importantly, the transistor is happy.</p>
