Look over my schematic?
DH
Posts: 1
I'm a little new to electronics in general, and was wondering if someone could look over my schematic and make sure it's sound.
The project is for a binary calculator (I've got the code roughed out, and will maybe post that later). Basically you flip switches 8-11 for the first number, and switches 12-15 for the second number. The BS2 calculates the addition, and then outputs to the LEDs on pins 0-4.
And if it's not too much to ask, could you also tell me about what type of resistors I'll need, assuming the LEDs are around 2VDC max?
Critique away, just don't be too mean.
The project is for a binary calculator (I've got the code roughed out, and will maybe post that later). Basically you flip switches 8-11 for the first number, and switches 12-15 for the second number. The BS2 calculates the addition, and then outputs to the LEDs on pins 0-4.
And if it's not too much to ask, could you also tell me about what type of resistors I'll need, assuming the LEDs are around 2VDC max?
Critique away, just don't be too mean.
Comments
I've attached a "proper" circuit for your goal; it uses 220-ohm series resistors for protection from programming errors.· Pros don't normally use those but you should until you're really good at writing code.· You'll also see that the input pins must be pulled to a known state; in this case the pins are pulled low (0) and when a switch is closed you'll get a 1 on that pin.· Finally, you should never use just one resistor with multiple LEDs; use one per LED and for the number of LEDs that can be lit, 1K is a safe value.
It will take you longer to wire the circuit and write the code -- the truth is you can read the switches and output the result with just one line of code (if you've connected everything properly).
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
One to calculate, and one to loop....
Saves him from having to reset the BS2 for every calculation.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Don't visit my new website...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
*Slaps myself with the manual*
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Don't visit my new website...