Questions tagged [avr]

AVR is a 8- and 32-bit microcontroller core developed by Atmel. AVR was chosen as microcontroller for the first generations of the popular Arduino SBCs.

Atmel uses the AVR core in both 8- and 32-bit microcontrollers. All AVR devices use a modified Harvard architecture and a RISC core, and have a (near) 1 MIPS/MHz performance. None can execute code from external memory or RAM. The series includes the ATtiny, ATmega, ATXmega, and AVR32 controllers. The Arduino development board uses an ATmega32.

See also Atmel's homepage and the Wikipedia page.

This tag should be applied to questions which involve the issues specific to AVR microcontrollers. It need not be applied to all questions which involve an AVR, for instance, questions about work within the Arduino environment should receive the tag.

What does AVR stand for? According to Wikipedia:

Atmel says that the name AVR is not an acronym and does not stand for anything in particular. The creators of the AVR give no definitive answer as to what the term "AVR" stands for. However, it is commonly accepted that AVR stands for Alf (Egil Bogen) and Vegard (Wollan)'s RISC processor.

related tags:

1898 questions
8
votes
3 answers

What do PA and PU mean in AVR lingo?

My Google-fu is letting me down today. What do PA and PU mean in ATmega88PA and ATmega8-16PU? If P for PDIP what is A and U, then?
Peter Mortensen
  • 1,679
  • 3
  • 17
  • 23
5
votes
1 answer

What is a "touch channel"?

Among the ATmega328 "key parameters" is listed: # of Touch Channels: 16 What does this number refer to?
Andreas
  • 723
  • 2
  • 13
  • 21
5
votes
2 answers

USIBR loses the MSB of the received byte in ATtiny45/85 of AVR family

Update: Dec.06.2017 I've just received an answer from Microchip for this bug report. They also could reproduce this symptom and they will inform me about their further investigation. Original question: I often use the Parallel port (D-Sub DB-25…
5
votes
2 answers

Why bother using RESET# line on AVR?

I am designing a simple AVR development board based on the ATmega1284-pu and was wondering if there was any reason to use the RESET pin on an ATmega chip to reset it? Why not just cut the power to the device and then turn it back on? (The ATmega…
Billylegota
  • 164
  • 5
4
votes
3 answers

Variable Frequency on AVR Chip?

I am looking at programming an AVR chip as a possible avenue due to some problems I'm having with 555 circuitry, but I need to be able to adjust the frequency on the fly with a pot. Is it possible to setup an AVR chip with variable frequency so…
JamesHoux
  • 891
  • 12
  • 28
4
votes
1 answer

Half voltage on output pin under load?

I'm working with an ATTINY26(L) learning about interrupts, and discovered a problem. I am getting a different output voltage on PORTA (half) than I am on PORTB. To simplify things, I made a program to turn on a single LED on a given pin. I've tested…
JYelton
  • 34,119
  • 33
  • 145
  • 265
4
votes
3 answers

AVR: disassembler with named-register support

Is there a AVR disassembler which produces human readable output, e.g., writes OUT SREG,R0 instead of OUT 0x3F,R0 (I would like to get a better understanding of what the compiler is doing.)
Mike L.
  • 221
  • 3
  • 8
4
votes
2 answers

Do you still need the capacitors to ground on the XTAL pins on an AVR if the internal resonator is used?

When you use a crystal as the clock you use a pair of capacitors on xtal1 and xtal 2. Do you still need them if you're using the internal resonator?
Ageis
  • 3,353
  • 14
  • 45
  • 67
3
votes
1 answer

AVR (attiny24) resets itself driving more than 5 outputs under no load

I have the blink code below running on an attiny24 with the default fuses, via Atmel Studio 6. If I set DDRA to any combination of 5 pins (or set DDRA to 0xFF and then blink by setting PORTA to any combination of 5 pins) then it works but as soon…
dibnah
  • 41
  • 3
3
votes
1 answer

Sleeping an ATtiny

I've seen several code examples of sleeping an AVR where they do this: while (1) { // Business logic goes here set_sleep_mode(SLEEP_MODE_PWR_DOWN); sleep_enable(); sleep_cpu(); sleep_disable(); } Now, my question is, why are…
David Högberg
  • 1,835
  • 2
  • 22
  • 34
3
votes
2 answers

Which AVRs are pin-compatible with the ATtiny2313?

Until the 4kb upgrade to the ATtiny2313 is available, which AVRs can I substitute when the ATtiny2313 is too tiny?
joeforker
  • 5,656
  • 10
  • 40
  • 59
3
votes
1 answer

AVR Pointer Atomicity

On the AVR XMEGA, or any AVR, is it safe to do pointer operations, like passing by reference and accessing pointers while interrupts are on? I keep feeling like I need to wrap each pointer operation into an ATOMIC_BLOCK() macro. Is this necessary?…
zacharoni16
  • 677
  • 1
  • 9
  • 25
3
votes
2 answers

Mysterious ~1Hz oscillation in audio output

I'm trying to create a simple audio circuit that is able to output a sine wave at an audible frequency. I'm using an atmega328p for this because I'd like the frequency pattern to be programmable in software. It is working mostly correctly except for…
Greg
  • 31
  • 1
3
votes
2 answers

AVRISP MKII does not appear in AVRStudio 4 (latest build 4.18 SP1)

I have a AVRISP MKII that I wish to program avr chips with through avrstudio 4 with. However on the "select platform" the only think that resembles MKII is JTAGICE MKII which is not what I have? Am I missing something here? When I plug in the…
ril3y
  • 571
  • 1
  • 6
  • 14
2
votes
1 answer

Why does this circuit ruin my AVR?

I have the following circuit attached to my ATTiny13A. More specifically, attached to its PB1: I'm doing this to initialize the port: //init DDRB |= (1<
Daniel
  • 949
  • 10
  • 22
1
2 3 4 5