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

learn more… | top users | synonyms

0
votes
0answers
14 views

Can manage to read device ID from an AVR only once?

I'm using an ATmega48 device and my debugger is the Atmel ICE. I manage to connect to the device only once, the 2nd time causes a "failed to enter programming mode" error. Cycling power to the device ...
2
votes
2answers
202 views

How can I bind a local variable to AVR's rXX register?

I need to have programmable pause with precision as high as possible. To accomplish this I have the following GCC code: ...
0
votes
0answers
35 views

Determining temperature using lm35 with avr MCU (program debugging) [on hold]

This Program converts the analog input from LM35 into binary outputs: ...
0
votes
1answer
51 views

Can some pins of the same port on AVR MCU's be declared as inputs and some as outputs?

Can some pins of the same port of AVR MCU's be declared as inputs and some as outputs? If yes, then I am not able to understand how this works since we have to compare the pins of the port and also ...
0
votes
1answer
37 views

AVR SPI slower than expected

I'm running an ATMega88A at 8MHz and have the SPI configured to run at Fosc/2 = 4MHz. In theory, shifting out 5000 bytes over SPI should take 1/4000000 * 8 * 5000 = 10ms. But according to the ...
1
vote
1answer
23 views

AVR SPI2X has no effect

I've got an ATMega88A configured to run on internal 8MHz clock: lfuse = 0xE2 hfuse = 0xDF efuse = 0x01 F_CPU defined as 8000000 This in confirmed in the 'real ...
2
votes
3answers
155 views

AVR SRAM limitation

I'm just an enthusiast looking for some advice. I'd like to use a microcontroller to read frames from a camera and write those frames to a small LCD screen. The camera and screen are on the same SPI ...
1
vote
1answer
32 views

ATmega 23K256 SPI RAM and ISP together

I want to connect 23K256 SPI RAM to ATmega. Do ISP programming will work together with SPI RAM connected. Thanks.
1
vote
1answer
91 views

I2C protocol debugging using oscilloscope

We are testing an I2C accelerometer connected to the ATMega32A micro-controller. The accelerometer was working fine. We can write and read the registers using I2C protocol. When connected to the ...
0
votes
0answers
23 views

Eclipse AVR Plugin: Broken pipe error

I am trying to get away from the Arduino side of life and get into AVR's. I work on a mac as my main development system. I have followed two tutorials on how to set up Eclipse for programming AVR's. ...
0
votes
1answer
47 views

Choosing between internal oscillator and external crystal- ATXMega32E5

We are working with a modern microcontroller ATXMega32E5, from the ATMEL XMega family. Our aim is to use the UART of the controller for effective communication, with the speed of about 9600 or 4800 ...
6
votes
1answer
57 views

Millis versus centis on AVR platform

I am building a device on the AVR platform. The device will need some timing information, so I was thinking of reimplementing Arduino millis-like functionality ...
1
vote
1answer
53 views

ATmega328A UART: everything working, but not as expected

I am trying to get UART working via the ATmega328A. I want to enter a character, and get that character to be printed out. However, when my code is run this is what happens: I enter one character, ...
0
votes
1answer
89 views

Best microcontroller for industrial applications [closed]

I have an industrial project requirement to build a device having this functionality: Store Data Send Data to Web Server Device to be placed under scorching sun Sensors - around 5 A Graphical ...
2
votes
0answers
51 views

What happens to AVR registers during multi-cycle instructions?

This is more of a theoretical question... (Also my first on Stack Overflow) I am wondering what happens to Atmel AVR microcontroller (i.e. ATTINY85) registers during a multi-cycle instruction. i.e. ...
1
vote
1answer
91 views

SPI not working, ATmega328 only sending 1 byte

I am trying to get SPI working on an ATmega328. This is my code: ...
1
vote
1answer
35 views

Cannot program ATTiny85 fused for 32 kHz

Now, I know what you're thinking. I've been thinking it all night too. Yes, I know that with the tiny fused for a 32 kHz crystal that I'll need the SPI clock to be 8 kHz or less. Even that, however, ...
1
vote
1answer
15 views

How to drain power with pins for led matrix on atmega32 instead of using a led driver

I want to make a led driver without the tlc594 series. I use the atmega32 of which I can use 1 PWM pin. The PWM pin will be connected to the base of the transistors. With the PWM pulse I can dim the ...
0
votes
2answers
61 views

How do I simulate a physical push button from an AVR

I've been messing a bit with EL wire that I purchased from amazon, I dissected the control unit and it appears to consist of a transformer, timing circuits(s) and a push button. When you push the ...
0
votes
0answers
18 views

Anyone experienced not being able to debug on AVR Studio 6?

I have a small C project with an ATTiny MCU, when I enter debug mode the dis-assembly window shows NOP for all lines and I can not step in the code... entering "0x0000,prog" in the address field does ...
0
votes
3answers
92 views

2 Digit 7 Segment Display Driver

I need to display the temperature acquired by my LM35 on a 2 digit 7 segment display. What I have is LTD383-R2 Common Anode Display. Datasheet here. The display has 1 Anode pin + 14 Cathode pins for ...
1
vote
1answer
31 views

Can avrdude address individual usbtiny programmers?

I'm envisioning a panel programming jig. In my mind, it consists of a Raspberry Pi, a powered USB hub, and a collection of usbtiny clones each connected to a pogo jig and a target on a panel. The ...
0
votes
0answers
61 views

I2C interfacing with ATmega32 and ArduinoMega2560 failed

I'm trying out I2C interfacing the ATmega32 with Arduino Mega2560 Board without success. The Arduino Board is configured to be the Master Read. The Atmega32 is configured to be the Slave Write. I ...
2
votes
4answers
135 views

Driving an LED from a uC pin with the Anode above uC's Vcc rail

I am using a 3.3V uC (ATMega 328p in Arduino Pro Mini) running from 3 alkalines (nominal 4.5V). So Vin=4.5V, Vcc=3.3V I'd like to drive LEDs from some pins, say at 20ma each. And I was thinking to ...
1
vote
2answers
68 views

AVR main loop interference with relay

I'm working on a test program on an ATmega164A that toggles a 12V relay on and off (with no load) through a ULN2003A. For my test program, I'm toggling the relay at 100ms. I've got an IN4001 diode ...
2
votes
1answer
99 views

AVR simple bootloader - how to call application code?

I am using the atmega328. I want to create a simple test application using a bootloader. I want to: Blink an led at one speed in the bootloader section of flash, and then blink at another speed in ...
0
votes
0answers
71 views

SPI always returns null while reading

We need some help in SPI protocol. We've been using an AVR microcontroller ATMega324PA (DIP) and an ADXL344 accelerometer (QFN Breakout). Both chip operates at 1.8V and supports I2C & SPI. Lately ...
1
vote
1answer
40 views

Is it possible to power target microcontroller from AVRISP mkII using Atmel Studio

I'm using the Atmel Studio IDE and a AVRISP mkII to program microcontrollers. I've always powered the microcontrollers to be programmed with an external power supply but I was wondering if it is ...
1
vote
4answers
279 views

Rotate a 7-segment display in firmware

I have a board with a 7-segment display controlled by an AVR. I need to rotate the display's characters in the firmware, so that the display is read correctly when physically rotated 180 degrees. ...
2
votes
2answers
90 views

AVR microcontrollers, who initilizes assembly `data` segment and what is the purpose to have this directive?

I am new to assembly and microcontrollers and am trying to figure out how they work. Now, I have read a lot how in assembly text and ...
2
votes
1answer
77 views

AVR external crystal not working with UART

So I have an ATmega328P with a 14.7456MHz external crystal, full-swing settings, and I'm trying to talk to my mac via UART and an FTDI friend-type device. If I connect AVR Tx to AVR Rx, then all ...
0
votes
1answer
105 views

Daisy Chaining ADC Sensors

I'm creating a grid of 200+ pressure sensors and need a clean way to get their values back to the master controller without a mess of wires. To me it seems like daisy chaining all the sensors ...
4
votes
2answers
258 views

Sink or source from AVR

I've been (re)learning microcontroller programming using AVR ATinys (13/45/85). One reference on digital outputs said that I should sink outputs, but nearly all of the circuit examples I've seen ...
2
votes
0answers
73 views

32-bit unsigned binary integer to 8-bit BCD in AVR ASM for ATtiny. How to make it more efficient?

I wrote a program in AVR ASM for converting 32-bit unsigned binary numbers to 8 digit ...
0
votes
0answers
47 views

I2C slave is not acknowledging for SLA+W but values can be read from/write to registers

We got a wierd problem in a I2C device. We've been trying to solve the issue for more than a week now. This post is about ADXL344 Digital Accelerometer from Analog devices. We made three prototype ...
0
votes
1answer
78 views

ATmega 328P SMD version

Currently I am using the normal ATmega328P chip with my barebone Arduino I have made. I am planning to switch it with an SMD version of ATmega328P, since it's smaller in size it will consume less ...
0
votes
1answer
46 views

Measuring pulse length with ICP

I am trying to measure pulse length, with ICP (input capture pin) on Atmega8, coming from this circuit:. PINB0 is ICP pin on AVR. This is (most of) the code: ...
2
votes
1answer
91 views

AVR long int calculation error

I'm having some trouble with a function( void CheckSum() ) for a checksum calculation. The problem is, that when I call up that function inside another function called ICMP_Frame(), it works fine. ...
1
vote
1answer
99 views

AVR Input not reading correct value

I feel like this is a true beginners problem, but I fail to see what I am doing wrong here: I have a SIP switch connected to port A of an Atmega32 and I cannot read correct values from the port. Here ...
0
votes
2answers
41 views

Low power ripple pulse counter

I'm trying to find a ripple/pulse/edge counter chip that can record rising edges from a wind anemometer while my AVR sleeps. The signal is typically 0-50 Hz. I want to read it every 10 minutes, so it ...
0
votes
0answers
40 views

AVR TWI/I2C Not Responding

I use Twi module of AVR Atmega168 to talk to DS1307. ...
0
votes
1answer
63 views

Does the Atmel-ICE Debugger work on ATtiny MCUs?

I've looked on the interwebtubes and could not find out if the Atmel-ICE debugger works with ATtiny MCUs. In theory, since the debugger supports debugWire and SPI modes, it should, but the official ...
0
votes
0answers
29 views

AVR324PA controller not executing flash code

We got a simple circuit that has a ATMega324PA controller. We use AVR-ISP MKII programmer to program the controller. Both the controller and programmer is supplied with the target voltage 1.8V. ...
0
votes
1answer
107 views

Reduce power noise on AVR

I'm working on an AVR computer, everything works fine, except when I tap any ground point with my finger (there are a lot of them exposed), the MCU (an ATMEGA328) hangs for a brief second. I have a ...
0
votes
2answers
93 views

Custom Atmega32u4 board first boot

I've built a custom board with an Atmega32u4, like the Arduino Pro Micro from Sparkfun. The circuit seems ok, but when I plug the board to a pc, the usb device isn't recognize (doesn't even pop the ...
2
votes
1answer
109 views

Run barebone arduino on 3Volts battery

i have finished building my barebone arduino..i want to run the barebone chip with 3V battery i.e double AA 1.5 x 2= 3V..the reason i am persisting using 3V Vcc is because in our project we need to ...
1
vote
1answer
99 views

ATmega XTAL input capacitance and crystal load capacitance

I need precise low-ppm crystal for my circuit with 8-bit ATMEGA (AT90USB1286). Currently 18pF TXC HC-49 (11.5x5mm) is used. I need also minimize size to reduce potential EMC and PCB. TXC - 7M/B ...
1
vote
1answer
66 views

No correct signal from ATMEGA162 UART

I got the following circuit: simulate this circuit – Schematic created using CircuitLab And this code to run it: ...
0
votes
0answers
47 views

I am able to program atmega8 but not atmega16/32

I am new to microcontrollers and am taking it as a hobby. I have USBasp programmer with a 40 pin ZIF socket. I used to program my atmega8 for blinking LED's and other purposes. Now I am working with ...
0
votes
0answers
59 views

ATmega 1284P lockup or stuck in reset after lightening storm, then fully recovers. How to prevent it?

I have a custom Arduino based data collection system which has been running happily, reporting data over a cellular connection on solar power for a few months. After a lightening storm it stopped ...