Save us from the Arduino, or not? - Page 1
Forum section: electronics / general

author: Chet T16
author_rank: Frequent Contributor
timestamp: April 30, 2011, 07:28:39 pm
content: I, like countless others, are starting out with electronics and microcontrollers and the first and easiest step seems to be the Arduino.Its always seemed to me that people who knew what they were doing were very critical of the arduino, whether this was because it was a "toy" or because it was allowing "normal" people do stuff that was normally only accessable to them!So...my question is, should I try wean myself off my arduino habit and learn to do it "properly" or do you think its perfectly acceptable to stay inside the bubble?Or an even easier question, are you critical of arduino based projects?

author: Trigger
author_rank: Regular Contributor
timestamp: April 30, 2011, 07:37:46 pm
content: If you're just doing an electronics project the Arduino is fine. If you want to get to the point where you can design your own custom boards for projects skip it and learn to program PICs/AVRs/MSP430s/etc in C. It's a larger learning curve but you'll learn the industry standard and be better off in the end.

author: Chet T16
author_rank: Frequent Contributor
timestamp: April 30, 2011, 07:43:46 pm
content: Just seen my typo :/Personally i'm just finishing the second year of a four year electronic engineering course so industry standard sounds good. That said, anything i've done with microcontrollers has been in my own time on my own little projects. I'm not sure whats covered in university in later years but we have done two modules in C and one in C++, nothing overly complicated which is perhaps why i took to the arduino

author: Trigger
author_rank: Regular Contributor
timestamp: April 30, 2011, 08:06:31 pm
content: Also FYI if you sign up on Microchip direct with a .edu account you'll get a 25% discount on all developer tools.

author: armandas
author_rank: Frequent Contributor
timestamp: April 30, 2011, 09:28:40 pm
content: Quote from: Chet T16 on April 30, 2011, 07:43:46 pmSince you're an EE student and not a musician or an artist, you should definitely go for proper stuff. I personally have (almost) nothing against the Arduino hardware, but the software side (wiring, sketches, whatever) is useless if you want to learn how things work. If you're quite new, it may be good to have a small dev board like Arduino, but do yourself a favour and use C to program it.

author: jasonh
author_rank: Contributor
timestamp: May 01, 2011, 03:42:35 am
content: This is a timely question for me as well although I don't understand a couple of the responses. This is probably due to the fact I don't know a lot about arduino.I would like to ask some more questions in response to the answers so I can understand when I might hit a wall with arduino.I started using C more than 25 years ago and java more than 15 so sketches or C is not a barrier for which way I go.I did have something going in arduino at a much faster rate than I had something going on my atmel STK500 board. The libraries in arduino seem to cover what I have plans to use it for, i.e. steppers, servos, spi, i2c etc..I have the uno board as a quick way to start but my understanding is that I can load the bootstrap on to any supported atmega chip and drop it in to my own PCB. To me the adruino boards may be quick for prototyping but should not limit how you want to place the components on your own board.So, what I don't understand is at what point will I feel like I can't get by? The IDE feels light and I have not explored how you do debugging but at the hardware level, what do I loose by using the arduino environment on the atmel chips?Now, if I was like the OP and may want a future in microprocessor development then I would say yes, learn the 'proper' way as well but for myself where this is a hobby, is there any real disadvantage?Thanks,Jason

author: Trigger
author_rank: Regular Contributor
timestamp: May 01, 2011, 05:53:23 am
content: Quote from: jasonh on May 01, 2011, 03:42:35 amIf you already know C it's trivial to learn how to manipulate microcontroller registers which is a universal skill that applies across embedded programming.The Arduino is made for non-technical people and it hides a lot from programmers. That makes it very easy to use and learn with the downside being that you are locked in to only the chips supported by Arduino, and those chips are limited in flexibility by the presets Arduino imposes. You don't have the ability to access advanced chip functions such as PicoPower by default or the ability to manipulate the pins in more detail. There is a lot of functionality in those chips that Arduino doesn't even touch.Register manipulation and C is pretty much universal across microcontroller meaning that your skills become portable. If there is a Freescale chip that is perfect match for your project you can grab some example code to see how the compiler wants its syntax and then grab the datasheet to look up the registers you need to change and get coding.The Arduino is a great tool for hobbyists and artists, it's easy to use and learn, but it's limiting when it comes to engineering applications. I'd rather have the ability to pick the microcontroller that best fits my project.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 01, 2011, 06:09:09 am
content: Quote from: Trigger on May 01, 2011, 05:53:23 amwhat if people want (and choose) to lock themself in? what if they not choose to become engineer, they choose to become artist? dont they have a place here? or anywhere else as long as electronics engineering is discussed?

author: Trigger
author_rank: Regular Contributor
timestamp: May 01, 2011, 06:25:58 am
content: Quote from: Mechatrommer on May 01, 2011, 06:09:09 amStill selectively reading I see you totally missed the"The Arduino is a great tool for hobbyists and artists, it's easy to use and learn, butit's limiting when it comes to engineering applications.I'd rather have the ability to pick the microcontroller that best fits my project."ThenQuote from: jasonh on May 01, 2011, 03:42:35 amI answered the question. I at no point said the Arduino had no place, just stating its limitations when trying to go past hobby uses as asked.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 01, 2011, 06:36:20 am
content: 1) you made quite a lengthy point2) i dont selectively reading. i read all your 10 points, and i'll ignore the nine, to make it simpler to discuss 1 point with you.3) even with my simple statement, it is you that miss my simple point... sure you did indicate arduino is for artist and hobbiest. what i asked iswhat if people want to lock themself in as an artist or hobbiest?read carefully before replying intelligently. i learnt that trick long time ago. and my previous post is questions, not points. a simple question should get a simple answer, or none at all.Quote from: Trigger on May 01, 2011, 06:25:58 am

author: Trigger
author_rank: Regular Contributor
timestamp: May 01, 2011, 06:52:02 am
content: Quote from: Mechatrommer on May 01, 2011, 06:36:20 amApologies then, I missed your question. Your English threw me off a bit and you likely missed the non-literal meanings of my statement. In saying that the Arduino is great for hobbyist and artist use it carries the implication that it's perfectly acceptable to invest in the platform.

author: kenster2001
author_rank: Newbie
timestamp: May 01, 2011, 06:54:53 am
content: If you are intent on learning the inner workings of microcontrollers, I would recommend trying assembly language first. It really aids in understanding how they work.Using the disassembler and understanding the output helped me write faster and shorter programs in C as well.

author: jasonh
author_rank: Contributor
timestamp: May 01, 2011, 07:06:40 am
content: OK, I understand there are some things that may not be accessible but it seems like a lot of things are covered, I think for my own projects it will do everything and to be honest what I want to do is just something that there are many existing products available, i.e. the telescope control and flight sim panels/moving platforms.I am going to have a wild guess that if I wanted to implement my own version of a lot of commonly bought items that use microcontrollers that it would only be a small percentage of products that I could not actually replicate in arduino.I say that based on the fact that I can program it using c/c++ and have access to all the pins for digitaio io and analog.So, you are probably correct to say there are features that may not be accessed but I wonder how often those features are the difference between can do the project or cannot do the project?Lol Ken, I am guessing your contribution is a bit of lighter fluid and that you are not serious.

author: Trigger
author_rank: Regular Contributor
timestamp: May 01, 2011, 07:38:39 am
content: Quote from: jasonh on May 01, 2011, 07:06:40 amIf you're just doing it for a hobby and not aiming to be an engineer then it fits your need perfectly. You'll likely only hit a snag if you're trying to do something more advanced like make an ultra low power project to do something like log sensor data for years using a 3v coin cell. If you stay within the limitations of the boards they can do some surprising things. I have a few Uno boards in my parts drawer for the times I need to rapidly put something together.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 01, 2011, 08:10:17 am
content: Quote from: Trigger on May 01, 2011, 06:52:02 amsame to me, apologize. 1st i'm not native english and culture, like many others here, so my english can be easily misinterpreted, but i'll try my best. 2nd i only like to provoke an idea instead of holding strong to my own. i hope this can become a harmonic and educative discussion.

author: JohnS_AZ
author_rank: Frequent Contributor
timestamp: May 01, 2011, 07:38:34 pm
content: IMHO ...1) Do -NOT- wean yourself off of the Arduino.2) -DO- learn other uC's and programming languages.Some applications are software intensive, and there are probably better choices than the Arduino. Some other applications are sensor and/or peripheral intensive and software light. An Arduino might be a perfect part for that.The thing is, and really my bottom line, you can NOT know too many micro-controllers or programming languages (including assy). They are like tools in your tool box. You might not need any one of them often, but when you do it's great to have it at hand.John

author: Chet T16
author_rank: Frequent Contributor
timestamp: May 01, 2011, 07:58:00 pm
content: I'm perfectly willing to learn others, i was afraid that using them might in some way contaminate me when i tried to branch outOf course when i say Arduino i don't mean i stick an Uno in everywhere i'm using a microcontroller.It seems to me the microcontrollers are so cheap we can stick them everywhere. When i was looking at doing the fuel injector pulser i've spoken about elsewhere i started off basing it around two 555 chips and i was calculating capacitances and resistor/pot values to vary the output. But then i thought about it and sticking an attiny85 (using arduino) in there gives a negligible cost difference and is far more flexible.Can someone give a concrete example of what i could do with an non-arduino atmega328 that the arduino couldn't do?

author: jasonh
author_rank: Contributor
timestamp: May 01, 2011, 09:39:33 pm
content: For that particular chip, possibly qtouch is unavailable, otherwise I am not sure there is anything you could not do unless you used up all the ram and needed the small footprint that arduino used.

author: Trigger
author_rank: Regular Contributor
timestamp: May 02, 2011, 08:21:39 am
content: You can't make a data logger that will run for 2+ years on a single 3v coin cell or better yet run indefinitely off micro energy harvesting. PicoPower is available on the chip that's on the Uno board. Yes you can turn it on but you'll be using register manipulation, not the Arduino libraries.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 02, 2011, 09:31:36 am
content: having knowing the arduino IDE library is not that efficient, limiting and less controllable (never dig into the library mechanism though), i figured out how to program it from AVR Studio (better C and ASM capable) and bought me a decent avr programmer in case i want to progam a bare chip. and yeah! we need to think of extra cost that will be involved if we want to learn a new chip. i wish there's dev board for spartan or arm (incl prorammer) that cost as much as Arduino

author: jasonh
author_rank: Contributor
timestamp: May 02, 2011, 10:59:12 am
content: Yes trigger, you are correct. I was looking at the 328 datasheet and the uno does have the 328p.

author: Tony R
author_rank: Regular Contributor
timestamp: May 04, 2011, 02:37:15 pm
content: Arduio is a great product, but putting on a resume that you know how to program Arduio probably wont in and of its self get you a job. If you look at what the industry is using these days it would be the ARM. The ARM is a very powerful platform and it is used in almost all mobile electronics.So Arduio is good, but learn something a little more advanced and up to what industry is using today.I also am personally a fan of assembly, not many are, it is kind of a small group of us who get some enjoy out of pulling our hair out. Assembly code is still used today and i don't think it will go away any time soon. People who can program in assembly will probably find jobs because not many can and companies still have to update old software to C and need some one who knows assembly so they can translate, or for some applications assembly is the best rout to go.With all that said about assembly, maybe you should try to pick some up. My first experience was with the 8051f040 from Silicon Labs a good text book that one of my professors wrote is the Embedded System Design with C8051 by Han-Way Huang. It is a textbook so it is spendy but has both C and assembly code. Although the 8051 is of the old CISC architecture, if you can manage learning a CISC right away and all the complexity of the 8051, you should be fine with most other assembles.

author: Harvs
author_rank: Super Contributor
timestamp: May 06, 2011, 12:14:27 pm
content: What can you not do with the arduino? Well the truth is, if you go to the trouble of reconfiguring, not much.I've been using AVRs for many years in various projects and recently bought an arduino for some rapid interface development.You should understand that the arduino is just a normal AVR, with an amount of the configuration simplified. So you can effectively reconfigure most things beyond what the makers of arduino ever intended you to, to access chip features. The problem with that is, you'll get to a point where the arduino libraries become more a hinderance than a positive.The difference between arduino and using an AVR with straight GCC isn't coding complexity, at the end of the day it's all GCC. It's when you go to straight GCC, you actually need to read the datasheet and learn how the uC works and is configured. This is the same for any other uC, PIC/TI etc.It's got nothing to do with one way or the other being "proper" or not. It's just how much do you want to abstract yourself away from the hardware of the uC.But I guess a few things I find fundamentally more difficult to do with Arduino vs straight GCC:- Fully customise timers to my application (as arduino wants them for other things.)- Calculate and optimise time critical routines, in AVRstudio with its simulator you can step through code and look at the number of cycles to complete a routine.- In line assembly, simply for the reason above. If I'm using assembly it's usually for a small time critical part of the code like an interrupt service routine, here time tracking I think is critical.- Simulation of all the registers. AVRstudio has a cool simulator for the 8-bit AVRs where you can see all the peripheral registers step by step.- and finally of the things off the top of my head, the ability to use a in-circuit debugger. In this case I use the AVRDRAGON, it's cheap and works well.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 06, 2011, 03:57:47 pm
content: Quote from: Harvs on May 06, 2011, 12:14:27 pmdo you mean arduino hardware? or arduino IDE (software)? all the previous posts... i read "arduino" as "arduino hardware". that maybe i misunderstood.

author: sacherjj
author_rank: Frequent Contributor
timestamp: May 06, 2011, 04:56:49 pm
content: Quote from: Mechatrommer on May 06, 2011, 03:57:47 pmArduino generally means the programming environment for the Arduino Boards. The boards are the Uno, Mega, etc.When the abstraction is done for the boards, many assumptions are made. Clock speed, pins for certain functions, interrupts that you don't have access to if you use certain Arduino helper function.I think the Arduino is great to learn how to interface circuitry with a micro. It can be used as a stepping stone and may be as much as you will ever need. But if it isn't, just realize that you will need to learn how to configure the micro at a lower level and modify or roll your own code to do the cool things that Ardiuno functions did for you.You can get slight customization with making new hardware description files for Arduino. But to get all features of the chip, you gotta go lower level.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 06, 2011, 05:47:56 pm
content: now i remember! its the Arduino who responsible for me being stuck in this parasitical capacitance matter!

author: Harvs
author_rank: Super Contributor
timestamp: May 10, 2011, 10:44:42 am
content: Quote from: Mechatrommer on May 06, 2011, 03:57:47 pmSorry for the delayed response, I've been away drinking red wine for a few daysI am refering to the Arduino development environment (aka software). The only real hardware restriction is using supported parts. Otherwise you can develop on a specific arduino board if you wish, or just load the bootloader onto a bare uC and place that in a circuit of your design. So no real difference to using any other type of device.I think most of the other posts are largely referring to the arduino software environment, because hardware wise there isn't really any significant difference to any other AVR development board (other than the widely adopted stacking thing.)