Tuesday, September 11, 2018

Tutorial 4

Hello guys. In this tutorial I am going to show you the connection between Atmega8 and USBasp. USBasp comes with FRC (Flat Ribbon Cable), which has 10 pin connector normally as shown below.
The pinout of the connector is shown in the below image. If you have 6 pin connector, follow the diagram of 6 pin connector,
Now again lets have a look at the pin out of Atmega8
You will notice that the pins marked in red rectangle is same as the pins of the connector of FRC cable of usbasp.

You next step is to put Atmega 8 in the breadboard and connect the marked pin to the usbasp FRC connector using jumper wires. VCC of connector goes to VCC of Atmega8, GND goes to GND, MOSI goes to MOSI, MISO goes to MISO , SCK goes to SCK and RESET goes to RESET.

After making this connection, Plug you usbasp to your PC. In the next tutorial, I will show yoy how to transfer a program to the Atmega8. Thankyou.

Sunday, September 9, 2018

Turorial 3

Now we have our Atmega8 with us, next we need a hardware commonly called as programmer to estabilish a communication between our PC and Atmega8. There are lots of programmer available in the market today. Some of the famous programmers are USBtiny, USBasp, Arduino etc, (Arduino can also be used as programmer). In my tutorial series, I am going to use USBasp programmer because it is cheap and easy to use. The link for usbasp is given below you can purchase from there.




Next we need to install the driver for this usbasp programmer. Down and install the driver from here.

Check whether your PC is detecting usbasp or not. I am using windows OS. Plug in your usbasp to the usb port of your PC and go to device manager and under universal serial bus, you should see "usbasp". If  you are not getting usbasp, it means some files are missing in the driver. If you are facing a problem like you windows is not recognizing usbasp click here  Download and install the software. After installation, open the software, plugin your usbasp to you PC, Select usbasp from the dropdown menu, Select driver and click install as shown below.
Now your PC should recognize the usbasp programmer.

So, in this tutorial we have chosen usbasp as our programmer to make communication between our PC and Atmega8. In the next tutorial, we are going to make connection to Atmega8 and usbasp. Thankyou.


Friday, September 7, 2018

Tutorial 2

Hello everyone. This is the first tutorial in our AVR tutorial series.  in the last tutorial we came across a term called microcontroller. Now we are going to explore  one of the microcontroller family called AVR. This microcontrollers are developed by atmel company. Atmel develop a wide variety of microcontrollers from small to big so that user can choose any of the microcontroller according to his application. For more details on AVR microcontroller types click here.

In this tutorial series we are going to use atmega8  microcontroller. As I have already said that it does not matter which microcontroller used choose all the basic principle behind each and every microcontroller remains same.

Atmega8 microcontroller is shown below.

It is an 28 pin IC(Integrated circuit). every microcontroller needs power therefore out of these 28 pins,  at least two pins are for giving power to the microcontroller.  arduino microcontroller can control many devices, many  sensors therefore some of the 28 pins are used to communicate with the outer world, these pins are called input output pins or GPIO (general purpose input output) pins. Some pins of the microcontroller are used to communicate with other digital devices. This is the reason why a  microcontroller has so much pins. The complete details of at mega 8 microcontroller is given in a document called its data sheet you can download the data sheet of at mega 8 microcontroller by clicking here.

Just have a look at the data sheet, don't worry if you do not understand  anything from it, this is the reason why I am creating my tutorials.  let's move forward, so we have seen that make it microcontroller its pinout and its data sheet.

So now we have a microcontroller,  next you will need some hardware. By which AVR microcontroller can communicates with our PC or laptop.  in my next return I will show you which hardware can be used  and how it can be used.  see you then keep smiling.




Thursday, September 6, 2018

Tutorial 1

Hello every one, I hope you all are doing great. I started this blog to help me and others like me, to learn and understand the exciting world of AVR micro-controllers.

I will try to keep the things as simple as possible.

A micro-controller is just a silicon chip that can do whatever we ask it to do.



In PC we write instructions  that we want our micro-controller to do and then we transfer these instructions to our micro-controller and micro-controller starts following our instruction. This is called programming the micro-controller. In simple word programming a micro-controller means telling the micro-controller to do the task. We just write these task one by one and put that in the brain of micro-controller.


There is a wide variety of micro-controllers available in the market today from different different manufacturers, The basic principle of programming each an every micro-controller is same "We write the task and put that into the brain of micro-controller". It really doesnot matters which micro-controller we start learning, all the basic principle are same in every micro-controllers.

I will not go in the conventional theoritical way to learn something interesting. Conventional way is boring :). We will learn in a practical way. Lets make a list what we all need to program a microcontroller.
1. A PC or a laptop to write the instructions (called program).
2. A Micro-controller
3. Some hardware to connect our micro-controller to PC. Some LEDs, resistors, etc.


 I will tell the exact list in my next tutorial. Till then keep smiling.







Tutorial 4

Hello guys. In this tutorial I am going to show you the connection between Atmega8 and USBasp. USBasp comes with FRC (Flat Ribbon Cable), w...