Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [atmega2560]

Low-power 8-bit AVR microcontroller with 256kB flash.

0
votes
0answers
22 views

Min/Max current for supply input of mega2560

What is the min and max current the mega2560 can take for the 5v supply input voltage of the chip itself, not just the arduino mega?
0
votes
1answer
47 views

Switch statement cases not executing

Overview: I am trying to use a switch statement to run different tests. A main menu is displayed on the serial monitor, and then the user is given the option to enter their menu choice in the serial ...
0
votes
0answers
15 views

Arduino Swarm - WiFi and Embedded Communication

I'm developing an Arduino-based swarm, each bot having 1 ATMEGA2560 as its main processor and 1-2 ATMEGA328 as sub-processors and a variety of sensors and actuators, with WiFi (LAN) connection in a ...
0
votes
2answers
46 views

How can I discard power from a device I want to read from?

I want to read the data line from a device that normally interfaces with a controller. It has 3 pins, 3.3v power, gnd, and data. I don't need the power line since the Arduino will be USB powered and I ...
2
votes
1answer
49 views

Ardunio Mega/ATmega2560: Using Port F or K for both analog inputs and digital outputs

On an ATmega2560, can ports have some pins used for analog inputs but others as digtial i/o? Specifically, I only need to use 3-5 analog inputs but have many digital inputs. I would like to use the ...
0
votes
2answers
41 views

Will a 12 VDC 1A Power Supply Adapter supply too much power and damage an Arduino Mega 2560?

The specs shown here: show that it has 54 digital pins with each outputting a DC current of 20mA which makes it 54 * 20 = 1080 mA Plus the DC current of the 3.3V Pin of 30mA we get a total of 1110mA....
1
vote
2answers
50 views

Matrix keyboard and 7segment display countdown combination

I'm working on an escape room for my university with an Arduino Mega. The last part consists of a 7segment display representing a time countdown, and the participants have to introduce the correct ...
0
votes
1answer
29 views

Converting code for ATTINY85 to ATMEGA2560. Pin change interupts

I have code that compiles correctly for an ATTINY85 board using the ARDUINO IDE but I don't have an ATTINY85 board. I have an Arduino Mega ATMEGA2560 and when I select this board in the Arduino IDE ...
0
votes
2answers
283 views

Parse a large json response with ESP8266

I'm doing a project where my Arduino uses an external ESP8266 wifi module (with AT firmware) to send http requests and receive server response. I'm trying to get an NBA scoreboard, and here's what my ...
0
votes
0answers
33 views

EEPROM.read data not comparing with DHT11 sensor value - Arduino temp controller

I'm using a DHT11 to read temperature to control a relay that will control a fan. When 'A' is pressed it allows the user to update the temp value that the relay will go HIGH at. The value is being ...
0
votes
1answer
341 views

How to program the Robotdyn Mega 2560 PRO MINI?

I want to program the Robotdyn Mega 2560 PRO MINI which has no USB port. How do I connect the pins to an FTDI? Which setting do I have to use in the Arduino IDE?
0
votes
0answers
39 views

Sketch works on MEGA 2560 timer2, but does not work on timer1

I set the PWM frequency on MEGA 2560 like this: TCCR2A = 0; TCCR2B = 0; TCNT2 = 0; TCCR2A = _BV(COM2A1) | _BV(COM2B1) | _BV(WGM20); ...
0
votes
2answers
84 views

ATmega 32A and 2560 R3 register to pin mapping?

I've been doing research for the last few hours trying to determine the mapping of physical pins to memory-mapped I/O registers for the Arduino Mega board (which is an ATmega 2560 R3). My code is on ...
1
vote
1answer
182 views

SOLVED: Strange phenomenon with avrdude: stk500v2_ReceiveMessage(): timeout only with ATmega250 on windows 7x64

I know this problem has been reported multiple times but in my case I think there is a different light on it. My desktop is a w7x64 box and I also have a notebook with w10. Both system have the ...
0
votes
1answer
28 views

Arduino Nano, Uno and Mega - XBee connection difference

I have a simple sketch working on arduino Uno and Nano sending data using an XBee. However, if I run the project on an Arduino Mega it does not work. What differences between Uno/Nano and the Mega ...
0
votes
0answers
29 views

Why is arduino Mega2560 taking so much time to recognise the pin is no longer at HIGH? [duplicate]

I am in my first arduino steps. I have a Mega2560R3 I wrote this code const byte D0 = 22; const byte D1 = 24; const byte D2 = 26; const byte D3 = 28; const byte D4 = 30; const byte D5 = 32; const ...
0
votes
0answers
149 views

How to use watchdog timer for the purpose of recovery from failures in Arduino ATmega2560

Here is my tool-set; Visual Studio with plugin called "Visual Micro" Flashing the HEX file using Atmel Studio. via AVRISP mkII on ATmega 2560 MCU And my simple trial code (I have also some others). ...
0
votes
1answer
41 views

Which board's bootloader is on the microcontroller?

Currently I'm doing a project that needs an Atmega2560 standalone MCU. After I burned the bootloader with this method: http://www.gammon.com.au/bootloader . I set the Board as "Arduino/Genuino Mega or ...
0
votes
1answer
78 views

Receiving junk values in Arduino serial monitor console

I want to send a character from a Zigbee transmitter to an Arduino Mega 2560. After the character is received, Arduino should send some data back to Zigbee. But Arduino is always receiving junk values ...
2
votes
1answer
150 views

Trying to run Timer1 in ATmega2560 with assembly

I have a slight problem with Timer1 in arduino (ATmega2560) while coding it in assembly. I try to run the Timer1 in CTC mode - I configure everything well in my opinion, but the TCNT1 just doesn't ...
0
votes
1answer
27 views

What are the negative PINs for on the IndustrialShield M-Duino 58 Analog

I am working as an internship on an Arduino based PLC. It is the M-Duino 58 Analog from IndustrialShields. I try to figure out how it works; Reverse Engineering. But i dont know why it has negative ...
0
votes
2answers
39 views

Read sensor data repeatedly after specified time?

I want to read sensor data using analogRead() after every 5ms. I have read other answers to similar questions but what I'm confused about is: let's say, I made a loop to read sensor data using ...
0
votes
1answer
25 views

Arduino loop over a function is always displaying 0 as final values

I trying to loop over a function in arduino to get values for 2000 times, and then divide it by 2000 to get an average offset: int16_t x_offset = 0; int16_t y_offset = 0; int16_t z_offset = 0; And ...
2
votes
1answer
222 views

Arduino Mega and gyroscope erroneous values

I have Arduino mega2560 and MPU6050. I connected to Vcc pin of the gyro to +5V on the mega, the SDA to SDA pin, SDL to SDL pin, AD0 and GND to 2 GND pins. I used this code: #include<Wire.h> ...
1
vote
1answer
120 views

Using the Arduino compiler, is it possible to use Atmega2560 interrupt pins that are unused by Mega?

Looking into the schematics for the Arduino Mega I noticed that pins PE6 and PE7 are interrupt-enabled (INT6 and INT7 respectively); however, they remain unconnected to any Arduino I/O pin. I'm ...
0
votes
1answer
33 views

attachInterrupt for mega 2560 not triggering

I recently bought a mega 2560 to toy around with as a hobby. It's pretty fun so far, but I've recently gotten stuck while trying to use attachInterrupt with a button. I'm using the CHANGE mode, and ...
1
vote
1answer
98 views

Arduino Mega Pins for SoftwareSerial (vs. AltSoftSerial)

I am currently looking at using an Arduino Mega to build a MIDI Receive box that will then pump the data over USB, but am having design issues/uncertainties with the Arduino's receiving end. I am ...
0
votes
2answers
79 views

Is an atmega 2560 board compatible with the Adafruit Trellis?

I want to build a custom midi controller for my computer, and yes, Adafruit has a mini Untz project. For my purposes, I need more analog inputs than the Leonardo, and the only other option I can find ...
1
vote
1answer
163 views

PROGMEM Corrupted Array

I am trying to store a large number of values into a couple of arrays using PROGMEM, but I am finding that a few of the values are read back corrupted. I am storing just 1s and 0s, but when I read ...
0
votes
0answers
273 views

How to program an SSD1322 display?

I'm new to programming. I would like to change the characters on an SSD1322 OLED display. Here are the photos. Is this possible with an Arduino Uno? Is the program of the display in the display or in ...
-1
votes
2answers
85 views

how can I break from this case by IRremote even if it's not finished yet?

I want to give a pause to case 0xFF02FD or at least to break from that case by entering the case 0xFFA25D even if the 1st case not finished, when I press power button wich has hexa code ( 0xFFA25D) I ...
1
vote
1answer
155 views

Confusion over Transistors for a switching circuit with an Arduino Mega 2560

Apologies if this is a stupid question asked by a noob, but I've looked around to try and find the answer and just can't work it out. Basically, I'm making a project on thingiverse (Glitch's MK2 ...
0
votes
2answers
117 views

Meaning of part number suffix on top of atmega2560 chip

I have been working on creating a stand alone atmega2560 arduino. When trying to program it with a serial adapter using the rx and tx pins nothing was happening. After a lot of debugging I found the ...
0
votes
2answers
304 views

ATmega 2560 with Arduino bootloader running issue

I have designed a board based on an ATmega2560 chip and I burned the bootloader by following this tutorial. Now I am able to load Blinky and other programs using an FTDI cable. But the issue I am ...
2
votes
3answers
125 views

Conditional randomization gets stuck

First-time poster here... I have the following code to randomize note values and store them in an array loop1[i], where i is a specific step in the loop: nextNote = random(-2, 3); note = note + ...
0
votes
1answer
533 views

Uploading code to Mega 2560 is stuck

I'm trying to upload code from a Mac (online Arduino editor) onto an Arduino Mega2560, to connect a motor to pin 52 and Ground to get it to move. But at the top it says busy (like it does when it ...
0
votes
0answers
1k views

Disable auto-reset Mega 2560 on serial monitor open using 60 ohm resistor

I tried preventing my Arduino Mega 2560 from restarting every time I open the serial monitor. This link didn't work for me at all. I tried connecting the RESET pin to 3.3v pin via a 60 ohm resistor ...
0
votes
3answers
415 views

avrdude flash issues

I want to burn a hex file to a custom ATmega2560 board. I use this USBasp programmer for flashing (firmware version 1.01) on my Mac OS X 10.12.6 system. All hex files are compiled with avr-gcc (GCC) 4....
1
vote
2answers
216 views

Trying to determine the phase difference between two square signals

I have been looking for the phase difference between two square signals and this is the code: #include <avr/io.h> #include <avr/interrupt.h> void setup() { //Serial.begin(9600); ...
0
votes
2answers
150 views

Why Arduino Mega 2560 throw error when i try to upload example

I'm try to connect my Arduino Mega 2560 to PC, but I think it's not easy as I imagine. I spent a lot's of time to install USB driver. Here is a screenshot: When I try to upload blink example, Arduino ...
0
votes
2answers
319 views

Burn Bootloader to Chinese Arduino 2560 with AVR ISP programmer

I got my hands on one of these ISP programmer for Atmel AVR microcontroller in USB stick design: Then I selected Progammer > AVR ISP and clicked on Burn Bootloader but it says stk500_recv(): ...
2
votes
2answers
890 views

Arduino MEGA2560 Standalone

I had an Arduino UNO (ATmega168) standalone working, but I need more pins, and I decided to use the ATmega2560, I was searching for some schematics, and none of them shown an ATmega2560 standalone, ...
1
vote
0answers
51 views

Erasing all flash on boards with over 64kb of program memory

I'm using a Mega2560 board. My project needs to store some large constant data. To preserve the first 64kb flash chunk, I write these data on addresses beyond this limit. But there is either an ...
3
votes
2answers
1k views

Arduino crashing during serial print for no obvious reason

I've written some Arduino Code which kept crashing and i couldn't find out why. Then i reduced the code as much as i could in order to see the problem. The reduced code currently doesn't do anything ...
1
vote
1answer
108 views

Controllino Debugging

Its a well known fact, that you can debug your arduino board with the help of an Atmel Ice. However, you might know the Controllino which is an arduino compatible device. It has an ATmega2560 on it. ...
1
vote
1answer
3k views

Rotary encoder I2C LCD menu

I am trying to make a menu for a monitoring/control system. I am not sure how to make this without interrupting my current code which needs to be monitoring my system at all times to shut off if it ...
0
votes
2answers
440 views

Read and store data with the usb

Hi i am new to Arduino and I want to know if it is possible to read the data from a sensor that it is connected to the Arduino, I am using the Arduino mega 2560, which is already working, as I have a ...
0
votes
2answers
155 views

mega2560- Interrupts reading digital input

Hi I am very new to Arduino, with very little programming experience. I am using mega 2560 and trying to understand how interrupt works. I have a code written, it is very similar as the example ...
2
votes
2answers
891 views

Error while boot loading Atmega 2560 using Arduino Mega 2560

I have developed custom board using Atmega 2560. I am doing boot loading process using the process of migrate from an Arduino board to a standalone microcontroller. I have followed this steps... 1) ...
3
votes
1answer
308 views

Bootloader and Boards Definition for Atmega2560V-8AU at 8 MHz / 3.3v

I am working on a home made project,where i am using Atmega2560V-8AU (note the suffix, this part has an 8 MHz maximum clock rate) as my main controller, supplying 3.3V to this chip. I want this ...