8051 Microcontroller Projects AVR PIC Microcontroller Projects Tutorials Ebooks Libraries, interfacing tutorials, lcd tutorial, stepper motor, dc motor 8051 assembly language programming electronics and communication ECE CSE pdf ebooks library BE final year project ideas Embedded systems

 
8051 microcontroller 8051 microcontroller
Forums

8051 Microcontroller Projects AVR PIC Projects Tutorials Ebooks Libraries codes :: Forums :: Discuss and Learn :: AVR Discussion Forum
 
<< Previous thread | Next thread >>
serial communication for AVR microcontroller
Go to page  [1] 2 3
Moderators: Ajay, Junied , abbas1707, Arun Kumar V, pdi33, Shailesh NAYAK, ۞ TPS ۞, shyam, sashijoseph
Author Post
ece
Wed Mar 12 2008, 09:57PM
 User Offline
Registered Member #3950
Joined: Tue Sep 11 2007, 06:55AM

Posts: 13
Thanked 0 times in 0 posts
we are working on project controlling of stepper motor through AVR microcontroller using serial communication.in that as a part of testing we are to transmit any one bit data and receive same bit.we are using AVR STUDIO4 software.pls guide us with instruction of serial communication as soon as possible

Back to top


abbas1707
Thu Mar 13 2008, 02:12AM

 User Offline
Registered Member #383
Joined: Thu Jan 25 2007, 08:07AM

Posts: 413
Thanked 63 times in 51 posts
check AVR serial tutorial

A Thousand Miles Journey Starts With a Single Step.
Back to top


ece
Thu Mar 13 2008, 04:15AM
 User Offline
Registered Member #3950
Joined: Tue Sep 11 2007, 06:55AM

Posts: 13
Thanked 0 times in 0 posts
we have already gone through it and we made program by reffering that but it is not working for transmitting and receiving a bipls,send proper program for that.
Back to top


Ajay
Thu Mar 13 2008, 10:17AM
Rickey's World Admin

 User Offline

Registered Member #1
Joined: Fri Feb 24 2006, 04:56AM

Posts: 3315
Thanked 611 times in 578 posts
which AVR you are using?

www.rickeyworld.info
If you feel satisfied with the user's forum reply please click on the thank button.

Obey forum rules!
Respect others!
Back to top


ece
Sun Mar 16 2008, 10:42PM
 User Offline
Registered Member #3950
Joined: Tue Sep 11 2007, 06:55AM

Posts: 13
Thanked 0 times in 0 posts
AT MEGA32.
Back to top


ece
Mon Mar 17 2008, 03:07AM
 User Offline
Registered Member #3950
Joined: Tue Sep 11 2007, 06:55AM

Posts: 13
Thanked 0 times in 0 posts
actualy we have to send and recieve a bit through port D of AT MEGA32 i.e on port D.0 and port D.1 we are not getting wat to do for program how to write.pls guide
Back to top


abbas1707
Mon Mar 17 2008, 11:13AM

 User Offline
Registered Member #383
Joined: Thu Jan 25 2007, 08:07AM

Posts: 413
Thanked 63 times in 51 posts
why D.0 and D.1 ?? you can do it on any pin... just send them/ receive serially

A Thousand Miles Journey Starts With a Single Step.
Back to top


Ajay
Mon Mar 17 2008, 12:18PM
Rickey's World Admin

 User Offline

Registered Member #1
Joined: Fri Feb 24 2006, 04:56AM

Posts: 3315
Thanked 611 times in 578 posts
abbas, PD.0 is RXD and PD.1 is TXD..

can i see your code ece..?

www.rickeyworld.info
If you feel satisfied with the user's forum reply please click on the thank button.

Obey forum rules!
Respect others!
Back to top


ece
Mon Mar 17 2008, 10:21PM
 User Offline
Registered Member #3950
Joined: Tue Sep 11 2007, 06:55AM

Posts: 13
Thanked 0 times in 0 posts
Here is our program.pls check it and make the necessary changes.

CODE:
.include"m32def.inc"
.def reg1= r16
.def reg2=r17
.def reg3=r18
.def reg4=r19
Serial_Init:

ldi reg1,00
out UBRRH,reg1
LDI reg1,25
OUT UBRRL,reg1

ldi reg4,( 1<<RXEN)|(1<<TXEN)
out UCSRB,reg4
//ldi reg1,00
ldi reg1,(1<<URSEL)+(1<<USBS)+(3<<UCSZ0)
OUT UCSRC,reg1

//sbi UCSRA,RXC

USART_Transmit:


sbis UCSRA,UDRE
rjmp USART_Transmit
ldi reg1,0XFF
out UDR,reg1

sbi UCSRA,TXC

USART_Receive:
sbis UCSRA,RXC
rjmp USART_Receive
in reg3,UDR
out PORTA,reg3

ret
 


[ Edited Mon Mar 24 2008, 11:41PM ]
Back to top


sashijoseph
Tue Mar 18 2008, 09:06AM

 User Offline
Registered Member #5870
Joined: Mon Feb 04 2008, 06:26PM

Posts: 471
Thanked 106 times in 101 posts
What clock are you using?

Let there be music........
Back to top


Go to page  [1] 2 3  

Jump:     Back to top

Syndicate this thread: rss 0.92 Syndicate this thread: rss 2.0 Syndicate this thread: RDF
Powered by e107 Forum System

8051 Microcontroller Projects 8051 AVR tutorials PIC microcontroller, 8051 assembly language programming electronics and communication ECE CSE pdf ebooks library BE final year project ideas Embedded systems