7
\$\begingroup\$

Okay, here's some background info leading up to the [obvious] question with further elaboration: I have been using a 28 pin PICAXE for small projects here and there for the last couple of years and am ready to move up. My current project is the PICAXE as a data acquisition module. I have simply mounted the board inside an enclosure, and run the inputs and outputs to [a lot] of screw terminals on the outside for quick and painless component swapping. (And for further visualization, I also built in a 5V regulator and put in a DC jack so i can hook up a universal wall wart for power and wired the USB connection to a mini-usb that can be plugged into from the outside.) Well, interfacing with the computer is pretty much a pain with the PICAXE, and it can only be programmed with their official program.

So, I am going to upgrade to Arduino. I was thinking the Arduino Mega Starter Kit because it seems like the most versatile, and I know that whatever board I get will be the board I will be using for a good while. If I could do it over again, I would have started with the Arduino.

The things I am most interested in is data acquisition and sending data back to my computer, as well automation, which I know will not be an issue. I have experience with C and BASIC but I prefer C; I am not sure if the there is a difference in language across Arduino's or not. So, what would you recommend as the most versatile Arduino that will accomplish my current goals and keep me fat and happy on capabilities for whatever strange things I desire doing next?

As a secondary question: is it possible to interface any (or all) of the Arduino's with LabVIEW?

\$\endgroup\$
0

10 Answers 10

7
\$\begingroup\$

It seems like you've largely answered your own question. The Mega is by far the biggest and most powerful of the Arduinos. Personally I lean more towards quantity instead of quality, so I'd get two less expensive Arduinos. I find the female headers on the arduinos somewhat limiting, so the various breadboard Arduinos tend to get my nod (Really Bare Bones Boarduino and Boarduino). You're usually choosing two things when you pick an Arduino: how many inputs/outputs it has and how to communicate with it. You're obviously on top of the i/o questions, but you might want to think about whether you're going to use USB or serial (probably via USB -> serial adapter) to program the Arduino. If you're only going to buy one or two boards, then USB is the easiest and cheapest. If you're going to end up with 3 or more boards, it's probably cheaper to buy serial-only boards and a separate USB -> serial converter (FTDI cable or FTDI basic breakout board).

The base Arduino is amazingly capable and it's pretty easy to add additional inputs with cheap multiplexer ICs. If you don't have immediate need for the extra inputs, it might be worth starting with a cheaper board.

If you're using the Arduino IDE, then you'll be programming in C++ on all the Arduinos. The Arduino documentation tends to encourage using only slightly more than the C subset of C++ (basically C with just one or two extras), so a C programmer should feel very comfortable. As an added bonus, you can do things like declare variables right before you use them, rather than having to do so at the start of functions. On the other hand, watch out for differences from the C standard library. sprintf("%f", foo) and some other things don't work by default. When in doubt, hit arduino.cc and search.

As for communicating back to the computer, I'm personally using Ruby on Rails to talk to my Arduino projects, but most folks seem to prefer Processing. It all boils down to a serial port, so you can use whatever you feel most comfortable with.

\$\endgroup\$
1
  • \$\begingroup\$ Awesome answer -- I was planning to buy the ATMega which was identified as the biggest, but you hold a very very good point with the multiple cheaper boards and adding inputs if necessary using multiplexers. I think this is the route that I will go. The virtual limitation of pre-built inputs would be greatly made up for by the additional capabilities of having multiple boards. I will be using USB of course until I build something better (bluetooth is in the future, but merely as a serial bridge so not philosophically different than serial->usb). \$\endgroup\$
    – iklln6
    Dec 24 '09 at 19:43
3
\$\begingroup\$

To date, all of the Arduino's and compatible systems consist of a board with an Atmel chip (such as an '168 or 328), a bootloader, a high level library and a cross-platform GUI. The bootloader enables you to download programs developed on the host using the uC serial port. Most people convert the uC serial port to a USB connection using some variety of FTDI USB to serial interface. The serial/USB interface could be used with LabView.

You can use these boards as Arduinos or as embedded systems. Most of these boards have a 3x2 header that conforms to Atmels ICSP specification. Using a USB to ICSP adapter (such as the ATmel AVRISPMKII) you can program the board without the bootloader or the Arduino libraries. There are a wide variety of Atmel libraries that you can use for stand-alone C development. Most of my development is done using the ICSP port, gcc and a Makefile. The Arduino libraries do an excellent job of providing hardware control at a high level. Sometimes the trade-off is performance. In a recent application I noticed a major speed improvement when I changed digitalWrite statements to bitset and bitclear operations.

The correct board depends more on your application --

  1. How many digital I/Os do you require?
  2. Is the uC A/D sufficient accuracy and resolution?
  3. Do you require analog output? What accuracy and resolution?
  4. Do you require signal conditioning?
  5. Do you require isolation?
  6. Do you require timestamping of data on the uC board or can that be handled by the host?
  7. How many serial interfaces do you require? (The last two applications I have done could have used one more UART ;)

If you cannot use the A/D on the uC, and you don't need the UARTs you may be better of with the smaller board. The last large data acquisition system I did used a uC with only a few peripherals. We needed a 16-bit A/D and a 14-bit DAC. There was no sense in paying for an internal 10-bit A/D or 8-bit DAC.

I make a couple of Arduino compatible boards that bring out all the I/O connections to a single header. You can make a system that has co-planar boards, stacked boards, remote boards (one ribbon cable) or a backplane. The backplane could be useful for a data acquisition system that uses peripheral cards. My boards are at http://www.wiblocks.com

\$\endgroup\$
2
\$\begingroup\$

If you are only doing data acquisition the Mega would seem a bit superfluous, unless of course you are using tons of sensors and or need multiple serial ports. I would say that for just simply data acquisition you would do OK with just the Diecimila(again depending on what you actually need to do with it)

\$\endgroup\$
2
  • \$\begingroup\$ I know the Mega is a bit overkill for a simple data acquisition task, but I don't want to be limited if I do get the wild hair to use tons of sensors. A couple years ago I bought the PICAXE setup to build my first robot, but now I wish I would have done more research to get something more full-featured to support the inevitable addiction. I suppose a more appropriate question might have been "What Arduino board has the most functions/features?" but I don't know if that question is unanswerable due to application-specific setups. \$\endgroup\$
    – iklln6
    Dec 19 '09 at 6:36
  • \$\begingroup\$ You could say that the Mega has more features, but your tight it does depend on your setup. If all of your sensors are I2C then there is no difference they can all be controlled via a single I2C bus, which all arduinos have, serial on the other hand is a different story. \$\endgroup\$
    – zklapow
    Dec 19 '09 at 21:33
2
\$\begingroup\$

Answer to your secondary question - yes, there is a free LabVIEW toolkit for Arduino and a whole community on the topic.

\$\endgroup\$
1
\$\begingroup\$

Yeah I would get two regular Arduinos instead of the Arduino MEGA, unless you specifically have a project that requires lots of I/O.

It's easy to make a project you want to keep around, so instead of tearing up your circuit to make a new project, keep it and just get another Arduino. If the cost of a regular Arduino is too much, you can build a Freeduino kit. And if that's too much, you can make a minimal Arduino setup using just an ATmega8, a resistor and a capacitor.

\$\endgroup\$
1
\$\begingroup\$

A slightly different solution to your question is to bear in mind that your PicAXEs are just a preprogrammed PIC,the manual lists the following equivalences:

  • PICAXE-28X1 = PIC16F886
  • PICAXE-28X2 = PIC18F2520 (3V version PIC18F25K20)

and obsolete chips:

  • PICAXE-28A = PIC16F872 (Superseded by 28X1)
  • PICAXE-28X = PIC16F873A (Superseded by 28X1)

So in theory you could get a Programmer which supports these PICs and reprogram them either in C or Assembler, wiping out the PicAXE bootloader and use them as standard PICs. This way you can program your chips with much more flexibility.

So you could take the chip in your datalogger for instance, reprogram it in C to do whatever it is that you want, and replace it in the same circuit. Although you might have to remove the PicAXE programming circuit if you have it in place I don't know how closely it mimics the PICs ICSP circuit (you won't be using the audio jack I think).

\$\endgroup\$
1
\$\begingroup\$

an almost fully functional arduino clone (eg; a duinostamp by Fundamentalogic) can be had for as little as $10-12 ... and once you are done prototyping, it is easy enough to embed it in your project and release it in the wild. Embedding a full Arduino(TM) would be overkill imo. I'd say get the cheapest ones and get an FTDI cable for uploading 'sketches' (via the arduino IDE) etc. You may also want to get an ISP programmer if you plan to put custom bootloaders etc (or just save a buck a chip by burning the bootloader yourself)

I am a beginner and I got the Duemilanove board at first, but ended up getting a boarduino also after playing with the original, as it is much easier to prototype with it right on the breadboard. In the future, I intend to build just the barebones "duino" stamp or equivalent for embedding in any projects.

Arduino(tm) is great to start out with, but I found very quickly that for actual projects that I intend to release into the wild I'd need something more flexible ... and cheaper (plus the female headers can get a bit unweildy, though they're great for beginners)

\$\endgroup\$
0
\$\begingroup\$

Consider some barebones boards in kit form, work nicely with breadboard, very inexpensive. Drawbacks: they are rs232 ttl and do not take shields. Maker shed has some adapters from std 232. Moderndevice.com sources the board. Under 15 dollars as I recally.

\$\endgroup\$
0
\$\begingroup\$

A big advantage to the Mega is that it has more memory and RAM, in particular, is quite limited on micro-controllers. Depending on what kinds of experiments you want to do, you may appreciate the extra flash for large programs and storage of constant strings; and you'll certainly appreciate the extra RAM space for arrays, logs, ring buffers, linked lists, etc., without having to invent compression schemes (quite so often...) to fit into less RAM, especially while you're debugging or testing concepts.

\$\endgroup\$
0
\$\begingroup\$

Another option for a breadboard-based arduino compatible is the Teensy. They have a mini-USB connector so you don't need the external USB to serial, and can be programmed as an Arduino using the free provided code to add to the Arduino IDE (or program as a straight AVR, your choice). They are available with and without the headers for breadboarding. I've used several of these on various projects.

\$\endgroup\$

Not the answer you're looking for? Browse other questions tagged or ask your own question.