Skip to main content

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.

0 votes
4 answers
51 views

What does it mean the MCU has 1 ADC and 10 ADC channels?

I got this AVR Microchip MCU ATtiny 204 chip. Now what I can't get, what do they mean in the datasheet it has 1 ADC and 10 channels ADC? The datasheet:https://datasheet.octopart.com/ATTINY204-SSF-...
Hazardous Voltage's user avatar
0 votes
1 answer
44 views

LCD Entry Mode Set and AVR MCU

I want to simulate **the Entry set mode ** function of and LCD based on HITACHI 44780 Controller. (Here is the datasheet.) The "Entry set mode" is given the following code of the 8 bits data ...
learn design's user avatar
  • 1,020
0 votes
1 answer
81 views

Analog switch for controlling LED

I need help/suggestions for the implementation of my schematic: In the schematic image pasted below, particularly look only at the charging IC, boost converter, analog switch, and ATTiny 1616 ...
Tahoor Asim's user avatar
0 votes
0 answers
24 views

AVR128Dx TCB Input Capture issue

Ive made a code for reading SENT sensor using TCB interrupt with event system. It works 90% of the time, but those 10% seems like it doesnt read correct high pulse duration, mby someone will see, what ...
Ralfs Volis's user avatar
2 votes
1 answer
295 views

Memory view is showing multiple bytes change after a single byte is assigned to a register. Why?

I am debugging an issue I have on a legacy codebase that is running on an atxmega32c4u chip. I am writing single bytes to registers in PORTC, but the memory view is showing multiple bytes change. The ...
daviegravee's user avatar
0 votes
1 answer
51 views

No touch points close to the edge of the screen

Just for fun and to learn, I'm writing code to drive a 800x480 TFT with resistive touch driven by an RA8875 and an ATmega328P and avr-libc. It works fine so far but when reading touch events, I don't ...
Torsten Römer's user avatar
0 votes
0 answers
27 views

Which ATtiny TWI parameter provides more robust operation?

I'm using an ATtiny3226 as an I2C client (slave) interface in a robot, to get commands from the main controller (single master) using I2C on a shielded cable. There are brushless and servo motors ...
Tirdad Sadri Nejad's user avatar
0 votes
1 answer
41 views

AVR assembly indirect addressing: "Found no label/variable/constant named …"

I am currently trying to indirectly address the SRAM of the ATMega328P by using the following code: ...
user380637's user avatar
1 vote
0 answers
48 views

SSD1306 display goes out-of-sync only if ATmega328 is reprogrammed

I have ATmega328 directly connected to the SSD1306 Display through I2C. Whenever I power up the ATmega, everything works great and the display works as expected. The problem occurs only when I upload ...
0x29a's user avatar
  • 481
0 votes
0 answers
29 views

Problems with OCR1B on Atmega328p

Trying to control 4 servos (SG90) using 4 pots on an arduino nano and the one connected to OC1B keeps having problems, with bits of jittering and it just not moving correctly (occasionally spinning), ...
jimothy's user avatar
0 votes
1 answer
36 views

Why did fuse bits successfully reset using ICSP and USBASP programmer?

I read a lot about fuse bits in AVR microcontrollers and everyone says that fuse bits can be reset by using high-voltage programmer only, they can't be reset via UART<->ICSP. So, I've received ...
Alexander Perechnev's user avatar
0 votes
2 answers
68 views

Extended IO registers handling in AVR using Assembly language

I want to program the ADC module of arduino Mega2560 using Assembly language (for simulation and learning), I can initialise the ADC Module using Assembly and my program converts in the first ...
learn design's user avatar
  • 1,020
1 vote
1 answer
49 views

Manipulating EEPROM in AVR using assembly programming

In the following video(at 10min): https://www.youtube.com/watch?v=YELGX5XDCiY&list=PLgwJf8NK-2e55CdbY_WnY6pejPHoojCkJ&index=18 The microcontroller used in the video series is ATmega32. Let's ...
learn design's user avatar
  • 1,020
1 vote
0 answers
48 views

SPI: Write to display while reading multiple blocks from SD card

I'm reading BMP images with hundreds of kB's raw from an SD card and parse/write the image data to a TFT LCD with an AVR MCU with 2kB RAM. Reading a single block of 512 bytes with CMD17, passing it to ...
Torsten Römer's user avatar
2 votes
3 answers
208 views

Tightest finite wait loop possible in AVR8

I need a wait delay function with fine grained control of the delay. I came up with the fairly standard way ldi Rx, N lp: dec Rx brne lp This ...
Peter Rottengatter's user avatar
0 votes
2 answers
143 views

AVR ATmega328P if statement wrongly executed after reset

I have simplified the listing to bare minimum where I can still observe this behaviour. When this program is running, it works as expected. Button press causes LED to show up. The problem exist on ...
smajli's user avatar
  • 940
0 votes
1 answer
47 views

How to increase the Atmega32A input output pins

I’m using ATmega32A to control a system which have a 30 outputs and 30 inputs. The issue is that the ATmega32A have only 32 DIO pin which can be use as input output pins. So how can I increase the ...
abdalla zakaria's user avatar
0 votes
1 answer
82 views

ATTiny85 won't reprogram

I am using a tiny AVR programmer to program code specifically this one, https://www.amazon.com/dp/B00B6KNJRY?psc=1&ref=ppx_yo2ov_dt_b_product_details , I can successfully upload code onto a blank ...
Ash Ketchup's user avatar
2 votes
1 answer
117 views

AVR32DA VIH threshold

I am looking into using an AVR32DA48 MCU for a design. The MCU will be powered at 5V and needs to interface with an IC at 3.3V. The IC is 5V tolerant and I am trying to figure out if a level ...
Mr.Y's user avatar
  • 153
0 votes
1 answer
80 views

How to identify all AVR MCUs (ATtiny and ATmega) that feature a factory-programmed unique ID

On Microchip's site, the "parametric search" table for microcontrollers does not have a filter column to select the models that feature a unique ID. Is there a way to list (enumerate) all ...
Cal-linux's user avatar
  • 2,153
0 votes
1 answer
42 views

Can WINC1500 be used with SPI for connecting to a router?

I'm planning to buy the WINC1500 WiFi module. I have heard that it contains a SPI layer, which can be used for telling the WINC1500 to connect to a router. But as I can see in the documentation, I ...
euraad's user avatar
  • 1,324
0 votes
1 answer
52 views

Ohmic load on AVR's SCK?

I have an ATTINY13, and almost all pins are used (only PB2 is free). What I need to add is a controllable ohmic load, which I believe best way to add is with an N-channel MOSFET, similarly with this ...
Daniel's user avatar
  • 969
0 votes
2 answers
79 views

Can I treat the USB controller in the ATMEGA8U2 as seperate from the rest of the microcontroller?

I'm working on a project that runs on a battery, but can be connected to a computer for a serial connection/charging. In the documentation it lists an example of a bus powered USB controller with ...
Elliot Smith's user avatar
1 vote
3 answers
300 views

ATMEGA328 out of memory, but avr-size reports I still have a lot of space

I have a program written in C. I have 390 byte array defined and a long string value consisting of around 475 bytes. Now I hit a problem if I add more characters to the string value, around 30 bytes, ...
0x29a's user avatar
  • 481
4 votes
2 answers
1k views

Transmitting from PC via USART to MCU working but very slow

I am sending a small 16-Bit RGB BMP image file from my Linux PC via USART (with a loosely wired USB to serial converter) to an AVR ATmega MCU sitting on a breadboard, running at 8 MHz with the ...
Torsten Römer's user avatar
0 votes
0 answers
99 views

Graphical LCD With Atmega64

I have ATMEGA64 and LCM240128, The wiring is as below: And my code is ( I'm using codevision): ...
Mojtaba Miraki's user avatar
2 votes
1 answer
379 views

ATmega64 custom board is not programming

I have designed a custom board for ATmega64 as below: It's the first time I want to program it, and I get a "chip enable program error". I can program ATmega16 and ATmega8, but for ATmega64 ...
Mojtaba Miraki's user avatar
1 vote
1 answer
94 views

ATMega328p wakes immediately after sleep

I'm having issues with my current AVR-C project that runs on an ATMega328p. After issuing the sleep command the chip wakes up again immediately. I want to wakeup with an external interrupt, but while ...
Julian F. Weinert's user avatar
1 vote
2 answers
478 views

Assembly: AVR Studio alternatives for Linux [closed]

I had been using using AVR Studio on Windows to write assembly code for my MCUs (mainly for atmega8515) for a couple years. However, recently I transitioned to Linux and turns out there aren't any ...
Heather7283's user avatar
4 votes
1 answer
649 views

AVR code disassembly - what is this code doing?

I have read and disassembled the code from an Atmel8 microcontroller from a faulty oscilloscope. This is the start routine: ...
DrD's user avatar
  • 199

15 30 50 per page
1
2 3 4 5
64