Any suggestions on which resistor values I should keep in stock?
I currently have 100-700ohm in about 100ohm increments - I keep needing smaller ones though (based on calculations). I'll be working with the Arduino's 5v supply, and mostly small components like LEDs and the like. I notice pull-down resistors should be like 10000ohm - I calculated a single LED at 33ohm, can't buy 1000 kinds in 10 ohm increments!
Thanks, and also first post!
I'd suggest standard resistor values in decades: 1 ohm, 2.2 ohms, 3.3 ohms, 4.7 ohms, 5.6 ohms, 6.8 ohms, 8.2 ohms. Then multiply by 10: 10 ohms, 22 ohms, 33 ohms, etc. Keep going until you reach 1 megaohm.
Even if you don't have the exact resistor you want you can probably cook it up by placing two resistors in series or parallel.
You could just buy the motherlode as a single item (if you have the $$$):
But you could probably get a subset of that yourself for cheaper :)
The Rugged Motor Driver: two H-bridges, more power than an L298, fully protected
Generally using the internal pullup:
digitalWrite (pinX, HIGH); // enables the internal pullup
and them using a switch contact to ground is sufficient.
Same for unused unused inputs, use internal pullup to keep them in a known state.
Single LED with 33 ohm, assuming 20mA current flow:
V/I = R
(5-Vf)/0.02 = 33
5 - Vf = 33*.02
5 = Vf + 0.66
5 - 0.66 = Vf
Vf = 4.34, or maybe a little less if you say Vlo-output is 0.3, then start with 4.7V instead of 5V.
Assuming 20mA current draw, what kind of LED are you using with Vforward = 4.34V ? Seems kinda high. Usually see 3.2 to 3.6 for white, blue.
In the past I have sold a resistor kit which had values and quantities I consider the most useful:
Sorry about the resistor usage comments in Portuguese. If there's interest I'll translate them later.
I bought some of these packs and have found them to be good value and very useful to have on hand
100 (bright LEDs), 1K (normal LEDs, transistor base resistors), 10K (pullups), 100K (555 timer longish delays.)
By all means get one of the "kits" that has lots of values, but the above are the ones I end up using most often.