How can we power, say, the controller’s board? We usually do it with the help of a USB cable. We can use the battery compartment which can fit several batteries. We can take one Krona battery and connect it to Arduino directly with a power plug. We can take a power module with regulated voltage or without it. The main thing is that the power source supplies suitable voltage for the board. Let me remind you that for Arduino, as well as for the majority of other boars,
including Iskra, preferred voltage is from 7 to 12 V, whereas permissible voltage is from
6 to 20 V. Its operating voltage is 5 V, but it has a voltage regulator built in it, which transforms any input voltage into 5 V voltage. The only thing is that if you supply input voltage lower than 7 V, at the pins you might receive a slightly lower voltage than 5 V. That’s why when we were looking at the description of the pump, I mentioned that its permissible voltage is from 3.5 to 12 V. In fact, every component has its own preferences when it comes to power, and you always need to pay attention to that. All the modules that we’ve used before and are going to use in the future, are optimized for 5 V voltage, because they were initially created for Arduino. However, let’s not forget that you might come across a device which has different power requirements. Besides, you always need to know how much the current draw would be for the newly connected component. For instance, you might discover that the pump’s current draw is quite high, from 65 to 500 mA, but Arduino’s outputs don’t actually allow such current load. Let’s once again look at the section of Arduino’s socket, to which power is connected. Apart from two “ground” outputs, there is one 5 V output. Ideally, you can use it to power some of your devices, but you need to remember that this output can only cope with currents
not higher than 800 mA. There is also a 3.3. V output, since the second best practice for small modules and their components is 3.3. V power. Here only 50 mA is permissible. The most intriguing output for us now is Vin. It is connected directly to the power input, from which power is supplied
to Arduino. This means that if you, say, connect a power module or a battery compartment to it, all this will be output through Vin. Moreover, you can connect your plus power pole directly to Vin and supply power through it to the controller's board. If you power your Arduino through USB, make sure that the load of your device does not exceed 500 mA, otherwise Arduino’s protection tool will be turning the power off in order not to
overload the USB port. If you want to supply high load, you need to use a powerful power source. You can solve this problem is various ways: you can either connect the power
source to Arduino and supply power
through the Vin output, or you can connect power separately to a powerful power supply. In the latter case, make sure that all your “ground” poles are interconnected in your circuit. If your ground values are different, then your voltage, i.e. the difference of potential between the “ground” and the “plus”,
may turn out to be different. In some cases, this could lead to some undesirable effects. Let me remind you once again that you need to connect the grounds if you are
using different power sources. In most cases, however, you won’t need to think about it, since if you are using some expansion cards, for instance, which allow you to connect some additional power source, like Multiservo shield, which we examined in Week 3, everything has already been taken care of. The grounds are interconnected there, so you won’t need to think about it. But if you take separately a battery package and a motor, you will need to connect the power “minus” to Arduino’s “ground”. By the way, I have removed one battery from the battery compartment not just because it’s easier to turn the device off this way, but also because its wires are loose now, and they can easily close. In this case, we will see a smoking power module, feel some smoky odor and might even witness
the power module ignite. I have witnessed this several times myself. That’s why when you are done working with your device, remove at least one battery. Now let’s imagine that you want to connect the pump to 3.5 V voltage, which is quite permissible for it, and you want to use the same power source to power your controller. Since we remember that Arduino works in the 6-7 V diapason, we don’t need to use an additional power source - we can just use the step-up voltage converter. It appears as a module in our circuit too, and it has two terminal blocks: the input and the output. Between them, apart from the components which perform this conversion, there is a preset resistor. This is a resistor which can be rotated in either direction to control output voltage. We shall do this next week, and you will get to see how this works
in practice. Let’s sum up: when you start assembling your device, think about how you are going to power it. What voltage does each of the components need? What current will be drawn to this component while it’s on? Consequently, how exactly are you going to power it? Will all your components have separate power supplies, or will they just have
one common power supply? If it’s a separate power supply, are you going to connect the ground? It must be connected. Once you’ve figured this all out, everything should work without a hitch, and there will be no need
to fear that something might
ignite.