Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

Help me to guide in ATmega2560 and ATmega1280

Status
Not open for further replies.

chirag2239

Member level 3
Joined
Jul 29, 2011
Messages
64
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Activity points
2,048
Hi All,

I have two problems. I am working on 2 projects. One based on ATmega1280 and ATmega2560.

In the ATmega2560, I am confused that I have prepared the code in Arduino IDE for Arduino Mega2560. Now, I have to prepare my own project board. So I have ordered new ATmega2560. I have found the hex file which generated during compiling the code in Arduino IDE. I have doubt that does that code works with by just loading the hex file? Or I have to load a bootloader before loading hex file?
Because I have read that for the standalone microcontroller, we need pin mapping for Arduino. SO do I need to load bootloader and pin mapping and all?
Can anyone guide me through this project such that I can make my board working? I have checked my code Arduino Mega2560 already. But now I need that my code should work on my project board which is non Arduino. What I have to do?

For the second one, I want to know that is there any difference between Arduino Mega1280 and Arduino Mega2560? Because by mistake I have ordered ATmega128 instead of ATmega1280. I just want to test the code. So I want to know that does the code of Arduino Mega2560 will work with Arduino Mega2560? May I load this code of Arduino Mega1280 to the ATmega2560? Will it be work?

Please help me and guide me.

Thanks
Chirag
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
18,131
Helped
4,063
Reputation
8,126
Reaction score
3,985
Trophy points
113
Activity points
119,602
Hi,

first: For sure there are differences between ATmega128, ATmega1280 and ATMega2560. You find a lot in selection guides but in detail you have to read the datasheets.

bootloader:
Usually you don´t need a bootloader to run a program. But you need to do all the necessara setup on the ATmega periferals. And check how to setup the fuses.

Klaus
 

milan.rajik

Banned
Joined
Apr 1, 2013
Messages
2,528
Helped
540
Reputation
1,078
Reaction score
523
Trophy points
1,393
Activity points
0
Because I have read that for the standalone microcontroller, we need pin mapping for Arduino. SO do I need to load bootloader and pin mapping and all?
Only the code is compiled and .hex file generated then there is no need of pin mapping. Pin mapping only happens in Arduino IDE and finally .hex file needed for a device to work will be generated. Before .hex file is generated all pin mappings will be done.

- - - Updated - - -

ATMega1280 and ATMega2560 have the same pinouts and also Arduino Mega1280 and Mega2560 have the same pinouts. So, the code for Arduino Mega2560 can work with Arduino Mega1280 but if the code can fit in 1280. The reverse always works that is code for Mega1280 will work with Mega2560.
 

Status
Not open for further replies.
Toggle Sidebar

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top