Arduino Mega or DUE?

i have to buy an arduino board with more i/o pins and a better clock cycle,so was looking at mega, but the recent launch of due, has confused me,should i go for due?..wont there be some bugs present in it?

techra:
i have to buy an arduino board with more i/o pins and a better clock cycle,so was looking at mega, but the recent launch of due, has confused me,should i go for due?..wont there be some bugs present in it?

What are you looking to do? Honestly right now the Due hardware is showing piles of weaknesses much like the hardware that came before, give it time for better designed kit to come out from other vendors. The software side is mostly there.

silasmoeckel:
Honestly right now the Due hardware is showing piles of weaknesses much like the hardware that came before, give it time for better designed kit to come out from other vendors. The software side is mostly there.

What are the piles of weaknesses? and what other vendors can do that we can't do?

m

I don't think due has wakeness but due has bene just lunched and we have to discover The potentialies of the due :smiley:

but the recent launch of due, has confused me,should i go for due?

If you have to ask then go for the mega. This is a 5V processor with higher current on the output pins.

and a better clock cycle

Assuming this means a faster clock, have you a specific need for a faster clock. Most projects will be adequately covered by the mega's speed.
However, the Due opens up all sorts of other projects, because of its speed and memory it is just that being a 3V3 processor it needs more love and attention payed to its output pins.

The most glaring not connecting up the built in Ethernet and wiring multiple pins together effectively limiting external ram use come to mind. I have not yet received the one I ordered but made some in the shop, I think you really limited yourself in trying to keep the the mega form factor which in itself was trying to keep comparability with the previous generations. I'm already thinking of a lot of kit that does not have the correct values for current limiting resisters where a 3ma is not going to be enough. Now granted I think the breadboard compatible form factors make more sense for a hobby/learning device. I love the ecosystem you guys have created but I've never been thrilled by the hardware. That is the strength of open source hardware I can just pop up eagle make what I want by building on the great works you guys have already done.

I'm already thinking of a lot of kit that does not have the correct values for current limiting resisters where a 3ma is not going to be enough.

I think that problem exists for the majority of Arm style chips out there. If you have the programming ability to make use of the Due, you are likely able to handle planning hardware around the Due also.

cyclegadget:

I'm already thinking of a lot of kit that does not have the correct values for current limiting resisters where a 3ma is not going to be enough.

I think that problem exists for the majority of Arm style chips out there. If you have the programming ability to make use of the Due, you are likely able to handle planning hardware around the Due also.

I think experiance on this forum has taught us (me anyway) that that is simply not a good assumption to make. We've seen many new users that come to the arduino platform with lots of software knowledge and experience but have little experience at all with fundamental electronics knowledge and have little concept of voltage, current, resistance and don't even own a digital multimeter let alone know how to use one. Conversely we've seen many users that come with good hardware backgrounds but are just trying to take on learning the C/C++ programming language that the Arduino platform uses. And of course there are newcomers that come with vast experience in both hardware and software and are soon teaching us stuff. :wink: If you are new to either programming or hardware I would suggest the Uno or Mega2560 is a better choice for one's first arduino board rather then jumping on the new Due offering. The IDE for the Due is still officially a beta release and the hardware will be new to most all of use that have no prior ARM experience.

Bottom line is that the Due was not designed and build to replace the Uno or mega boards, but rather to offer a more advanced board for those projects requiring the increased resources that the Due board offers. Every new user will of course have to make their own decision on their first arduino board selection, but I would think that the 'official' forum recommendation should be that the Uno/mega is a best or better choice, unless the users has prior experience.

Lefty

Techra,
I would also agree with Grumpy_Mike.
For 5V compatibility, software maturity, and less headaches,
given a choice between MEGA and DUE boards, I'd pick Mega at this point in time.
But there are other AVR based options for more pins.
For example, the Teensy boards Teensy USB Development Board
if you don't need shield compatibility. Teensy++ has almost as many
i/o pins and the same amount of flash/sram/eeprom as MEGA but is MUCH smaller,
is more breadboard friendly for prototyping and has native USB support - something
not available on MEGA.
Teensy++ is also much cheaper than an Arduino MEGA.
As for speed, Teensy does have some core library modifications to make things faster
in certain situations without having to change any sketch code or using AVR specific coding.
For example, if doing digitalWrite() with all constant values, teensy can do that
in 62.5 ns vs Mega will do it in about 5us (Teensy in this case about 80x faster)

when you say:

i have to buy an arduino board with more i/o pins and a better clock cycle

Do you really mean "have to" or "want to".
At the present there really is no such animal.
There is no "arduino" board that can offer compatibility with existing AVR s/w and libraries
and give a better clock cycle. (faster)

The mega, offers more i/o pins but is still the same clock rate so the clock cycle will be the same.
Mega is not a speed up. It offers more RAM and more pins than Uno.
The advantage is that there is fairly good support for mega in many of the AVR based libraries out there.

DUE is faster than Uno/Mega, but given it is so new there are bound to be issues.
It is a different processor so any library that strayed away from using the arduino core code
functions and touches ARV registers or did inline AVR assembler will not work.
There are many libraries out there that do this for various reasons, from speed to needing
functionality that the arduino core code does not provide.

Also consider this, the Arduino team keep the final design specs and s/w a secret from
the general community until it was released, because of this the hardware and
software has not been reviewed or beat on by very many people at this point in time
and the Arduino community at large is just now starting to look at the impact
on existing libraries and shield compatibility issues.


-availability.
Granted this is probably only a near term supply issue.
But today, DUE is hard to get vs other 3rd party boards.

  • 5 volt tolerant inputs.
    IMHO, this is a really big deal and the main weakness in the DUE.
    From a "ease of use" and "backward compatibility" perspective,
    how useful is the Arduino shield compatible headers on the DUE
    when there are many shields out there that do bi-direction i/o
    and will drive input pins with 5v and potentially fry the DUE?

Boards like the chipkit boards don't have this issue since their input pins
are all 5v tolerant.

  • Value for the dollar
    The chipkit UNO32 hits a nice sweet spot, in that it offers 32 bit performance
    in an Arduino Uno form factor yet costs about the same as the Arduino Uno.
    (32bit 80mhz MCU with 128k flash and 16k of RAM with 22 extra i/o lines.)
    In other words:
    32bit, 5x the clock speed, double the i/o lines, 8 times the RAM, 4x the flash,
    5V tolerant in the same form factor and the same cost as an Arduino UNO.

Boards like the Teensy 3 are much smaller, cheaper than MEGA and will consume less power so
they will be better for 1 off small projects that are space and power limited.
Teensy also is much more friendly to bread-board prototyping.

For general playing around with 3v MCU boards,
the STM based boards like the STM32F discovery board are currently about $12USD
Not "duino" s/w but
it has 192k of RAM, same amount of ROM, it runs at double the clock speed of the Due and the board has various things on it (a DAC, a mic, an accelerometor, and a usb host port).
http://www.st.com/internet/com/TECHNICAL_RESOURCES/TECHNICAL_LITERATURE/DATA_BRIEF/DM00037955.pdf

--- bill

the STM based boards like the STM32F discovery board are currently about $12USD

Yes they are cheap, I have a couple myself. However the tool chain in a pain and it takes a long time to get all the drivers linked in. The examples don't work on many tool chains. It took me most of a day to get the blinking LED working, and two days to get the voice recorder example working.
I was using a trial version of Cross Works on my Mac. When the trial ran out it thought it was not worth the £100 or so for the software.

On the comparison of the Due with boards made by silicon vendors I think it's simply unfair.
Most (all) of these boards are sold either at cost or as a loss leader. Generally they do not a lot of work on the other elements of the equation or the simply copy us.

I can assure you that Arduino doesn't get any strategic pricing from ATMEL, the factories that make official arduino boards negotiate prices based on their sales.

About the Teensy. I think Paul did a great job. I won't elaborate on the pricing differences. There are many reasons for it.

Clearly the Due could be better in a number of areas like every product on earth. we could sit here and I could start finding things that I don't like about the Teensy, Chipkit and all the rest.

Judging Arduino just by looking at the hardware is a very narrow perspective on life... The project is the combination of multiple factors and it includes the work with do in documentation, keeping the IDE simple, working with the community on a lot of projects etc.

The project is the combination of multiple factors and it includes the work with do in documentation, keeping the IDE simple, working with the community on a lot of projects etc.

This is the #1 reason why I chose Arduino, and have built and bought more and more boards. I struggled with other IDE's and boards but, found quick success with Arduino!

I bought one of the TI Stellaris LaunchPad boards ($5!) TI has a very nice tutorial to get you up and started. "Open the box" is step 25... (after many downloads and rather complex SW installation procedures.)

techra:
i have to buy an arduino board with more i/o pins and a better clock cycle,so was looking at mega, but the recent launch of due, has confused me,should i go for due?..wont there be some bugs present in it?

I may not represent a "typical" Arduino user because I love to hack at the boards and libraries at the processor and bit level.

I'm just finally getting comfortable with the ATMEGA registers and layout... nothing I've written would work on a DUE board, so for me personally I would buy a MEGA2560 over a DUE.

It's difficult enough to acquire and maintain (and hack) the "classic" Arduino libraries without having to deal with another whole new set.

As long as the "high level" stuff (like analogRead, EEPROM, Serial.xx, etc..) all work on a DUE, then the DUE is probably the better choice.

My 2 cents......

There are some boards with Pick processors they are very nice not completely open source but faster than the atmega . DUE for me has been a disappointment although the processor is blindingly fast the software and libraries are not ready , in six or eight months to a year ti will be better. I am redesigning my project to use a Leaf labs maple, a compromise, more pins than UNO, nearly the same speed as DUE, still has a arm processor. The big down fall is all of these Some what zippier devices are 3.3v at low current. This requires more attention to detail when designing a circuit. Careful not to smoke the cpu.

Leaf Labs Maple is a nice board but, it also has some issues. Like the Due there is some give and take. The Due has a bigger support group and I think it will be an amazing tool with some time given to people working with it.

evmaker:
The big down fall is all of these Some what zippier devices are 3.3v at low current. This requires more attention to detail when designing a circuit. Careful not to smoke the cpu.

Unlike with DUE, at least with the chipkit and maple, the inputs are 5v tolerant so that can make
interfacing to 5v devices simpler in some cases.

--- bill

This post is quite old but i wanted some help understanding one difference in Due and Mega.

Is the code written for Mega compatible with Due or will i have to make some changes?

haxan:
This post is quite old but i wanted some help understanding one difference in Due and Mega.

Is the code written for Mega compatible with Due or will i have to make some changes?

Short answer "it depends".
If the code limits itself to not directly touching the internal MCU h/w directly and only uses the
Arduino core library functions or the APIs from the libraries that come with the IDE then the code will work for both.

But by you saying "code written for Mega", I'm assuming you have code that is not really
truly Arduino code in that it violates the Arduino APIs by directly touching hardware.
If that is the case, then no, it will not work on DUE.

That is from a s/w perspective.
Then there is the h/w issue of 5v vs 3v and pin drive capability.

Thanks Bperrybap.

I now understand what you mean. Well i am using a few libraries, some from Arduino and some from other contributors.

Is there anyway i can know if the h/w is being touched in those libraries? I will have to skim these lib files.