Resistors and Colors

[Total: 0    Average: 0/5]

This example shows resistors with the proper color coding.

Body Code:

<script>
<!-- 

function namen(color1,color2,color3) {

    this.color1=color1
    this.color2=color2
    this.color3=color3
    
  }

  function makeArray(n) {
    this.length=n;
    return this;
  }

  lijst=new makeArray(84)
  
  lijst[1] = new namen("brown","black","gold");
  lijst[2] = new namen("brown","red","gold");
  lijst[3] = new namen("brown","green","gold");
  lijst[4] = new namen("brown","gray","gold");
  lijst[5] = new namen("red","red","gold");
  lijst[6] = new namen("red","violet","gold");
  lijst[7] = new namen("orange","orange","gold");
  lijst[8] = new namen("orange","white","gold");
  lijst[9] = new namen("yellow","violet","gold");
  lijst[10] = new namen("green","blue","gold");
  lijst[11] = new namen("blue","gray","gold");
  lijst[12] = new namen("gray","red","gold");

  lijst[13] = new namen("brown","black","black");
  lijst[14] = new namen("brown","red","black");
  lijst[15] = new namen("brown","green","black");
  lijst[16] = new namen("brown","gray","black");
  lijst[17] = new namen("red","red","black");
  lijst[18] = new namen("red","violet","black");
  lijst[19] = new namen("orange","orange","black");
  lijst[20] = new namen("orange","white","black");
  lijst[21] = new namen("yellow","violet","black");
  lijst[22] = new namen("green","blue","black");
  lijst[23] = new namen("blue","gray","black");
  lijst[24] = new namen("gray","red","black");

  lijst[25] = new namen("brown","black","brown");
  lijst[26] = new namen("brown","red","brown");
  lijst[27] = new namen("brown","green","brown");
  lijst[28] = new namen("brown","gray","brown");
  lijst[29] = new namen("red","red","brown");
  lijst[30] = new namen("red","violet","brown");
  lijst[31] = new namen("orange","orange","brown");
  lijst[32] = new namen("orange","white","brown");
  lijst[33] = new namen("yellow","violet","brown");
  lijst[34] = new namen("green","blue","brown");
  lijst[35] = new namen("blue","gray","brown");
  lijst[36] = new namen("gray","red","brown");

  lijst[37] = new namen("brown","black","red");
  lijst[38] = new namen("brown","red","red");
  lijst[39] = new namen("brown","green","red");
  lijst[40] = new namen("brown","gray","red");
  lijst[41] = new namen("red","red","red");
  lijst[42] = new namen("red","violet","red");
  lijst[43] = new namen("orange","orange","red");
  lijst[44] = new namen("orange","white","red");
  lijst[45] = new namen("yellow","violet","red");
  lijst[46] = new namen("green","blue","red");
  lijst[47] = new namen("blue","gray","red");
  lijst[48] = new namen("gray","red","red");

  lijst[49] = new namen("brown","black","orange");
  lijst[50] = new namen("brown","red","orange");
  lijst[51] = new namen("brown","green","orange");
  lijst[52] = new namen("brown","gray","orange");
  lijst[53] = new namen("red","red","orange");
  lijst[54] = new namen("red","violet","orange");
  lijst[55] = new namen("orange","orange","orange");
  lijst[56] = new namen("orange","white","orange");
  lijst[57] = new namen("yellow","violet","orange");
  lijst[58] = new namen("green","blue","orange");
  lijst[59] = new namen("blue","gray","orange");
  lijst[60] = new namen("gray","red","orange");

  lijst[61] = new namen("brown","black","yellow");
  lijst[62] = new namen("brown","red","yellow");
  lijst[63] = new namen("brown","green","yellow");
  lijst[64] = new namen("brown","gray","yellow");
  lijst[65] = new namen("red","red","yellow");
  lijst[66] = new namen("red","violet","yellow");
  lijst[67] = new namen("orange","orange","yellow");
  lijst[68] = new namen("orange","white","yellow");
  lijst[69] = new namen("yellow","violet","yellow");
  lijst[70] = new namen("green","blue","yellow");
  lijst[71] = new namen("blue","gray","yellow");
  lijst[72] = new namen("gray","red","yellow");

  lijst[73] = new namen("brown","black","green");
  lijst[74] = new namen("brown","red","green");
  lijst[75] = new namen("brown","green","green");
  lijst[76] = new namen("brown","gray","green");
  lijst[77] = new namen("red","red","green");
  lijst[78] = new namen("red","violet","green");
  lijst[79] = new namen("orange","orange","green");
  lijst[80] = new namen("orange","white","green");
  lijst[81] = new namen("yellow","violet","green");
  lijst[82] = new namen("green","blue","green");
  lijst[83] = new namen("blue","gray","green");
  lijst[84] = new namen("gray","red","green");


var _ptimgs = "/data/ex_819/";
function start() {

   var i =  document.formulier.selbox.selectedIndex+1;
   
   document.kleur1.src = _ptimgs + lijst[i].color1 + ".gif"
   document.kleur2.src = _ptimgs + lijst[i].color2 + ".gif"
   document.kleur3.src = _ptimgs + lijst[i].color3 + ".gif"

   document.formulier.c1.value = " " + lijst[i].color1;
   document.formulier.c2.value = " " + lijst[i].color2;
   document.formulier.c3.value = " " + lijst[i].color3;
   }



//-->
</script>

Resistor Code E-12
<IMG SRC="/data/ex_819/left.gif"><IMG SRC="/data/ex_819/brown.gif" name="kleur1"><IMG SRC="/data/ex_819/small.gif"><IMG SRC="/data/ex_819/black.gif"  name="kleur2"><IMG SRC="/data/ex_819/small.gif"><IMG SRC="/data/ex_819/gold.gif" name="kleur3"><IMG SRC="/data/ex_819/big.gif"><IMG SRC="/data/ex_819/right.gif">

<FORM name="formulier">

<SELECT NAME="selbox" size=1 onchange="start()">

<OPTION>1 Ohm
<OPTION>1.2 Ohm
<OPTION>1.5 Ohm
<OPTION>1.8 Ohm
<OPTION>2.2 Ohm
<OPTION>2.7 Ohm
<OPTION>3.3 Ohm
<OPTION>3.9 Ohm
<OPTION>4.7 Ohm
<OPTION>5.6 Ohm
<OPTION>6.8 Ohm
<OPTION>8.2 Ohm

<OPTION>10 Ohm
<OPTION>12 Ohm
<OPTION>15 Ohm
<OPTION>18 Ohm
<OPTION>22 Ohm
<OPTION>27 Ohm
<OPTION>33 Ohm
<OPTION>39 Ohm
<OPTION>47 Ohm
<OPTION>56 Ohm
<OPTION>68 Ohm
<OPTION>82 Ohm

<OPTION>100 Ohm
<OPTION>120 Ohm
<OPTION>150 Ohm
<OPTION>180 Ohm
<OPTION>220 Ohm
<OPTION>270 Ohm
<OPTION>330 Ohm
<OPTION>390 Ohm
<OPTION>470 Ohm
<OPTION>560 Ohm
<OPTION>680 Ohm
<OPTION>820 Ohm
  
<OPTION>1 Kilo-Ohm
<OPTION>1.2 Kilo-Ohm
<OPTION>1.5 Kilo-Ohm
<OPTION>1.8 Kilo-Ohm
<OPTION>2.2 Kilo-Ohm
<OPTION>2.7 Kilo-Ohm
<OPTION>3.3 Kilo-Ohm
<OPTION>3.9 Kilo-Ohm
<OPTION>4.7 Kilo-Ohm
<OPTION>5.6 Kilo-Ohm
<OPTION>6.8 Kilo-Ohm
<OPTION>8.2 Kilo-Ohm

<OPTION>10 Kilo-Ohm
<OPTION>12 Kilo-Ohm
<OPTION>15 Kilo-Ohm
<OPTION>18 Kilo-Ohm
<OPTION>22 Kilo-Ohm
<OPTION>27 Kilo-Ohm
<OPTION>33 Kilo-Ohm
<OPTION>39 Kilo-Ohm
<OPTION>47 Kilo-Ohm
<OPTION>56 Kilo-Ohm
<OPTION>68 Kilo-Ohm
<OPTION>82 Kilo-Ohm

<OPTION>100 Kilo-Ohm
<OPTION>120 Kilo-Ohm
<OPTION>150 Kilo-Ohm
<OPTION>180 Kilo-Ohm
<OPTION>220 Kilo-Ohm
<OPTION>270 Kilo-Ohm
<OPTION>330 Kilo-Ohm
<OPTION>390 Kilo-Ohm
<OPTION>470 Kilo-Ohm
<OPTION>560 Kilo-Ohm
<OPTION>680 Kilo-Ohm
<OPTION>820 Kilo-Ohm

<OPTION>1 Mega-Ohm
<OPTION>1.2 Mega-Ohm
<OPTION>1.5 Mega-Ohm
<OPTION>1.8 Mega-Ohm
<OPTION>2.2 Mega-Ohm
<OPTION>2.7 Mega-Ohm
<OPTION>3.3 Mega-Ohm
<OPTION>3.9 Mega-Ohm
<OPTION>4.7 Mega-Ohm
<OPTION>5.6 Mega-Ohm
<OPTION>6.8 Mega-Ohm
<OPTION>8.2 Mega-Ohm

</SELECT>

<P>

<input TYPE="text" NAME="c1" SIZE="10" value=" brown">
<input TYPE="text" NAME="c2" SIZE="10" value=" black">
<input TYPE="text" NAME="c3" SIZE="10" value=" gold">
</FORM>

</center>
<P>

Times Viewed: 2

Leave a Reply

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