My Circuit run Perfectly in Protues.
but in practicality not working :(
what can i do?
শূন্য - The ZeRo
Of course it doesn't work - you're missing a few parts.
Max232 for rs232
No such thing as an internal crystal - there is an internal rc oscillator that is not too stable.
Just like the millions before you that have had the same problem - what baud rate and what are your fuses set to?
Have you verified how fast your AVR is running?
If you are serious about using UART then don't mess about. Buy a baud rate friendly crystal and two capacitors to accompany it.
But if you are to stick with the internal 8MHz your fuses have selected then at least read out the 8MHz calibration value and load it into OSCCAL when the code starts so it will at least be closer to 8MHz.
Your wasting your (and our) time trying to do serial comm with out an accurate clock source! Add a xtal and two caps, set the fuses and be happy.
(Possum Lodge oath) Quando omni flunkus, moritati.
"I thought growing old would take longer"
14.7456MHz is a good crystal for a 16MHz avr. Try half that for 8MHz? Or get a newer mega88 that will run on a faster clock. Mega8 is ok for research, experimenting.
Imagecraft compiler user
8 Mhz rc will work correctly with 9600, the only thing to do is crossing TXD/RXD, and of course ttl-level serial converter.
AVR UART lib
© 2021 Microchip Technology Inc.