Electronics

Programmer Atmega16/32 Minimum programming Socket System

AED 31.50

Low stock
1

Description

For the Atmega16 and Atmega32 learners, this socket board will gonna be a great help and time saver, which you don't let you reassemble the basic circuit for the Atmega16 or the atmega32 every time you want to make a circuit, all you have to do is just insert the chip into the socket and you are ready to use any USBasp programmer to program the MCU, crystal, Rest button, power line capacitors and 2 LED ready and connected to the MCU, the LEDs are D1 Power indicator and PD2 Program Run indicator.


Note: the Atmega16/32 is not included, and to program the MCU you need to buy the USBasp Programmer separately from here.


for All AV



Specifications:

  • 32 I/O pin headers ready to use without a breadboard.
  • Crystal:  8MHZ crystal you can change by desoldering it and change it to 16MHz or 12MHz crystal.
  • supported AVR MCU Versions: ATmega16/ATmega32 or any pin-compatible MCU
  • Power supply: power adapter or external expansion pin power supply (not support ISP download interface power supply)
  • DC-005 Power Connector 5.5*2.1mm 
  •  4 VCC, GND pin headers
  • Reset: Reset button ready to use
  • LED Power  indicator (D1) and program run indicator (D2)
  • a standard ISP pin header interface to connect any USBasp Programmer

  Now let's start by  Blinking an LED Tutorial with ATmega32, . We are going to blink the LED at half a second rate.






The resistor is connected here to limit the current drawing from the LED. Remember, the controller can not provide more than 30mA at the terminals.

Programming Explanation

The program for the ATmega32 microcontroller to blink an LED is shown below. The comments in the code explain the purpose of the individual line of the code.

#include //header to enable data flow control over pins

#define F_CPU 8000000 //telling controller crystal frequency

#include //header to enable delay function in program

int main(void)

{

DDRD = 0xFF; // ( or 0b1111 1111) In AVRSTUDIO for telling the controlling to use a certain bit of

//a port as input we use “ZERO”, for telling it to use a certain bit as output we use “ONE”. Since we put eight “ONE’s”,

// all the pins of PORTD are enabled as output. If we put a zero as “0b1111 0111”, now all the pins 0,1,2,4,5,6,7 are enabled

//as inputs and PIN 3 is Enabled as input.

while(1) // loop goes on forever and the LED will be blinking forever

{

PORTD = 0xFF; // all pins of PORTD are said to provide 5v output or told to pull high (LED ON)

_delay_ms(220); //delay for 200ms

_delay_ms(220); ); //delay for 200ms

PORTD = 0x00; // all pins of PORTD are said to provide ground at output or pull down

_delay_ms(220); ); //delay for 200ms

_delay_ms(220); ); //delay for 200ms

}

}