Internet Windows Android

Useful devices on arduino. Homemade Arduino

Arduino. The well-known and loved by many device has become so popular that even small children are already trying to write a sketch before they are born. PS, this is banter ... In short, I don’t want to lag behind, and in this article I’ll tell you how to turn an ATmega8A expansion board into an arduino. Who does not know what this fee is, they can read it. Yes, I understand, many will say, but where is home-made. And homemade is that for Arduino you need only a few things. The first is the microcontroller. For cheapness go ATmega8. The second is quartz at 16 MHz. Third - two ceramic conduits for 22pf. And the fourth is a USB TTL converter, any. To assemble, you need to attach quartz to the legs of the MK XTAL1 and XTAL2. Attach two conders to the same leg, and the other legs of the conder to the ground and that's it.

Now let's move on to practical actions. We will turn a debug board into Arduino, but all actions are valid for a simple MK, quartz and a pair of conders. And so, let's go.
On the expansion board, the quartz is set to 7.3728 MHz by default. It won't work for Arduino. So we take and change it to 16 MHz.

Next, we need to upload the bootloader to our board. To do this, take any Arduino board. I have an Arduino UNO on hand. If you don't have an Arduino yet, it's time to get one. You can buy it at the Chip Resistor store. And so, we have an Arduino UNO. we put the Arduino UNO in front of us on the right on the table, and the ATmega8A expansion board on the left. On the right side, these boards have an ISP connector with the classic Atmel pinout.

Feel free to take the wiring and connect these connectors one to one with the exception of pin 5.


Now we take the wires and insert one end into the 5th pin on the ATmega8A expansion board, and the other end into the Arduino UNO Digital 10 pin. It should turn out like this.

As a result, after all the manipulations, we should have this look.

If everything is fine, then connect to the USB of the computer. When properly connected, the LEDs on the Arduino UNO and the red LED on the ATmega8A expansion board should light up. (Unfortunately, in the photo, the wires blocked the LED, but believe me, it is on)

We turn to software procedures. And here all fans of the ATmega8 MK are waiting for a big set-up from the Arduino manufacturers. Currently IDE version 1.6.3 does not support these microcontrollers. More precisely, there are configuration files and a bootloader, but it cannot be uploaded. The fact is that Arduino switched to the minimum ATmega328P MK, and this infection has Extended Byte Fuse. But the bad eight is not. Because of this rubbish, the bootloader is not flooded, but swears at the absence of these bits. Therefore, you need to fill the bootloader with the old version of the IDE. If you don't have it, you can download it from me. This is version 1.0.3 and does not need to be installed. Just unzip somewhere and that's it. Then just run the program from this folder. And now let's set up the program for filling our MK. First, choose a programmer from the examples ArduinoISP and upload it to the Arduino UNO or whatever you are currently using.

After pouring, you need to replace the Arduino UNO board or which one you have on Arduino NG or older w/ATmega8.

Everything. Can be filled. Click Tools -> Write bootloader and wait for the end of the recording.

Ready. Arduino was born. We disconnect all the wires, and hang the expansion board on the GSMBOARD 1.1 debug board. Next, we take the USB-TTL expansion board and connect it with GND - GND, RXD - TXD, TXD - RXD wires and apply power. The green LED should light up.

If everything worked, turn off the old program and run the latest version of the male. Today it is 1.6.3 and we are writing this code. void setup() ( pinMode(2, OUTPUT); ) void loop() ( digitalWrite(2, HIGH); delay(2000); digitalWrite(2, LOW); while(1); ) Exactly what is happening here. First, we initialize pin 2 to the output. Then we display a unit on it, wait two seconds and press it to zero. Then we fall into an endless loop. To make it clear, here is a picture of what the debug board has turned into.

As you can see, the second pin is just responsible for turning the module on and off. Now it's time to upload our sketch to the freshly baked Arduino. To do this, reconfigure the IDE by selecting the items as in the picture below. And don't forget to change the port to USB-TTL.

All set up. Click upload sketch. Everything would be fine but the error got out. Eh. Here's what a rake zavolyalas. The Arduino uses a virtual COM port to download programs. It works like this. First, the IDE compiles the project, then pulls the MK reset button, and since the bootloader starts first, the IDE, seeing it, starts pouring the program into flash. And if, after compilation, you do not reset the MK, then the IDE of the bootloader will not wait and will throw out an error. To jerk the reset, all Arduinos have a DTR COM port pin. The USB-TTL expansion board does not have this leg, so when the IDE compiles the project and writes Loading.

Frantically press and release the reset button on the ATmega8A expansion board. The IDE will pick up the bootloader and flash the program. Everything, the program will go down a bit and turn on the GSM module. If everything is done correctly, it should be like in the picture.

For happy owners of USB-RS232 adapters, you can bring the DTR pin out of the port (of course, through the MAX3232 chip) to the MK reset. This is pin 5 on the ISP header through a 100nF capacitor. That is, DTR - capacitor - RES. And then the IDE itself will pull the reset. In any case, this should be the picture. The program worked and turned on the module.

Now you can tinker with the GSM module. If you have any questions, write. Let's try to figure it out.

ANONYMOUS 02.02.16 22:32

Thank you for the article. Now I can use mega 8 in my arduino uno.

niko19 25.12.16 23:03

Why the hell do all this with an expansion board and get an Arduino if there is already a ready-made Arduino on the table? The question is how to make a home-made Arduino, let's say on a breadboard, from Mega8 and quartz lying around. What needs to be poured into Mega, literally point by point, or even better, a ready-made firmware file. For example, I have a parallel programmer, however, I also have a serial programmer, and there is no ready-made Arduino ...

Alexey 25.12.16 23:40

Arduino is an Atmel microcontroller with a loaded bootloader for working with arduino IDE. All you need is to set the fuses for the bootloader, select from the firmware folder for your MK and fill it in. If in short.

Arduino is a versatile DIY platform for microcontrollers. There are many shields (expansion boards) and sensors for it. This diversity allows you to make a number of interesting projects aimed at improving your life and increasing its comfort. The areas of application of the board are endless: automation, security systems, systems for collecting and analyzing data, and so on.

From this article you will learn what you can do interesting things on Arduino. Which projects will be spectacular, and which ones will be useful.

What can be done with Arduino

robot vacuum cleaner

Cleaning the apartment is a routine and unattractive task, especially since it takes time. You can save it if some of the household chores are assigned to the robot. This robot was assembled by an electronics engineer from Sochi - Dmitry Ivanov. Structurally, it turned out to be of sufficient quality and is not inferior in efficiency.

To assemble it you will need:

1. Arduino Pro-mini, or any other similar and suitable size...

2. USB to TTL adapter if you are using Pro mini. If you chose the Arduino Nano, then you don't need it. It is already installed on the board.

3. L298N driver is needed to control and reverse DC motors.

4. Small engines with gears and wheels.

5. 6 IR sensors.

6. Engine for the turbine (larger).

7. The turbine itself, or rather the impeller from the vacuum cleaner.

8. Motor for brushes (small).

9. 2 collision sensors.

10. 4 x 18650 batteries.

11. 2 DC-DC converters (boost and step-down).

13. Controller for operation (charge and discharge) of batteries.

The control system looks like this:

And here is the power system:

Such cleaners are evolving, factory-made models have complex intelligent algorithms, but you can try to make your own design that will not be inferior in quality to expensive counterparts.

Able to produce a luminous flux of any color, they usually use LEDs in the body of which there are three crystals glowing in different colors. They are sold to control them, their essence lies in regulating the current supplied to each of the colors of the LED strip, therefore, the intensity of the glow of each of the three colors is regulated (separately).

You can make your own RGB controller on Arduino, even more, this project implements control via Bluetooth.

The photo shows an example of using a single RGB LED. To control the tape, an additional 12V power supply is required, then the gates of the field effect transistors included in the circuit will be controlled. The gate charge current is limited by 10 kΩ resistors, they are installed between the Arduino pin and the gate, in series with it.

Using a microcontroller, you can make a universal remote control controlled from a mobile phone.

For this you will need:

    Arduino of any model;

    IR receiver TSOP1138;

    IR LED;

    Bluetooth module HC-05 or HC-06.

The project can read codes from factory remotes and store their values. After that, you can control this homemade product via Bluetooth.

The webcam is mounted on a rotary mechanism. It is connected to a computer with installed software. It is based on the computer vision library - OpenCV (Open Source Computer Vision Library), after the program detects a face, the coordinates of its movement are transmitted via a USB cable.

The Arduino gives a command to the drive of the rotary mechanism and positions the camera lens. A pair of servos are used to move the camera.

The video shows the operation of this device.

Watch your animals!

The idea is to find out where your animal is walking, this can be of interest for scientific research and just for fun. To do this, you need to use a GPS tracker. But to store location data on some drive.

At the same time, the dimensions of the device play a decisive role here, since the animal should not feel discomfort from it. To record data, you can use it to work with Micro-SD memory cards.

Below is a diagram of the original version of the device.

The original version of the project used the TinyDuino board and shields for it. If you can't find one, you can use small Arduinos: mini, micro, nano.

For power, a Li-ion element of small capacity was used. The small battery lasts for about 6 hours. The author ended up fitting everything in a cut-off tic-tac jar. It is worth noting that the GPS antenna must point upwards in order to receive valid sensor readings.

Combination lock breaker

To crack code locks with Arduino, you will need a servo and stepper motor. This project was developed by hacker Samy Kamkar. This is a rather complex project. The operation of this device is shown in the video, where the author tells all the details.

Of course, such a device is hardly suitable for practical use, but this is an excellent demonstration.

Arduino in music

This is more likely not a project, but a small demonstration of how this platform has been used by musicians.

Drum machine on Arduino. It is noteworthy that this is not an ordinary enumeration of recorded samples, but, in principle, sound generation using "iron" devices.

Detail ratings:

    NPN-type transistor, for example 2n3904 - 1 pc.

    Resistor 1 kOhm (R2, R4, R5) - 3 pcs.

    330 Ohm (R6) - 1 pc.

    10 kOhm (R1) - 1 pc.

    100 kOhm (R3) - 1 pc.

    Electrolytic capacitor 3.3 uF - 1 pc.

For the project to work, you will need to connect the library for fast expansion into a Fourier series.

This is a fairly simple and interesting project from the category of "you can brag to your friends."

3 robot projects

Robotics is one of the most interesting areas for geeks and just those who like to do something unusual with their own hands, I decided to make a selection of several interesting projects.

BEAM-robot on Arduino

To assemble a four-legged walking robot, you will need:

    Servo motors are needed to move the legs, for example, Tower Hobbies TS-53;

    A piece of copper wire of medium thickness (to withstand the weight of the structure and not bend, but not too thick, because it does not make sense);

    Microcontroller - AVR ATMega 8 or Arduino board of any model;

    For the chassis in the project, it is indicated that the Sintra Frame was used. It is something like plastic, it bends into any shape when heated.

As a result you will get:

It is noteworthy that this robot does not drive, but walks, can step over and go to elevations up to 1 cm.

For some reason, this project reminded me of a robot from the Wall-e cartoon. Its feature is the use for charging batteries. It moves like a car, on 4 wheels.

Its component parts:

    Plastic bottle of suitable size;

  • Jumpers mom-dad;

    Solar panel with an output voltage of 6V;

    As a donor of wheels, engines and other parts - a radio-controlled car;

    Two continuous rotation servos;

    Two conventional servos (180 degrees);

    Holder for AA batteries and for the "crown";

    Collision sensor;

    LEDs, photoresistors, 10 kΩ fixed resistors - 4 in total;

    Diode 1n4001.

Here is the basis - the Arduino board with a proto-shield.

This is how spare parts from - wheels look like.

The design is almost complete, the sensors are installed.

The essence of the work of the robot is that it goes to the light. Abundance he needs to navigate.

This is more of a CNC machine than a robot, but the project is very entertaining. It is a 2 axis drawing machine. Here is a list of the main components of which it consists:

    (DVD) CD drives - 2 pcs;

    2 drivers for stepper motors A498;

    servo MG90S;

    Arduino Uno;

    Power supply 12V;

    Ballpoint pen, and other design elements.

From the optical disc drive, blocks with a stepper motor and a guide rod are used, which positioned the optical head. From these blocks, the engine, shaft and carriage are removed.

You won’t be able to control a stepper motor without additional equipment, therefore, special driver boards are used, it is better if a motor radiator is installed on them at the time of starting or changing the direction of rotation.

The complete assembly and operation process is shown in this video.

See also 16 best Arduino projects from AlexGyver:

Conclusion

This article is just a small drop of what you can do on this popular platform. In fact, it all depends on your imagination and the task that you set for yourself.

Arduino is a hardware computing platform that is used to design and create electronic devices of various levels of complexity.

At the heart of this electronic constructor is a hardware platform for input and output, which is programmed in the Processing / Wiring language, created on the basis of C ++. What components does the Arduino consist of, what can be done with it and how to learn how to handle this smart chip?

Arduino is one of the most common miniature controllers with a set of inputs and outputs that works according to a pre-written program. This universal controller is very convenient for prototyping electronic devices, which makes it popular not only among students and hobbyists from all over the world, but also among advanced designers and inventors.

Arduino captivates with its versatility. Using special expansion boards, this controller can communicate with other devices via Bluetooth, Wi-Fi, GPRS, make and receive phone calls and SMS.

The controller is not a simple chip, but a board with a ready-made power circuit and interfaces for connecting to a PC, input and output connectors.

Thanks to a wide range of protocol libraries, it is possible to organize the interaction of Arduino with sensors and servos used in modern robotics.

And the open architecture makes it possible to customize the Arduino for any purpose. And thanks to the simplified programming language, it will be easy even for beginners to master the operation of the controller. It is especially convenient to work with Arduino thanks to the platform, which gives an almost instantaneous response to programmed commands.

What can be done with Arduino? We add lessons on creating devices based on this board in our Arduino Lessons section. A programmer, designer or engineer can turn almost any original idea into a working prototype - all you need to do is purchase a controller and additional radio components. Also, programming and circuitry enthusiasts are captivated by the low cost of Arduino, which makes the controller accessible to the masses.

Projects on Arduino: what can be done

Let's look at some original ideas that can be implemented on Arduino. In addition to the circuit itself, you may need additional details that are most profitable to buy on AliExpress.

Home temperature controller

You can implement such a project using several Arduino Nano boards and one Arduino Uno or Mega, which will act as a base. Communication between modules can be implemented using NRF24L01– a radio communication module, which makes it possible to combine up to 6 boards.

In one case, you need to assemble an Arduino Nano connected to humidity and temperature sensors, as well as a module NRF24L01. The power source can be a conventional battery. Several of these devices must be placed throughout the house.

Indicators from will be transmitted to the base, which is the Arduino Mega or Uno. It also needs to connect NRF24L01 signal receiver, power supply and LCD display to display text information. It is necessary to locate the "base" in the immediate vicinity of the heating system. By accepting and processing incoming data on humidity and temperature, the base will send commands to the heating system and increase or decrease the temperature.

CNC machine

This idea is one of the most difficult to implement. With the Arduino Mega, you can implement not only a CNC machine, but also a 3D printer. In addition to the board itself, you will need motor drivers L298N as well as the engines themselves. The rest of the work is the frame and code development.

smart greenhouse

All owners of a garden or a personal plot know how much attention a greenhouse and seedlings grown in it require. It is necessary to constantly monitor soil moisture, open and close doors in time, etc. With the help of Arduino, all these routine processes can be automated.

Using just one Arduino Mega board and a controller, you can capture and display information about the temperature in the greenhouse, as well as send commands to start watering, control motors to open and close doors.

robots

Robots are the best toy not only for children, but also for adults, especially when it is possible to control them. Using Arduino and various materials at hand, you can make a robot in any configuration: from the most primitive to complex models.

For example, with the help of ultrasound, your robot will be able to fix the distance to obstacles and go around them while moving. Applying motor driver L293D, you will have at your disposal 3 servos and 4 motors. With the help of the HC-06 module, you will be able to control your brainchild via Bluetooth via a smartphone.

Of course, the list of projects on Arduino that you can do with your own hands is not limited to this - the possibilities here are limited only by your imagination and skills.

Holding the original Arduino board in my hands, the idea of ​​​​assembling its clone arose in my head. After sitting and thinking about the project, it was decided to fit everything on a one-sided board, and to provide the board with an FT232RL chip for communication with a computer. In order to avoid the failure of the computer's USB port due to excess current consumption, I decided to sacrifice the ability to power from USB, but more on this move a little later.

So, dear readers, I present to your attention our version of the Arduino clone. Meet Paduino FT232RL

As mentioned above, the board has a drawback - it is deprived of the possibility of power supply from the USB port. However, thanks to the use of the FT232RL chip, there is a 3.3V output on the board. Also to add. I would like to attribute the functionality to the presence of an automatic boot jumper (ENABLE), as well as a jumper (JP LED13), which allows you to turn off the not always used LED connected to pin number 13.

Also, in addition to the already existing Vin output on the Arduino, a VTG INPUT output has been added. In my opinion, the standard output Vin has a number of disadvantages, although on the other hand there are pluses. The disadvantages include the loss of voltage across the diode (0.6-0.8 volts), also when the Arduino is powered not from the power connector, but directly from the combs, we lose protection against polarity reversal. the Vin output in the circuit is located after the protective diode. At the VTG INPUT pin, we always have a voltage equal to the input voltage without any losses, and when the Arduino is powered through the combs, the reverse polarity protection functionality is preserved. in the diagram, the output is located in front of the protective diode. The advantages of the Vin output include the fact that when the power is properly supplied, it will always have a plus, otherwise there will be nothing, while the VTG INPUT is either a minus or a plus.

The meaning of this modification is the ability to power homemade motor shields presented on this site and our Arduino clone from a single power source without any loss of supply voltage.

Since the FTshka in this assembly uses only the ground and signal lines of the USB port, then, having looked through the datasheet, we will hang a harness on it in the following configuration:

This time I will skip all the manufacturing steps. From the manufacturing process, I will attach only a photo of the etched and tinned board before the installation of the elements.

A few words about FT232RL. The microchip is quite small. In order for you to be able to assess your strengths, I give a photo of the FTS on a ten-kopeck coin.

We attach the Ftshka to the board, center it, moisten the legs with flux, take a very small amount of solder on the soldering iron tip, and quickly go through each leg. If you are new to soldering and have not yet learned how to solder quickly, with one touch, I advise you to make an interval of 10-15 seconds after each leg.

In terms of size, the Paduino is not much larger than the original Arduino.

Everything, with the manufacture figured out. To work in the Arduino environment, it remains only to fill in the controller memory bootloader.

After uploading the bootloader, nothing prevents us from proceeding directly to programming.

First you need to download the Arduino environment. You can download the latest version from the manufacturer's website.

We connect our clone to the computer, if the Internet is available, the device should be detected automatically.

If, when connecting, the driver on the FT232RL was not installed automatically, then download the driver for your OS from the FTDI manufacturer's website.

In the comments to the article, a person pointed out the possibility of a conflict between new drivers for the FT232RL from the manufacturer's website. In this regard, it is better to install the driver from the Arduino IDE (arduino-1.0.5-windows\arduino-1.0.5\drivers\FTDI USB Drivers)

Open the downloaded ID and select the board. The board will show up as Arduino NG or older w/ATmega 8 when using the ATmega 8 controller, or as Arduino NG or older w/ATmega 168 when using the ATmega168.

Then select the COMport to which the board is connected. My cable was determined under the ninth number.

To check the performance, we will fill in the test flasher program into the controller by doing the following:

After a successful download, you should see the following

If everything worked, then congratulations. You yourself have assembled a full-fledged USB Arduino clone.

The archive contains a template for LUT and a list of parts.

Open Image => Print => Full Page

To facilitate the desoldering of smd components on the reverse side of the board, where there is no marking, I will give a picture.

I would like to note that there are no rating markings on smd capacitors, but to facilitate desoldering in the picture, I applied them. 104 - 0.1 uF, 22 - 22pF.


We collected the best and even crazy Arduino projects that we met in 2015.

Arduino Wake Up Machine

Breaking Combination Locks with Arduino

This Arduino controlled mechanism can open any combination lock in less than 30 seconds. The project of hacker Samy Kamkar demonstrated the vulnerability.

Robot sorting Skittles

A project of a 3D printed Arduino robot that will help save the time it takes to sort Skittles. Perhaps the biggest disappointment is that the mechanism is not universal and suitable for M&M's. Video and more detailed description

Protopiper - gadget for prototyping

Amazing gadget for prototyping. Tired of running with a roulette wheel? With this device, you can quickly sketch out a sketch the size of a room.

Open source snow blower

The engine of progress in many cases is laziness. Remove snow with a shovel? This job requires a robot. Perhaps snow blower salesmen will not like this project, because. The author believes that everyone can independently make one for themselves. .

Blaster to switch music

Everyone has different musical tastes. But sometimes the music is just awful. Nobody in the company likes her. It happens. If your dream and such moments is to shoot a gun and change the music... then know that the project is realized, dreams come true.

Give your hair more power

Discreetly send messages, launch applications, broadcast your location - all this can be done by gently stroking your hair - this is so natural for girls.

Knit with Arduino

To knit, it is not necessary to contact your grandmother or buy professional equipment. DIY robot that knits using Arduino.

Robot BB-8 on Arduino

A project for those who dream of making a BB-8 robot from Star Wars.

Ok Google Sesame open the door

In this project, an MIT student implemented a door opener using a Google Now voice command. To get into the house, you just need to say: "Sesame, open." Video and project description.

Typewriter playing a symphony

The typewriter of 1960 has become not only a printer, but also a musical instrument.

Robot AT-AT

Controlled robot AT-AT from Star Wars.

Robot T-800 from Terminator

There are a lot of Terminator movie fans in the world, but few have recreated the T-800 robot. You can read more about the project and watch the video.

Egg Minion Robot from Kinder Surprise

A fun homemade robot that you can make yourself. More about the project.

Control your TV with your mind

The TV remote is no longer needed. All you have to do is think about changing the channel. The project used a chip from the game Star Wars Force Trainer (Star Wars), released in 2009. Read more.