Вы находитесь на странице: 1из 22

Experiment List of ST_13

Familiarizing with AT mega 16



Above shown is the pin configuration of AT mega 16 IC.
It is a 40 pin IC with Pin numbers starting from the left side of U-shaped notch.
Pin number 11 and 31 should be connected to ground.
Pin number 10 should be connected to +5 volts.
Pin number 32(AREF) and 30(AVCC) are shorted and connected to +5Volts.
Pin number 9(RESET) should be connected to +5Volts through a pull-up resistor as
shown below.
An indicator LED is also used with RESET pin.





Experiment 1:- LED interfacing with ATmega16

Part A: - To glow a visible LED Using AT mega 16
Connect a LED to any Pin of input/output Port (A,B,C,D) say PB0 of ATmega16
Connect the positive end (longer leg) of LED to the pin and the negative end
(shorter leg) to ground via a 220 ohm resistor as shown.

Program the IC to switch on and off the LED after certain time intervals.
In ST_13 Dev Board 8 linear LED arrays are provided that are internally
connected to PORTB of ATmega16.
Program the IC to display different LED Pattern Using the PORT B I/O pins.




Part B:-Seven Segment Display(SSD) interfacing.
Seven Segment Display is of two type (as shown in fig)

Common Anode

Common Cathode

SSD have 8 pin for internal 8 LED and 2pin (3 and 8) for VCC.

Just connect two 8 pin Relimate connector at two I/O ports and connect the SSD to its
lower nibble side.











Part C: - 8x8 LED DOT Matrix Interfacing.
I3indya 8x8 LED matrix have one row pins and eight column pins.
For interfacing we need two PORTS one for row and one for column.
The DDR registers of both the ports is to be made as output.
For selecting a row we give 1 to that row pin and 0 for deselecting that row.
For selecting a column we give 0 to that column pin and 1 for deselecting that column
pin.
Following is the circuit Diagram.













Experiment 2:- To interface a 16*2 LCD with AT mega 16
Following is the circuit connection for interfacing a 16*2 LCD with ATmega16.
An 8 pin connector is provided on board.
Connect this connector to any I/O port of atmega16 using 8 pin connecting wire say Port
C.
Program the IC to display different character on LCD.
Actual connections for 16*2 LCD already done on Board
Note PORT X=C









Experiment 3:-DC motor control using Driver L293d:-

Connect any two I/O pins of atmega16 with the input pins of motor driver L293d i.e.,
Direction 1-A and Direction 2-A.
In ST_13 Dev Board PB.0, PB.1, PB.2 and PB.3 are connected internally to input pins of
L293d.
Connect enable pins (Pin no-1 and 9) and VCC1 (Pin no-16) with constant +5V and
ground as shown in fig.
Connect the output pins of L293d with the terminals of the motor.
Give +9V to VCC2 (Pin no-8).
Write a code to so as to make PB.0 high and PB.1 as low and note the direction of
rotation of motor.
Now interchange the connection and note the change in direction of rotation.
Now make both the pins as high (low) and observe the locking effect in motor.
In st_13 DEV board a slide switch is used so that we can also use PWM in motors.
In PWM mode both enable pins are connected to TIMER OC2 Signal. Hence we can vary
the speed of motor also.







Experiment 4:- Controlling Stepper motor using ATmega16

St_13 Dev Board has on Board ULN2803 IC to control the stepper motor.
Circuit Diagram for ULN2803 IC module is as below.
Connect 8 pin Input of ULN2803 to any I/O port of ATmega16.
As we are working with 5 wire stepper motor ,So we can control the stepper motor by
connecting it in OUTPUT of ULN2803 (10-PIN).














Experiment 5:- IR Sensor interfacing.

I3indya Dual IR Sensor can be used either in analog mode or digital mode.
A slide switch is given in sensor module to toggle between analog and digital mode .
By changing the value of variable resistor we can change the range of IR sensor.


In ST_13 Dev Board, six 3-pin connector is given to interface with IR sensor as well as
other sensors also.
These connectors are internally connected to PORTA (PA.0-PA.6) so that we can use
internal ADC of ATmega16.
Following is the circuit diagram of i3indya IR Sensor.





Experiment 6:- Interfacing Buzzer to ATmega16

Buzzer is used to make sound using microcontrollers.


Connect a Buzzer to any Pin of input/output Port (A, B, C, D) say PB0 of ATmega16.
Connect the positive end of Buzzer to the pin and the negative end to ground as shown.
Program the IC to switch on and off the Buzzer after certain time intervals.
In ST_13 Dev Board Buzzer is internally connected to PA.7 pin of ATmega16.


Experiment 7 :- Interfacing Keypad and Matrix Keypad.

Part A:- Using a key to operate an LED
Make the LED connection as in previous experiment.
Connect a reset switch to any input/output pin of AT mega 16 say PC0.
Connect one leg of switch to ground and the other leg to the pin pulled up by a 10k ohm
resistor (as shown)





Make PC0 as input pin and program the IC to control the LED with switch.
Similarly on board 8 linear LED can be controlled using a 4*4 keypad matrix provided in
ST_13.
Now integrates as many switches and LEDs as you want and glow them using switches
by making changes in program code.















Part B: - Interfacing a 16 Key keypad
Interface the given 16 key keypad to 8 pins of PORT X (x=A,B,C,D) of ATmega16.
Make connection to LCD with another PORT as done before.
Press the Keys of keypad one by one and obtain corresponding display on LCD.
In ST_13 Keypad matrix the 16 reset switches are connected in a square matrix fashion
with 8 output wires connected to an 8 pin male rellimate connector.












Experiment 8:- Interfacing RGB

RGB Led is used to produce infinite colors.
It has 4 legs as shown in fig.
InST_13 Dev Board we are using common Cathode RGB Led.
RGB Led is controlled by PWM of AT mega 16.
In ST_13 Dev Board pin no 1, 3 and 4 are connected internally to PD.4 (OC1B), PD.5
(OC1A) and PB.3 (OC0) of ATmega16 respectively.
Pin no 2 is connected to ground.

Note: - In ST_13 Dev Board 4 Pin Connector is used to interfacing RGB Led as shown in
fig.







Experiment 9:- Using External Interrupts

IN ST_13 Dev Board a switch is provided for providing a external interrupts.
This switch is connected internally to Pin PD.2 (INT0) of ATmega16 as shown in fig.
Write a program of pressing the switch in Interrupt Service Routine.

















Experiment 10:- Speaker interfacing using PWM of ATmega16.
In ST_13 Dev Board four connectors are provided to directly interface with PWM of
ATmega16.
These connectors are internally connected with OC0, OC1A, OC1B and OC2 pin of
ATmega16.(as shown in fig)
2 wire speakers can be directly interfaced to any of these connectors.
We can generate different type sound using PWM of ATmega16.





















Experiment 11:- DTMF Controlling

I3indyas DTMF Board can be used to control the devices using cell phone.
This DTMF Board is supported by all type of cellular phone.
DTMF Board has an audio jack to take input from cell phone using audio extension
cable.
It has 4pin output connector to interface with ATmega16 or motors directly.
It accepts power supply using on-board 2 pin connector.
It also has 5 indicator LEDs to analyze the output of DTMF IC (MT8870) (as shown in fig).












Experiment 12:- Relay interfacing to ATmega16

I3indyas Relay Board is used to control a circuit by a low power signal using switching
mechanism mechanically.
In this Relay Board two RELAYs are used.(as shown in fig.)
This relay board has 3 pin input connector which has to connect with output of ULN
2803.
NOTE: - 1
st
pin should be connected to power supply
There are two output connector through which, any external circuit can be controlled.
Two indicator LEDs are also given in board for respective RELAYs.








Experiment 13:- Touch screen interfacing to ATmega16.

Touch screen can be interfaced to atmega16 using ADC.
In ST_13 a 4-pin separate connector is given to interface with touch screen.
This connector is internally connected to four pin of PORTA (PA.0-PA.3).
I3indyas touch screen has 4 pin female relimate connector which can be directly
interfaced with atmega16s ADC (as shown in fig.)












Experiment 14:- USART Board interfacing to ATmega16.

I3indyas USART Board is used for serial communication between computer and
ATmega16.
This Board has on-board MAX232 IC and DB9 female connector.


In ST_13 Dev Board there is a separate 4 pin connector for interfacing with USART
Board.(as shown in fig.)
USART board has on-board 4-pin connector .Connect it to ST_13 Dev Board using 4 pin
female relimate connector.
We will have to use serial cable (USB to SERIAL) with adopter to make communication
between computer and ATmega16.





Experiment 15:- RF Module interfacing to ATmega16.

I3indyas RF Boards can be used for wireless communication.
There is separate board for transmitter and receiver.
Transmitter and Receiver Board have female connectors for interfacing with Tx and Rx
module respectively.


Both transmitter and receiver board have 9 pin DPDT switch to make addressing
mechanism i.e. both Tx and Rx should have same addressing to sustain communication.
Recover Board have 4 LEDs indicator.
Both Boards have 4-pin on-board connector which can be interfaced with any i/o pins of
ATmega16.














Experiment 16:- Power Supply

ST_13 Dev Board have on-board power supply module.
It have an voltage regulator IC(7805) which give +5V output.
It has some capacitors to remove unwanted oscillation in supply.


We are using 9V adopter to provide external supply to Board.
Also there is 2 pin connector so that we can also use batteries.
There is 6-pin DPDT switch which is used to toggle between supply of USBasp
programmer and External supply.

Вам также может понравиться