I am a software person, so sometimes my hardware knowledge is scattering bits of knowledge linked together with wild guesses. So, I wanted to make sure I understood how to power the spark. I tried looking at the wiki, and it only had basic information.
The Spark has 3 potential sources of power:
- The USB tab providing regulated 5v input;
- The 5v pin on the left side;
- The VIN pin on the left side.
Now, I assume the 5v and the USB tab are logically connected. As long as I provide regulated 5v power to either one its fine. Presumably I should not connect live power sources to both at the same time. Is this basically correct?
Now, VIN I assume is for connecting 7-35v. There is a voltage comparison transistor that selects the VIN if it has voltage greater than the other inputs (5v). This is like the Uno, in that you can feed it 7v externally, and it will use that instead of the USB power, when the spark is connected to the computer. Is this correct?
If I connect the Digispark to USB power, and nothing to the VIN pin, it looks like it gives less than 5v on the VIN pin (3.8v by my measurements). If I measure the 5v pin when the Spark is connected to USB, I get 4.6v, so it looks like the VIN pin is going through the regulator, and the 5v pin has some loss (diode maybe?). Is this correct?
Basically, I'm trying to figure out the appropriate way to wire up Neopixels, which want 5v and higher amps if I light many lights. For a small number of pixels (32 for 2 LED rings in a goggle setup), I want one power source. On the Teensy 3.0, I can hook the Teensy up to USB power, and use the VIN pin to give me access to the 5v directly (Teensy 3.0 is an Arm processor running at 3.3v). Should I hook the pixels power up to the 5v pin in the Spark, or do I need to create a regulated 5v support, and feed both the Spark and the Neopixels directly?