Using Shields (ART292E)

An important part of the projects involving microcontrollers is the Shield. By interfacing the microcontroller with sensors and output devices which require high currents, they are fundamental for the control of solenoids, relays, motors and other high power devices. See in this article how to work with these important interfaces.

The outputs of a microcontroller such as those used on Arduino boards can only provide 40 mA currents with 5 V and 50 mA with 3 V.

This means that if we want to control higher current circuits or devices we can not make their direct connection to these boards.

Even taking into account the limit situations in which we control higher current loads, if we use all the outputs simultaneously for this purpose, we run the risk of overloading the microcontroller, taking it to the limit of its dissipation.

If we want to control higher power loads, above 50 mA, we need to use some kind of higher capacity interface, usually called "Shields".

A Shield is nothing more than a power circuit that, from the outputs of a microcontroller, such as Arduino, can control a certain load.

 


 

 

 

Some Shields also offer the possibility of isolating the microcontroller output from the controlled circuit or device, adding safety which is especially important when the controlled circuit or device is connected to the power grid.

In general, Shields can be easily assembled, either experimentally on solderless boards or as permanent or universal boards, there is the possibility of buying a ready unit.

Boards containing sets of relays, H-bridges are common to control higher power loads or motors with the reversal feature.

 

Figure 2 – Four-relay board
Figure 2 – Four-relay board

 

 

However, there are cases where the ready board does not exist or if it exists it has features far beyond what we need.

For example, we may need to control a power load through a relay, but we only have Shields for sale with 4 relays.

We pay for four and use only one, which besides being a waste, can compromise a project in which we want to occupy the smallest possible space.

In this case, it is best to build the Shield and we need a circuit for this purpose.

On our site we have several options for these interfaces, from common components to adding additional features such as an external timer or another feature that no longer needs to be programmed.

Another possibility is that there is no Shield for what we want to do which requires not only a circuit for its activation but also the circuit itself.

For example, if we are creating a high-powered sound alarm, besides the drive circuit that involves, flike a relay, we also need the siren itself to be controlled.

Building a specific Shield for this, we can have a different approach to the problem: we can make the siren controlled by the microcontroller, for example, Arduino eliminating many components.

We eliminate the relay and we make the digital control of the siren. In another article in this section, we show you how to proceed in cases like this.

The adaptation of common circuits "building blocks" like the ones we have in thousands of our articles, circuit banks, mini-projects and simulated circuits in Multisim offers a huge range of ideas on this site.

We can use development Shields, as in Figure 3 which contains a contact array.

 

Figure 3 – Small development board
Figure 3 – Small development board

 

 

More than that, we can use our simulations to verify if a project works, not necessarily using a microcontroller that is available in the simulator.

For example, we can simulate the operation of a block, as shown in the figure below, using the function generator and adjusting its output to rectangular pulses as the ones obtained in the output of an Arduino, as shown in Figure 4.

 

 

Figure 4 – Simulating a shield
Figure 4 – Simulating a shield

 

 

Simply adjust the output of the rectangular generator to 3.3 V or 5 V and check if the block works, as it is appropriate.

Note that in this simulation we have a 5 V lamp, but its voltage can be higher.

In the given example we have a high power beacon controlled by the microcontroller.

 

The Electronics

While microcontroller boards such as Arduino, MSP430, PIC and others contain most of the electronics we need in our designs, basic knowledge of electronics is still critical to developing a project, except in a few cases where Shields do everything.

Knowing electronics to know what to connect, how to connect and what to program is fundamental for projects involving these boards.

On our website, in addition to a vast amount of theoretical articles that deal with circuits, projects and interpretation of diagrams, besides the principle of functioning of everything that is electronic, the reader will also have the possibility of acquiring courses and books of support.

And of course, buying your board, Arduino, for example, it will be interesting to have an array of contacts and a good stock of basic components like transistors, resistors, capacitors, diodes, relays, LEDs that in many cases can be acquired in the form of kits .

From there on you only need to create your circuits remembering the programming of which we will deal later on.

 

 

Shields Sensors

Just as we have the actuator circuits, the signals that control our design can come from the most diverse types of sensors.

Many of them can be attached directly to the boards as they provide compatible signals such as LDRs, thermistors, micro-switches, etc.

However, in some cases, signals are not compatible with the inputs requiring special Shields that process their signals to an appropriate form of driving.

We have in this case, Shields of inertial sensors and even radio signals which can receive the control signal from a cellphone or tablet through Wi-Fi connection.

While in some cases these Shields can also be assembled, there are many of them that can be purchased ready.

 

Where to get Shields

By following Google's directions, the reader can find several Shields suppliers in our country, besides the Arduino boards themselves and other microcontrollers.

Prices vary according to what each Shield does.

MOUSER ELECTRONICS (www.mouser.com) also provides excellent quality, original and not from doubtful sources Shields.

Just access their site through our advertising and in the search enter the word "shield" that the reader will see all the available options.

 

Programming

The programming language used in most cases offers no learning difficulties.

The C and C ++ language are the most used with many courses and tutorials on the Internet.

In many cases, ready-made "sketch" programs can be found, which can be easily used or adapted to what we want.

 

Conclusion

From a time when even the components needed to be assembled at home, improvised with the material that was available, through the common components and integrated circuits obtained in the specialized market, we came to the "maker" of the 21st century.

Starting from microcontrollable boards and shields pratically any design can be created, from robots and drones to wearable and home appliances that in many cases can be turn out to be excellent commercial products.