Offline
Newbie
Karma: 0
Posts: 12
|
 |
« on: May 09, 2012, 11:10:31 am » |
Dear All I am new for arduino I would like to know, What is the advantage Arduino than AVR.if both use same chips Thanks in advance
|
|
|
|
|
Logged
|
|
|
|
|
Greenville, IL
Offline
Edison Member
Karma: 11
Posts: 1289
Warning Novice on board! 0 to 1 chance of errors!
|
 |
« Reply #1 on: May 09, 2012, 11:24:32 am » |
The advantages, in my opinion is that Arduino is easier to understand, and it is quicker for writing working code. Then, you also have the advantages of examples, and shared knowledge.
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 12
|
 |
« Reply #2 on: May 09, 2012, 11:40:48 am » |
Dear cyclegadget Thank you very much for reply
It would be much appreciated, if you can prove that quicker writhing code using example like LED blinking Thanks in advance
In Assembly using PIC
loop bsf portb,1 call delay bcf portb,1 call delay goto loop
|
|
|
|
|
Logged
|
|
|
|
|
Global Moderator
UK
Offline
Brattain Member
Karma: 138
Posts: 19067
I don't think you connected the grounds, Dave.
|
 |
« Reply #3 on: May 09, 2012, 11:46:15 am » |
delay is a built in function on PIC, is it? Pin modes? Is this a troll?
|
|
|
|
« Last Edit: May 09, 2012, 11:48:41 am by AWOL »
|
Logged
|
Pete, it's a fool looks for logic in the chambers of the human heart.
|
|
|
|
Greenville, IL
Offline
Edison Member
Karma: 11
Posts: 1289
Warning Novice on board! 0 to 1 chance of errors!
|
 |
« Reply #4 on: May 09, 2012, 11:47:02 am » |
I hope he is not fishing... It is quicker for me because, I am not sharp at port control and I have not memorized registers or things like that. I am a Novice but, I do alright using Arduino. To do what you did, I would have to look up things and that is where my time would be. Copy and paste took 30 seconds more or less. /* Blink Turns on an LED on for one second, then off for one second, repeatedly. This example code is in the public domain. */
void setup() { // initialize the digital pin as an output. // Pin 13 has an LED connected on most Arduino boards: pinMode(13, OUTPUT); }
void loop() { digitalWrite(13, HIGH); // set the LED on delay(1000); // wait for a second digitalWrite(13, LOW); // set the LED off delay(1000); // wait for a second }
|
|
|
|
|
Logged
|
|
|
|
|
Left Coast, CA (USA)
Offline
Brattain Member
Karma: 279
Posts: 15316
Measurement changes behavior
|
 |
« Reply #5 on: May 09, 2012, 11:51:53 am » |
Dear All I am new for arduino I would like to know, What is the advantage Arduino than AVR.if both use same chips Thanks in advance
Advantage include: 1. Easy to use and free IDE, available in all popular PC operating systems. 2. Access to many arduino supplied C/C++ libraries and functions as well as a world of 3rd party contributed C/C++ libraries and functions. 3. Help is always available from this very friendly forum. What more could a newcomer ask for? Lefty
|
|
|
|
|
Logged
|
|
|
|
|
Anchorage, AK
Offline
Sr. Member
Karma: 10
Posts: 492
|
 |
« Reply #6 on: May 09, 2012, 12:49:57 pm » |
If you're into assembly, and you're OK with using binary logical operations to toggle ports, you may feel like the Arduino is more of a toy. The IDE is meant so you can write code, click a button, have a working project. It's honest-to-gosh C/C++, but there are many tricks that go on behind your back so you don't have to mess with the gory details. If you like gory details, and you feel more comfortable knowing how something happens, rather than just accepting that it does, you'll get frustrated with the Arduino IDE.
The AVR (non-Arduino) is more like PIC. If that's what you're comfortable with, the only advantage to the Arduino is the collection of excellent drop-in code libraries and examples.
|
|
|
|
|
Logged
|
|
|
|
|
Austin, TX
Offline
Faraday Member
Karma: 41
Posts: 5172
CMiYC
|
 |
« Reply #7 on: May 09, 2012, 07:34:59 pm » |
What is the advantage Arduino than AVR.if both use same chips Arduino uses an AVR chip. AVR is another name for ATmel microprocessors, so your question doesn't make any sense.
|
|
|
|
|
Logged
|
|
|
|
|
universe
Offline
Sr. Member
Karma: 0
Posts: 258
I'm enjoying my Life
|
 |
« Reply #8 on: May 11, 2012, 03:25:12 am » |
Dear All I am new for arduino I would like to know, What is the advantage Arduino than AVR.if both use same chips Thanks in advance
A lot of people use Arduino, they are kind to share and help, that is the 1st! Connection is simple, only use a USB type B cable compare with AVR Butterfly A lot of example application in the web The code is much easier yah to be understood I love the color, the name, the nation (Italy),I love pizza Everyday, the user increases, it motivate me to improve and improve I love open source! It's very welcome to answer you 
|
|
|
|
|
Logged
|
|
|
|
|
Manchester (England England)
Offline
Brattain Member
Karma: 277
Posts: 25506
Solder is electric glue
|
 |
« Reply #9 on: May 13, 2012, 09:23:14 am » |
if you can prove that quicker writhing code What sort of prof do you want with code so ridiculously simplistic as that! It is like asking for the simplest "hello world" example to compare languages, it tells you nothing useful.
|
|
|
|
|
Logged
|
|
|
|
|
Netherlands
Offline
Tesla Member
Karma: 90
Posts: 9401
In theory there is no difference between theory and practice, however in practice there are many...
|
 |
« Reply #10 on: May 13, 2012, 02:19:58 pm » |
It is like asking for the simplest "hello world" example to compare languages, it tells you nothing useful. not agree ] It can tell you something about how stdio is implemented, what a minimal program looks like, if strings are native supported, maybe if compiled what the minimal exe size is, but yes, it is only a drop in the ocean of things to know about a language  see - http://c2.com/cgi/wiki?HelloWorldInManyProgrammingLanguages -
|
|
|
|
|
Logged
|
|
|
|
|
SF Bay Area (USA)
Offline
Faraday Member
Karma: 78
Posts: 5454
Strongly opinionated, but not official!
|
 |
« Reply #11 on: May 13, 2012, 05:47:01 pm » |
In Assembly using PIC But you didn't include the code for delay ! And it won't work because you haven't set TRISB so that the pin is an output, and you haven't properly handed selecting the correct bank for portb (may not be necessary on some PICs.) Please rewrite your example such that it will blink any digital output pin on the chip (any port, any bit) with a variable delay specified in milliseconds (accurate to +/- 1ms), and THEN compare to the Arduino Blink example...
|
|
|
|
|
Logged
|
|
|
|
|
Canada
Offline
Full Member
Karma: 0
Posts: 246
Code Monkey
|
 |
« Reply #12 on: May 13, 2012, 09:19:35 pm » |
It is like asking for the simplest "hello world" example to compare languages, it tells you nothing useful. not agree ] It can tell you something about how stdio is implemented, what a minimal program looks like, if strings are native supported, maybe if compiled what the minimal exe size is, but yes, it is only a drop in the ocean of things to know about a language  HelloWorld makes for some interesting ad hoc comparisons, but it really doesn't say much beyond that. Simple terminal I/O and the notion of "strings" are not nearly universal enough for all the different computing environments a language can be designed for. Even common OO languages implement a String in vastly different ways that is not apparent at all when you look at the syntax and grammar.
|
|
|
|
|
Logged
|
I yield() for co-routines.
|
|
|
|
0
Offline
Faraday Member
Karma: 16
Posts: 3196
20 LEDs are enough
|
 |
« Reply #13 on: May 13, 2012, 10:52:29 pm » |
It would be much appreciated, if you can prove that quicker writhing code using example like LED blinking Thanks in advance
1) You can not write code quicker with Arduino. 2) Arduino is simpler because of the IDE that works out of the box most of the time. Thus the entry barrier is lower for beginners. If you are an expert you may still use an Arduino because of the shields or just because you have one lying around. But if it is simpler or not *for your tasks* is your decision. Any questions like is A better than B without defining what exactly the meaning of "better" is are basically pointless. Especially in cases where A is a part of B.
|
|
|
|
|
Logged
|
|
|
|
|
SF Bay Area (USA)
Offline
Faraday Member
Karma: 78
Posts: 5454
Strongly opinionated, but not official!
|
 |
« Reply #14 on: May 14, 2012, 01:21:34 am » |
The other thing is... I give you three "virgin" computers; one with MacOSX, one with Linux, and one with windows. Get a "blink" example written, compiled, and loaded onto a microcontroller, using each one. This is actually not as bad as it used to be for PIC, since MPLAB-X now runs on MacOSX and Linux, but I'd still bet it would go faster using Arduino.
|
|
|
|
|
Logged
|
|
|
|
|
|