ENCYCLOPEDIA OF RADIO ELECTRONICS AND ELECTRICAL ENGINEERING Arduino. Acquaintance. Encyclopedia of radio electronics and electrical engineering Encyclopedia of radio electronics and electrical engineering / Radio amateur designer Probably, in the life of any novice radio amateur, there comes a moment when he is no longer satisfied with the simplest electronic devices. There is a desire to design something practically useful. However, devices based on a pair of transistors can hardly be expected to solve more or less complex problems. On the other hand, a novice programmer may want the programs he writes to control some kind of autonomous robot or other similar device. It's one thing when a program simply works with information in the computer's memory, and it's quite another when a robot, obeying a written program, goes on a "journey" around the room or a programmed microcontroller becomes part of some useful device. At the same time, neither a novice radio amateur nor a programmer still has sufficient knowledge and skills to repeat, let alone re-design a micro-controller device. After all, in fact, a microcontroller is a very small and simple, but still a computer. It is necessary to know in detail the architecture of a particular microcontroller, to study the assembler language specific to it. The easiest way to solve this problem is to use a ready-made kit for creating robots like those made by the famous manufacturer of all kinds of designers for children - Lego. Such a kit contains all the necessary components for the manufacture of a robot: a microcontroller unit, electric motors, sensors. The undoubted advantage of such a set is that it is possible to design a robot based on it very simply and quickly. All necessary software is included with the kit and has an intuitive interface. Technical documentation is designed for the youngest lovers of technology. However, according to the author, for a not very large set of sensors and actuators, as well as a set of standard plastic parts, an unreasonably large amount will have to be paid. However, this does not negate the fact that such designers are best suited for the younger age group. Despite the high cost of specialized constructors, the very idea of using a relatively small number of standard functional units to create a complex device looks quite sensible. This is the path followed by the developers of the Arduino board with the AVR series microcontroller and many expansion boards for it. The most common version of this board today is the Arduino UNO. To create custom programs, there is a specialized development environment Arduino IDE, in which programming is carried out in a language based on the widely used C ++ language. The great advantage of Arduino is its almost complete openness. On the official website of the developer, you can download the development environment for free [1,2]. When it starts, the one shown in Fig. 1 window in which you can enter the program, translate it into machine code, load it into the microcontroller of the Arduino board and run it for execution.
It should be noted that the Arduino development company has split into two independent companies, Arduino LLC and Arduino SRL, which continue to produce products under the same brand name, which creates confusion. Nevertheless, the software is regularly updated, there are versions for Windows, Linux, MacOS. In addition to the software supplied by the board developers, there are many other development environments, for example, [3]. The folder with the software is best placed in the root folder of drive C. Together with the program text editor and the compiler, it contains subfolders with examples of typical programs and a set of libraries for solving standard tasks, which greatly simplifies the life of a novice programmer. The first time you connect the Arduino board to your computer, the operating system will detect the new device and require you to install its driver, which is also available in the software folder. After installing the driver, you need to restart your computer. As a result of successful installation, an additional COM port will be displayed in the Windows Device Manager. The use of a high-level language simplifies development and greatly reduces the requirements for the programmer's qualifications, but, on the other hand, the resulting program will not be optimal in terms of occupied memory and execution speed. A program written in a low-level language (assembler language) would take up significantly less memory space and would run faster. But in amateur developments, this can be neglected. Naturally, in critical cases, you need to use the Arduino with extreme caution. However, it is fundamentally possible to use Arduino in a variety of devices: from the simplest thermostat to unmanned aerial vehicles. For example, the Russian aerospace company "Lin Industry al" [4], engaged in the design of ultralight launch vehicles, created an Arduino-based flight parameter recording unit (Fig. 2) for its experimental rocket (Fig. 3). And scientists from the Indian Institute of Research and Science Education (Trivandrum) used Arduino in a training radio telescope [5].
A special bootloader program is pre-written in the microcontroller installed on the Arduino board. With its help, the application program developed on the computer is written to the program memory of the microcontroller. The bootloader itself takes up some of this memory (from one to four kilobytes, depending on the version), but thanks to this organization of interaction with the computer, it is difficult for the user to bring the microcontroller to an inoperative state using incorrect commands. An ATmega4P microcontroller is installed on the Arduino UNO board (Fig. 328), which has 2 KB of RAM and 32 KB of program memory. The microcontroller clock frequency of 16 MHz is set by a quartz resonator. Arduino UNO does not need a separate programmer, the board can be directly connected to the USB connector of the computer, for which it has a USB-BF connector and a USB-to-serial interface converter on the microcontroller. In other variants of Arduino boards, a micro-USB connector can be used to connect to a computer. On outdated and homemade boards, you can also find a regular COM port.
The Arduino UNO board connected to the computer is powered by the USB connector. And to work without a computer, it needs to be supplied with a voltage of 7 ... 12 V from an external source, for which the board has a special connector. Thanks to the built-in voltage regulator, Arduino UNO does not impose special requirements on the quality of the supply voltage. So its source can be almost any small-sized power supply, the output voltage of which lies in the required range, and even a 9 V galvanic battery, for example, Krona (6F22) or two series-connected 3336 batteries (3R12). There are 14 digital input-output lines, which are called D0-D13, for communication with external actuators, as well as for retrieving information from sensors. On six of them, the microcontroller can output pulses with a software-controlled duty cycle (PWM). They are marked on the board with "~". In addition, there are six analog input lines A0-A5. Analog inputs are connected to a ten-bit analog-to-digital converter built into the microcontroller, but if necessary, they can also be used as additional digital input-output lines D14-D19. It should be noted that from version to version of the board, the number of analog input lines and lines capable of operating in PWM mode changes. For example, the Arduino Leonardo board and its domestic counterpart Iskra Neo have 12 analog lines and seven PWM lines. As a rule, all I/O lines on the boards are marked, so it is easy to understand them. There are four LEDs on the Arduino UNO board: a power indicator (ON), an LED permanently connected to the D13 line (L), and two LEDs to indicate the exchange of information with an external device via the serial port (TXi RX), as well as a button to bring the microcontroller into the initial state. One of the advantages of Arduino is a wide range of additional boards, the so-called "shields" (English shield - shield). They allow you to connect electric motors and other powerful loads to Arduino, provide work in computer networks using Ethernet and WiFi protocols, transmit information over a GSM cellular network, work with sound, etc. Many ready-made software libraries, both official and official, work with shields. and those written by third parties. The Arduino UNO board is well suited for debugging programs at the development stage and establishing designs. But for many practical applications, the capabilities of the Arduino UNO are redundant, and its size may be too large to be installed in the finished product. Arduino Nano and Arduino Mini boards are oriented to use in ready-made designs. In terms of parameters, they are almost identical to the Arduino UNO, but they have a simplified design, smaller dimensions and are somewhat cheaper. If the capabilities of the Arduino UNO are not enough, you can use the Arduino Mega board with more memory and the number of I / O lines. The list of options for Arduino boards is not exhausted by this, but other options for initial study are less suitable. Only the name Arduino is protected by copyright, so many manufacturers release their own versions under the names Free-duino, Craft Duino, Funduino, Diavolino, etc. Among all this diversity, there are designs that completely repeat the original ones, as well as their own designs, the compatibility of which with the original sometimes questionable. However, as a rule, devices from different manufacturers are standardized, so if the board is declared as a copy of the Arduino UNO, then everything said about the Arduino UNO applies to it, although, of course, you cannot vouch for each manufacturer. An acceptable level of quality for an amateur can be provided not only by manufacturers of original devices, but also by little-known companies that offer similar designs at a much lower price. The Arduino board is not very complicated and is quite affordable for self-production, the documentation for this can be found on the official website of the manufacturer [6]. A description of the homemade board, which is part of the Arduino family, was also published in the Radio magazine [7]. Thanks to these advantages, among electronics lovers, Arduino has actually become a kind of standard. The use of complete function blocks and program libraries greatly simplifies and therefore speeds up development. In fact, Arduino shields are "black boxes". It is important how this or that block reacts to certain signals and influences, but its internal structure is not fundamental. Printed publications in Russian dedicated to the description of Arduino exist, but, frankly, they do not lie on the shelf of every bookstore or library. As an example, we can cite the book [8], and among the periodicals we can note a series of articles in the journal "Levsha" (an appendix to the journal "Young Technician"). There, starting from No. 6 for 2012, monthly publish articles on the use of Arduino [9]. However, on the Internet you can find a lot of resources, both completely devoted to Arduino [10-12], and sites of a broader scientific and technical orientation, which have corresponding sections [13-16]. In conclusion, you can see that to facilitate the work with Arduino, you can make a few simple devices. For example, it is not very convenient to stick the stripped ends of the wires into the sockets of the connectors. For this, there are shown in Fig. 5 special connecting wires with lugs, which are both pins and sockets. It is easy to make similar wires yourself using contacts from connectors. And for quick connection of external devices, it is better to use connecting wires like the one shown in Fig. 6, on one end of which a crocodile connector is soldered, and on the other - a pin contact.
It is often necessary to connect several wires to one output of the board, for example, to supply power to several sensors. Here you can use PBS sockets or similar, all the leads of which must be connected together and soldered to the connecting wire, at the opposite end of which there is a pin contact. For quick assembly of simple devices without the use of a soldering iron, special prototyping boards are well suited. The appearance of one of them is shown in Fig. 7, and the diagram is in fig. 8.
The hard leads of the parts are inserted into the spring sockets of such boards, and the missing connections between them are made with wire jumpers or the wires described above. So, the main advantage of Arduino, on the one hand, is the presence of well-developed and flexible capabilities in order to become the basis of fairly complex designs, on the other hand, the amount of initial knowledge necessary to get started does not actually go beyond school courses in physics and computer science. Literature
Author: D. Lekomtsev See other articles Section Radio amateur designer. Read and write useful comments on this article. Latest news of science and technology, new electronics: A New Way to Control and Manipulate Optical Signals
05.05.2024 Primium Seneca keyboard
05.05.2024 The world's tallest astronomical observatory opened
04.05.2024
Other interesting news: ▪ LaCie Mobile SSD Secure and Portable SSD 2TB Pocket Drives ▪ Good cholesterol protects the liver from inflammation News feed of science and technology, new electronics
Interesting materials of the Free Technical Library: ▪ site section Batteries, chargers. Article selection ▪ article Tin boars. Tips for a modeler ▪ article Where do spiders live that can move like acrobats performing somersaults? Detailed answer ▪ European cow parsnip article. Legends, cultivation, methods of application ▪ article A simple CB antenna. Encyclopedia of radio electronics and electrical engineering ▪ article Comparison of the number of cards of black and red suit. Focus Secret
Leave your comment on this article: All languages of this page Home page | Library | Articles | Website map | Site Reviews www.diagram.com.ua |