Microcontroller Introduction
Microcontroller Introduction
• Co u r s e Co d e : C S E 4 2 5
• M i c ro co nt ro l l e r
• St u d y of Em b e d d e d sys t e m
• Co m p u t e r Pe r i p h e ra l s
• Int e r f a c i n g Prot o co l s
• Pro g ra m m i n g
Course Objecti ves
• Le a r n i n g Mi c ro co nt ro l l e r
• Le a r n i n g Pro g ra m m i n g fo r M i c ro co nt ro l l e r
• Le a r n i n g e n o u g h t o p l a n a b o u t a Pro j e c t
• Ma k i n g a Dev i ce
• Le a r n i n g h ow t o Pro g ra m a s p e c i fi c D ev i ce
• Ru n n i n g yo u r OW N M A D E d ev i ce
Course Planning
Introducti on to Microcontroller
A m i c ro co nt ro l l e r (s o m e ti m e s a b b rev i at e d µ C , uC o r
M C U ) i s a s m a l l co m p u t e r
o n a s i n g l e i nt e g rat e d c i rc u i t
co nt a i n i n g a p ro ce s s o r co re , m e m o r y, a n d p ro g ra m m a b l e
i n p u t /o u t p u t p e r i p h e ra l s .
It c a n o n l y p e r fo r m s i m p l e t a s k .
A m i c ro co nt ro l l e r i s oft e n d e s c r i b e d a s a ‘co m p u t e r- o n -
a - c h i p’
Would you believe that each one of you is
using at least 20 microcontrollers in your
house?
So exactly where can microcontrollers be
founded, right?
How Does A Microcontroller Look
Like?
Microcontroller Circuits
Output
Programming for Microcontroller
• He a d e r F i l e
• Ma i n Pro g ra m Bo dy
• Us e r D efi n e d Fu n c ti o n s
• Va r i a b l e s
• Lo g i c Ma k i n g
• Lo o p Co nt ro l et c …
Programming for
Microcontroller
Header File
• AT M E L AV R 8 bi t & 3 2 b i t
• AT M E L A R M Ba s e d
• 8 0 5 1 A rc h i t e c t u re
ATmega
8
Pin Diagram of ATmega8
Pin Classification of ATmega8
28 PINS
5
Power Pins
Pin Classification of ATmega8
23
I/O Pins
ATmega3
2
Pin Diagram of ATmega32
Pin Classification of ATmega32
40 PINS
8
Power Pins
Pin Classification of ATmega32
32
I/O Pins
Peripherals
Electronic
Devices Sensor Display