Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [atmega328]

The ATMega328 is the chip that is the heart of the Arduino Uno. It is popular also as a chip to use to create your own board. Since it is available in the through hole version, it can be placed on a breadboard easily for circuits.

Filter by
Sorted by
Tagged with
0 votes
0 answers
15 views

Help with Arduino sleep and watchdog timer interrupt

I want to use Arduino's sleep and wakeup functionality but have hit a roadblock and can't seem to get past it. As I am just prototyping for a final system, I cannot use the LowPower library to ...
user avatar
-2 votes
0 answers
22 views

Connect MAX30100 directly with ATmega328p without using Arduino [closed]

Can we use MAX30100, a pulse oximeter sensor to connect directly with ATmega328p without using Arduino?
user avatar
-1 votes
0 answers
38 views

Ardunio Errors with ATmega644A Fastled (MCUDude Mightycore)

Good Morning, I am trying to compile a ardunio project with ATmega664A using the MCUDude MightyCore plug in while using the Fastled library. I have used this before with ATtiny167 with Spence Konde ...
user avatar
  • 1
1 vote
0 answers
40 views

ATmega 328 Bootloaded, but Cannot Upload

I have been working on a project that I program using the ATMEGA 328p inserted into an Arduino Uno, and then remove it to put it on my breadboard. I now have realized how inadvisable this is, since I ...
user avatar
2 votes
1 answer
146 views

Arduino Nano Atmega328P not sleeping with either <LowPower> or <avt/sleep.h>

I'm working on a battery powered Arduino Nano project. I really need it to save power for hours on end, so I turned to Arduino LowPower Library and avr/sleep.h to do the job. However, whatever I do, ...
user avatar
  • 123
0 votes
1 answer
33 views

Safely extend TCNT1 / ICR1 to 24 bits using TOV1

I'm hoping to time external events on a '328p Arduino that will occur slowly enough that they'll overflow the 16-bit counter TCNT1. In a different scenario I'd prescale the counter, but I need the ...
user avatar
  • 221
1 vote
1 answer
102 views

Interval timer on Arduino: Doubt about TimerOne library

I want to synchronize a timer interrupt from a button is pressed. I want to read a button state 3 seconds later from the first pulse moment (to identify long pressed button, 3 seconds for this example)...
user avatar
  • 113
2 votes
0 answers
71 views

Why can't an Arduino/ATmega328 act as an SPI slave at anywhere approaching the maximum speed claimed in the datasheet?

The ATmega328 datasheet claims a maximum SPI slave speed of Fosc/4. For a chip clocked at 20MHz, that would be 5Mbps. However, my tests show that even with no processing whatsoever in the interrupt (...
user avatar
1 vote
1 answer
86 views

Uploading to an external Atmega328P with a clone UNO R3 with soldered chip

As a complete newbie, after much looking for the best bargain, I ended up buying one of these UNO R3 clones, without realizing it had the chip soldered on the board. It looks like this: It works OK ...
user avatar
  • 121
2 votes
2 answers
64 views

Trying to understand the bottleneck of sensor sampling rate

Lets say I have a sensor connected to Arduino Uno Rev3's I2C Bus. I am reading the sensor output and using Serial.print() to send the sensor reading back to a my laptop. I am trying to understand the ...
user avatar
2 votes
1 answer
89 views

Will the pro trinket gamepad library work on an Arduino Uno?

I have an Arduino Uno and I wanted to know if the pro trinket gamepad library works on an Arduino Uno since both have same atmega328p CPU chip.
user avatar
2 votes
1 answer
44 views

SparkFun RedBoard PTH Kit wrongly configured hardware

I have a SparkFun RedBoard PTH Kit. It's not made by SparkFun, but by https://inmotion.pt (that doesn't exist anymore). I soldered it, and bought a FTDI adapter, but when I try to upload the blink ...
user avatar
  • 121
2 votes
1 answer
98 views

Arduino not rebooting with watchdog enabled

I have a custom board that is switching an inductive load through a 10A@230V ac relay. Due to a poor design, voltage spikes are causing the board to reboot from time to time (brown-out, watchdog and &...
user avatar
  • 21
0 votes
3 answers
228 views

Power saving configuration of unconnected pins

By default, all Arduino (ATmega328P) pins are configured for input without the internal pull-up enabled. This default seems to come from the AVR microcontroller itself. When it comes to saving power - ...
user avatar
0 votes
1 answer
36 views

Where does the 5v Output power on the Arduino uno come from?

I am wondering where the extra 5v output power on the Arduino uno come from. Is it directly from the atmega328 microcontroller or from the external power source (usb or 9v battery). Thanks.
user avatar
0 votes
1 answer
34 views

Bootload from a Nano to an ATMega328 without a crystal

I have a program to load from a Aduino Nano as ISP to a ATMega328p chip that will have an internal clock at 16M, but I don't have a crystal handy. Is there a way I can not have to buy a crystal? What ...
user avatar
  • 167
2 votes
1 answer
119 views

Arduino data-types

(Im new to the arduino side of stackexchange). Im working on a worksheet for to begin with arduino. I have prior experiences working with arduinos, but problem is new for my field of expertise. Any ...
user avatar
0 votes
1 answer
62 views

Procedure for changing frequency of Nano or similar

I need to get interrupts at one of three specific rates: 1920, 2000, and 2400 per sec, at a fairly high precision (~10 ppm). I've asked about this on Electronics but I think here might be more ...
user avatar
  • 221
1 vote
1 answer
98 views

Adding L293D motor shield to Breadboard

Anyone knows how to attach the l293D motor driver shield on a breadboard? I need to put the shield on top of a breadboard and then use an Atmega328P as the main way of controlling it. Than you :)
user avatar
5 votes
2 answers
396 views

Powering Atmega328p from 4.5V

I want to use Atmega328p controller to handle some very simple signals. I'm using the chip and not the whole arduino board because it is a lot cheaper. The problem is that chip itself doesn't have ...
user avatar
  • 75
2 votes
0 answers
64 views

Stand alone Atmega328p-au

I'm trying to make a standalone arduino board with an OLED display using an Atmega328p. I never tried to make such a board using SMD components. I've soldered everything together except the OLED ...
user avatar
0 votes
1 answer
63 views

Two-Wire Interface (TWI) Frequency and SMBus Compatibility

Have I understood the ATmega328P datasheet correctly regarding the TWI clock frequency? From §21.5.2 Bit Rate Generator Unit, the TWI clock frequency is calculated as follows: Then solving for TWBR: ...
user avatar
  • 629
1 vote
1 answer
69 views

Interrupt takes longer than expected [closed]

I am trying to write a delay function in C, which should take 0.5 seonds then carry on. I am aware that there are libraries for this purpouse, I want to make it myself. #include <avr/interrupt.h>...
user avatar
1 vote
0 answers
66 views

the buzzer stops sounding after a few seconds

Sorry, I'm not fluent in English. I beg your help I made an arduino uno project where the buzzer only turns on for 2 seconds after the light turns on. Even though the light is still on I want the ...
user avatar
  • 11
2 votes
2 answers
142 views

As a novice, how do I program my Atmega328p?

I bought a board which the above MCU is the atmega328p. Since I haven't used atmel MCU before, now it's a bit confusing. Are the ATMEGA and STM32 programmers not universal? What programming methods ...
user avatar
0 votes
1 answer
68 views

Save Watchdog ISR Return Address in EEPROM

If the WDT ever fires, from the ISR I save some info in EEPROM for later diagnostics before I drive the reset pin. Stack size, heap size, etc. It might also be useful to know where the code was when ...
user avatar
0 votes
1 answer
33 views

DS1337 with shared I2C pull-up

I have a project using an ATMEGA328P and a DS1337 RTC chip. The DS1337 is an 8 pin IC with VCC at pin 8 and GND at pin 4. According to the datasheet both pin 5 (SDA) and pin 6 (SCL) need an external ...
user avatar
  • 43
1 vote
0 answers
40 views

Reprogram By Address: Arduino Node Array

Let me just start off by saying that this is the first time I've attempted a project at this scale. I'm not sure that I'm even taking the right approach on this. I'm attempting a project inspired by ...
user avatar
2 votes
1 answer
56 views

SPI.begin doesn't work after tristate

I am working on a ultra-low power project using an ATMEGA328P, a nRF24L01 and a 0.47F super-capacitor to measure various sensors akin to Gammon's solar power project. I have been having problems with ...
user avatar
  • 43
-1 votes
1 answer
239 views

ATmega328p bootloader issue : [avrdude: stk500_recv(): programmer is not responding]

I am using an arduino uno board and have placed the new ATmega328chip in the socket as a simple setup as mentioned in Minicore installation instructions. However, I am unable to burn the bootloader. I ...
user avatar
  • 183
1 vote
0 answers
71 views

Why does this piece of code overflow at 255?

Im having a problem where i got unsinged long variable and i need to increment it in eeprom everytime setup starts and it overflows at 255 back to 0. unsigned long NumberOfBoots = 0UL; #define ...
user avatar
  • 11
1 vote
1 answer
46 views

Custom 328P-AU board not responding via ICSP

I created a custom PCB based on a 328P. The design is mainly based on the Arduino Nano schematic (3.0). The boards have arrived some days ago, and I can't get avrdude to recognize them via USBASP (or ...
user avatar
  • 23
1 vote
0 answers
34 views

Help with understanding fuses for an embedded AVR project

I am planning to build a project, but it's something quite embedded and I have no need for the extra features or bootloader of a standard Arduino. At the same time, I think I want to use the ATmega ...
user avatar
0 votes
1 answer
143 views

What does avrdude: Device signature = 0x000000 mean? Faulty wiring? Software issue? Incorrect tutorial?

I followed this tutorial a couple of times and when I clicked on bootloader I get this error: avrdude: Device signature = 0x000000 To see the configuration file click here. Why do I get this error (...
user avatar
1 vote
0 answers
30 views

Receiving code between atmega328P (C) and Feather m0 (Arduino)

I've tried to create a receiver code for receiving my data (really only want the ac/gy values and nothing else) and use the following main code for sending via C programming: https://github.com/...
user avatar
0 votes
1 answer
34 views

Atmega328p with arduino without the board

Perhaps this is a beginners question and I am not sure. I currently have a custom made circuit with an atmega328p chip connected to an mpu6050. However, when I program in Arduino I am not sure what to ...
user avatar
0 votes
1 answer
109 views

LED Blink in assembly with timer1 output compare interrupt not working

I was trying to have some fun with avr-assembly on my arduino and I tried the following codes to blink my LED first I tried the ISR approach and when It didn't work I tried the CTC mode one, both ...
user avatar
1 vote
1 answer
35 views

Will the noise from a voltage regulator interfere with IR LEDs and receivers on an Atmega328? (Arduino Uno sketch)

I have a project which uses an IR LED and receiver to communicate with other Arduinos. I am using the Atmega328 out of the Uno, rather than the whole Arduino board and I need it to be battery-powered, ...
user avatar
  • 63
-1 votes
1 answer
457 views

Why ATMEGA328P U-TH doesn't answer to USBasp but work fine with Arduino as ISP?

I ordered ATMEGA328P AU from China recent but I got "ATMEGA328P U-TH". which seem super problematic. I try to use USBasp to burn bootloader but it fail and show error message as shown. ...
user avatar
  • 131
1 vote
0 answers
81 views

Error message while trying to burn bootloader onto atmega 328p

I have tried to burn bootloader onto an atmega 328p chip onto a breadboard using another arduino uno , I am not using an external clock but I am doing all the steps to make this thing which are given ...
user avatar
2 votes
1 answer
372 views

How detect I2C errors with requestFrom()

I am going to use MCP23017 chips, and some of them will be cabled with a 1 meter max unshielded cable. I am expecting that certain transmissions may toss errors. So I want to tackle this problems by ...
user avatar
  • 133
0 votes
1 answer
277 views

LED does not blink - Arduino UNO+WiFi R3 ATmega328P+ESP8266 board

As I am learning the Arduino coding, I want to see if my program can turn on the LED light. I have tried all the things, but the code does not start the LED light I have installed on the board. The ...
user avatar
2 votes
1 answer
73 views

Nrf24l01 smd pcb placement tips

I am working on pcb design with nrf24l01 smd. I have read somewhere that nrf24l01 module has problem while communication when it is placed with its antenna within the pcb. I want my module to be ...
user avatar
1 vote
1 answer
399 views

AVRdude does not read the FUSE byte values correctly

I am exploring the ATmega328p MCU via a standard Arduino UNO, with the help of avr-gcc toolchain and AVRdude (All in the WINAVR package). I have successfully programmed the board a few times with it. ...
user avatar
  • 113
0 votes
1 answer
277 views

Atmega 328p at 3.3v : Internal vs external oscillator

I am currently working on a pcb that uses smd atmega 328p (au). I will be powering it through a lipo battery and a ldo regulator for 3.3v input. I am using the multiwii flight controller code. I know ...
user avatar
1 vote
0 answers
48 views

Arduino code crashing

I am writing an SIM900A + arduino(Arduino UNO with Atmega 328P) code to just send the current time stamp every 20 minutes. The code keeps crashing in the SendMessage() function as the setup prints ...
user avatar
  • 11
1 vote
1 answer
53 views

Atmega 328P U crash on 5V/1A [closed]

Atmega 328PU crash on 5v/1A. Why? It works on 5V/400ma but when i switch it to 5V/1A power it crash. Any idea or solution for this?
user avatar
  • 113
0 votes
2 answers
67 views

Can I use the microchip of Arduino Uno as a standalone microcontroller

I want use the ATmega328P chip of the Arduino Uno board as a standalone device. Is that possible? Which pins are which on the Arduino board and the ATmega328P? Do I need any external components?
user avatar
1 vote
0 answers
78 views

Cannot program ATMEGA328PU after burning bootloader with internal clock

I have build a couple of boards that have an ATMEGA328P-AU (the 32 pin MLF, as used on the Arduino Pro Mini). If I burn a bootloader via SPI to use an external 8MHz clock, I can then use the Arduino ...
user avatar
  • 111
1 vote
0 answers
36 views

SD card initialize and fails when date changed

i am making a project using Arduino Uno that display data on 7 seg display which stored in SD card as day by day. when i make power ON to device then SD card initialization done & data shows ...
user avatar

1
2 3 4 5
10