Albert Einstein

Albert Einstein
My inspiration....

Pages

Search Box

Custom Search

Search Result Place

Serial COM port using ATmega8 (AVR Dude Hack)

Introduction:
Many times, I have written code for UART communication and when it came to testing, my laptop does not have a serial port. I bought a USB to serial port converter but it didnt worked. I felt frustated and finally thought of buying a Serial to Com port module in an electronics hobby store. After seeing that I got the idea of making one myself. I have 2 USB AVR Programmers with me. I tried different circuits but they didnt worked for Windows 7 because of driver problems. I googled for the circuit and finally came to know that the circuit of USB Programmer and USB to Serial port are both same. I just have to connect some wires in the programmer and change the firm ware of the programmer and it became USB to Serial Converter! Voila! My laptop has a serial port now! 

There are other methods in internet, but you can only them in old PC's of with Windows 98 or XP. You will find support for high end operating systems like Windows 7. This circuit is tested and it is working 100%. I started using COM port for all my projects because you can give different inputs and debugging became even more simple using serial port.

Click here : http://www.recursion.jp/avrcdc/cdc-232.html
In the above link you will find the details of the circuit. You can build the circuit using ATTiny45 or ATTiny2313 or ATmega8. But the baud rate speeds will vary depeding upon the device you use.
Circuit Diagram:

Circuit Building:
First build the whole circuit using any of the 3 MCU's. You will find the firmwares in the website. Choose CDC32 from here..
http://www.recursion.jp/avrcdc/download.html
Flash the microcontroller using the firmware. You will have seperate firmwares for different MCU. After that connect the circuit to the USB port. The PC will not recognise your driver. Download the driver depending upon your operating system. The best part in this method is that it supports all operating systems including Windows 7. Install the driver manually in device manager options. For checking the working of circuit, just connect Tx and Rx pins with a wire. Open the terminal and type something, you will see the same thing on the screen. 
My USB to Serial Converter: 
I have built this and connected to my development board. Previously it is a programmer, now it became USB to Serial port to my laptop. I am going to build this using ATTiny45 once I get the chip. But the maximum baud rate with ATTiny45 is only 4800bps as per the circuit. I will post those pics once I finish building the circuit. So keep waiting for my updates.



I have tested this circuit and it is 100% working. You you have any problems building this circuit or with firmare or drivers, post your problems, I will surely help you out.
Click here for sample project after building this circuit.


I will be updating this post regularly, so subscribe to my blog newsletter(top right of this page) for updated information. If you have any doubts, post you comments here or mail me @ arifuddin2007@gmail.com 

Arifuddin Sheik

6 comments:

Anonymous said...

I would like to exchange links with your site arif-ece.blogspot.com
Is this possible?

arifuddin said...

what links you want to exchange. send details to my mail

arifuddin2007@gmail.com

Anonymous said...

Nice post and this enter helped me alot in my college assignement. Gratefulness you as your information.

mithun said...

just linked this article on my facebook account. it’s a very interesting article for all


BE ECE Projects

Power Point Presentations said...

I have been reading a lot on here and have picked up some great ideas. You are so inspirational. Wished I would take the time to write my own blog – but I’m afraid I’m not persistent and nobody would read it anyway ) – so I keep coming back and enjoy your stories
Electrical Engineering

dinesh kumar said...

hi sir i need your help i have a doubt for this usb to uart using atmega whether we need any program please kindly reply to my mail id dinesh.beece.2013@gmail.com

No of times page visited

CONNECT WITH FACEBOOK

Newsletter

Followers

Recent Posts

Blogger WidgetsRecent Posts Widget for Blogger

About Me

My photo
Visakhapatnam, Andhra Pradesh, India
I am graduate from Swarna Bharathi College of Engineering in Khammam, Andhra Pradesh, India. Currently I am doing a business. After seeing the response to my blog, I am planning to start my old electronics geek work again. Now I have got more funds and I am planning to do some creative projects. Thanks for all those who encouraged me for doing this wonderful job.