Shop OBEX P1 Docs P2 Docs Learn Events
Arduino, gaining foothold in education market? What can Parallax and the Prop d - Page 5 — Parallax Forums

Arduino, gaining foothold in education market? What can Parallax and the Prop d

1235711

Comments

  • LeonLeon Posts: 7,620
    edited 2010-08-03 08:51
    Also, the Propeller has to be programmed in assembler to achieve the same speed as the Arduino, which is programmed in C. In most cases, the eight processors on the Propeller aren't used for parallel processing but to implement peripheral devices, which are available in hardware on the Arduino. I'd guess that 90% of Propeller applications could have been done just as easily, and a lot cheaper, on an Arduino.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM

    Post Edited (Leon) : 8/3/2010 9:46:43 AM GMT
  • RavenkallenRavenkallen Posts: 1,057
    edited 2010-08-03 17:42
    @ Leon...Wait, the Arduino runs at 20 million IPS. Assembly is more efficient than C, but a lot harder to code. If the Arduino is that fast than the Prop doesn't stand a chance


    @BradC... Well, you are right about the larger memory, but a lot of people just add more anyway.....

    I am not trying to seem like a know-it-all, but WHEN the 8 cores of a prop are used in Parallel(And in assembler), the Arduino can't keep up. It's not that i don't like the Arduino. I'm just saying that for SPEED, sheer speed. The Arduino can not keep up. Sure there are some things that the Arduino might have on Prop....Size, few external components, Built in ADC and more I/O pins(for the Arduino Mega).... Can you think of one specific application where the Propeller couldn't do it better?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller + Picaxe = Romeo & Juliet
  • LeonLeon Posts: 7,620
    edited 2010-08-03 17:50
    Have you actually seen a real-world application which achieves 160 MIPS on a Propeller? There isn't one.

    Can you name an Arduino application that would run better on a Propeller?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM

    Post Edited (Leon) : 8/3/2010 5:55:02 PM GMT
  • RavenkallenRavenkallen Posts: 1,057
    edited 2010-08-03 18:25
    No, i a cannot think of a real world application that uses 160 MIPS per second, but It is there? Yes. And it CAN be used. A lot of the 80's computer emulations that the guys do here would be very hard to do on the Arduino. While i could name a few specific ones, A lot of robots could benefit from having 8 things going at once(Even the Robot that i made myself). One core for drive systems, one for vision sensors, one for tactile/ buttons, perhaps a wireless/infrared communications core, a synchronizer core and perhaps a couple more which could be called upon for fast processing of math laden stuff. Plus, one core can watch over the others and if one hangs for some reason the main core can correct the problem....I have an Arduino and occasionally i play around with. I like some things about it, but still overall i like the Prop better. I also love the Pixace. They are even cheaper and easier to use than the Arduino(although not as fast), For programs that need a lot of program space/ Speed i would still use the Prop....Call it blind loyalty, but its not. So Can the Arduino really execute 20 MIPS IN C? I thought C was a rather bloated language compared to others? I would actually have to investigate it more if it could.... I know you know quite a bit more about stuff than i do so lets do this, how about you name the Main features of the Arduino. Why do you like it better?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller + Picaxe = Romeo & Juliet
  • LeonLeon Posts: 7,620
    edited 2010-08-03 18:45
    It isn't possible to achieve 160 MIPS with a Propeller application! I don't see the relevance of the various emulations of obsolete computers and operating systems to embedded systems design.

    The gcc compiler is quite efficient, and MIPS are the same whether the code is generated by a compiler or an assembler.

    The AVR actually approaches 20 MIPS, as most instructions are single-cycle.

    I don't like the Arduino any better than the Propeller or any other system, I use whatever best suits the application.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM
  • RavenkallenRavenkallen Posts: 1,057
    edited 2010-08-03 19:00
    Well, you make it sound like that everything is better than the Prop. By saying it could only beat it one or two days of the week or only 15-30% of the time(If you count sundays, haha) is an exaggeration...So the ATMEGA328 can really execute 20 million C instructions per second with a 16 MHZ clock?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller + Picaxe = Romeo & Juliet
  • LeonLeon Posts: 7,620
    edited 2010-08-03 19:11
    Define "better".

    The AVR needs a 20 MHz clock, if it is going to get close to 20 MIPS. It can't execute 20 million C statements a second, of course. Some C statements will compile to a single assembler statement, but most of them won't.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM
  • mparkmpark Posts: 1,305
    edited 2010-08-03 19:16
    Leon said...
    I'd guess that 90% of Propeller applications could have been done just as easily, and a lot cheaper, on an Arduino.

    90% seems pretty excessive. I'd bet that more than 10% of Propeller applications use video, and I don't think video is easier or cheaper on Arduino.
  • RavenkallenRavenkallen Posts: 1,057
    edited 2010-08-03 19:19
    Faster, cheaper, smaller...ect.
    So what kind of speed could you expect with a "regular" Arduino with 16 MHZ clock? Cause that is what most Arduino's have.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller + Picaxe = Romeo & Juliet
  • LeonLeon Posts: 7,620
    edited 2010-08-03 19:35
    The Propeller can execute code faster than an AVR, say. It might not have as much memory. It will cost a lot more. It might be a lot bigger. It doesn't really matter, one selects the device that best suits the application; it might be a Propeller, it might be something else.

    An AVR with a 16 MHz clock will deliver something approaching 16 MIPS.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM
  • RavenkallenRavenkallen Posts: 1,057
    edited 2010-08-03 22:17
    Well, i was mainly talking about speed. Not really cost, size, program space, ram....That is all i was saying.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller + Picaxe = Romeo & Juliet
  • Martin_HMartin_H Posts: 4,051
    edited 2010-08-05 02:16
    Quick question.

    Since the Arduino is an 8 bit processor and the Propeller is 32 bits, wouldn't the Propeller be faster even if they were clocked identically and the Propeller had a single core? 8 bit assembler is going way back for me, but adding quantities larger than your register size required using several add with carry operations, while a 32 bit processor can add them with a single instruction.
  • Nick McClickNick McClick Posts: 1,003
    edited 2010-08-05 04:15
    Propeller instructions usually take 4 clocks to execute, hub operations can take up to 22. I believe AVR instructions execute in a single clock. But that's only comparing assembly. Arduino is compiled C, which will be much slower. A single prop cog will run 20 mips, an ATmega 168 will run 16 mips. It's apples-to-oranges, but the prop is pretty fast.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Forums RSS Feed!

    Gadget Gangster - Share your Electronic Projects
  • BradCBradC Posts: 2,601
    edited 2010-08-05 04:44
    Nick McClick said...
    A single prop cog will run 20 mips, an ATmega 168 will run 16 mips.

    That's a valid statement if the code being executed fits into the cog in its entirety and never references the hub.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "I mean, if I went around sayin' I was an emperor just because some moistened bint had lobbed a scimitar at me they'd put me away!"
  • LeonLeon Posts: 7,620
    edited 2010-08-05 05:24
    The Mega168 will actually run at close to 20 MIPS. Most Arduinos use a 16 MHz clock, though. Compiled C isn't much slower than assembler on chips like the AVR. It is a lot slower on the Propeller, though.

    A 32-bit processor can do some things faster than an 8-bit device, it depends on the application.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Leon Heller
    Amateur radio callsign: G1HSM

    Post Edited (Leon) : 8/5/2010 5:30:02 AM GMT
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-05 05:37
    I'm not sure why people assume that C will run so much slower than assembly. The C code is getting compiled to machine code, after all.

    The ATmega168 can run up to 20 MIPS according to the datasheet.
  • Nick McClickNick McClick Posts: 1,003
    edited 2010-08-05 07:06
    I haven't done the analysis myself, but it looks like C runs about 1/20th-1/50th the speed of native assembly on AVR.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Forums RSS Feed!

    Gadget Gangster - Share your Electronic Projects
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-05 07:55
    That article isn't claiming that C runs about 1/20th-1/50th the speed of native assembly on AVR. It's claiming that the Arduino library functions digitalRead() and digitalWrite() are 1/20th-1/50th the speed of direct port access.

    Since the author doesn't state either way whether the direct port access was done in C or ASM, I think that in the context of the experiment, it's safe to assume that it was in C. Here is an example for comparison: iamsuhasm.wordpress.com/tutsproj/avr-gcc-tutorial.

    The "Arduino" can correctly be considered a system, but at a fundamental level the "standard" Arduino (currently the Duemilanove) is simply a convenient carrier board for the ATmega328. If somebody wants to use the Arduino IDE & libraries with all of the included "syntactic sugar", it's easy to do. However, if they feel like using something like AVR Studio and getting as low-level with C as they can, that option is available. As is ASM if it's absolutely needed.
  • Martin_HMartin_H Posts: 4,051
    edited 2010-08-05 12:05
    The C language is one of the lower level of the high level languages, and compilers have generally matched hand assembly since the mid 80's. If there's a large gulf in performance between C code and hand assembler then you either have a bad compiler or a programmer. This especially true for RISC CPU's that have dual issue and out of order instruction issue. In the early days of RISC CPU's I used to read the C compiler's output to get tips on optimization. At some point I stopped reading the output and went pure C.

    However, the Propeller sounds like a special case because of its unique architecture.
  • Nick McClickNick McClick Posts: 1,003
    edited 2010-08-06 12:49
    You're right - C isn't as crappy as I thought it was. I've been looking at a few different analysis & it looks something like 90% of the speed of assembly. The Arduino, though, is much slower than assembly. So is spin.

    I wonder why Spin is so much slower... probably because it's interpreted.
  • GranzGranz Posts: 179
    edited 2010-08-12 23:02
    I must admit that I have long been intrigued by the Arduino. My biggest problem with that system is similar to my problem with BB guns. For decades, my kids have asked me to let them get BB guns; my response has always been: I don't want a play gun in my house. If you want a gun, get a real .22 or .38 and learn proper gunmanship. If you have a pretend gun, you will learn to use your gun poorly.

    In the same way, if you want to use a microcontroller, get a real one. The Arduino limits what pins you can use for I/O and how they may be used. In addition, the Arduino uses a non-standard dialect of C and people create "sketches" rather than write programs (learn proper terminology, not a made-up new term to replace the decades-old word "program"). I would rather have full use of the pins and program in standard C (or BASIC, or FORTH, or CoBoL, or whatever) than learn non-standard stuff. Although after over 35 years of using and working on computers, it would not throw me too bad, I want to stay mainline.

    I really like the AVR family and use it in a lot of my products, but (even though I am sorely tempted) I have managed to avoid the Arduino - for now. However, with all the fans out there, I will probably get one some day :eek: (I just like playing with all sorts of different computer stuff - and my problems with Arduino are not all THAT strong ;) )
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-13 01:56
    The Arduino pinouts are based on the underlying hardware configuration of the ATmega328. Don't be fooled by the "marketing speak" of using any pins for any purpose. There are like billions of devices out the running just fine with fixed pin configurations.

    As for programming one, if you don't want to use the Arduino IDE, then get a $35 AVR ISP mkII and download AVR Studio (free) and program via the ICSP header. And the Arduino does not use a non-standard dialect of C. The code that you write in a sketch is proper C and/or C++, or GCC won't compile it.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2010-08-13 03:03
    Okay..........
    Now that you mention "marketing-speak", I would like to point out the Arduino Paradox of "open-source" on a device that can protect your code in the finished product.

    The Propeller is true open-source, whilst any developer for profit can jump in and exploit the open-source communities resources and then hide his dirty work in the finished product as machine code which is hardware protected from examination.

    It seems part of the popularity of Arduino is that some of the users can have it both ways. I'd have to say 'Arduino Open-Source" is somewhat misleading.

    BTW, there are times that reassignment of pins to more generic use saves one the cost of having to buy a processor with more pins. As I recall, my engineering exam had a whole section on 'Engineering Economics', good design is cost effective.
  • LeonLeon Posts: 7,620
    edited 2010-08-13 03:22
    You can use the Arduino pins for anything you want, there is no restriction in the hardware. You just need to create your own shields and write the code using a standard AVR compiler, or assembler.

    The Propeller simply won't be attractive to the sort of people that use the Arduino, it's a completely different market.
  • Kevin WoodKevin Wood Posts: 1,266
    edited 2010-08-13 04:00
    AVR never made any claims whatsoever that the ATmega is open sourced, and the ability to protect the code rests in the ATmega microcontroller, and has nothing to do with the Arduino. The fact that the Arduino uses an AVR microcontroller does not make their project nor products closed source. They make their work available for anybody that wants it.

    Now, to call the Propeller true open-source is just plain wrong. Parallax has made some parts of the Propeller available, such as the Spin interpreter, but has in no way licensed all there is for the Propeller under any of the many available open source licenses.

    For the end user to not be able to protect their code is not open source. The topic of code protect was brought up years ago when the Propeller was announced, and there was all of this yada yada yada about there being no code protect & software patents & "true openness", and you know what? It's really just a bunch of Smile. The fact is, using "true openness" as a justification for no code protect for the end user, on a product that the manufacturer protects their own intellectual property, is a double-standard, to word it politely.

    And whereas the Arduino folks have no say whatsoever over AVR's intellectual property, Parallax has full control over their intellectual property. And I have yet to see Ken post the Propeller VHDL or Verilog or whatever they used for the Propeller under an open source license. Nor has the code for the Propeller tool been posted to SourceForge.

    The Propeller is not true open source. It's not even false open source. It's a closed source, proprietary product owned, controlled, and produced by Parallax. And if Parallax wants to produce their own Arduino clone, they're free to do so, and all of that they need to do so is on the web. But if somebody wants to produce their own Propeller, well, somebody post the links...

    FWIW, I have no problem with Parallax opening or closing their products. Either way, they have both supporters and detractors, and it's their decision to make. But I'm calling BS on the idea that the Propeller is true open-source. It's not.
  • LeonLeon Posts: 7,620
    edited 2010-08-13 04:39
    There are true open source processors, many of them are on the OpenCores web site in the form of VHDL or Verilog code that can be implemented on a suitable FPGA:

    http://opencores.org/projects?cat=10&lang=0&stage=0&lic=0

    As Kevin as pointed out, the Propeller isn't open source in the same way as those devices. Neither is the Atmel ATMega328, come to that.

    The only thing that is open source about the Propeller seems to be the Object Exchange. All the source code for the Arduino development software is available, and hardware designs such as that for the Duemilanove may freely be copied by anyone. All the Eagle design files are in the public domain. Parallax has not made any of their PCB designs available, or the source code for their development software. There's nothing wrong with that, of course; Parallax has to make a profit.

    XMOS has also made the source code for their development software available, as well as the PCB design files for most of their development boards. They serve as reference designs, and are very useful.
  • schillschill Posts: 741
    edited 2010-08-13 05:11
    Granz wrote: »
    In the same way, if you want to use a microcontroller, get a real one. The Arduino limits what pins you can use for I/O and how they may be used. In addition, the Arduino uses a non-standard dialect of C and people create "sketches" rather than write programs (learn proper terminology, not a made-up new term to replace the decades-old word "program"). I would rather have full use of the pins and program in standard C (or BASIC, or FORTH, or CoBoL, or whatever) than learn non-standard stuff. Although after over 35 years of using and working on computers, it would not throw me too bad, I want to stay mainline.

    I really like the AVR family and use it in a lot of my products, but (even though I am sorely tempted) I have managed to avoid the Arduino - for now. However, with all the fans out there, I will probably get one some day :eek: (I just like playing with all sorts of different computer stuff - and my problems with Arduino are not all THAT strong ;) )

    I don't really see how something like this

    http://www.evilmadscientist.com/article.php/diavolino

    or many other variations of Arduino hardware are not standard microcontrollers (I purposely chose one that looked "evil" for effect). There are no limits on how pins can be used. The only hardware connected to any pins are the ftdi chip (not on the board linked above) and an LED on (Arduino digital) pin 13. You can program it with any language that works with the AVR and use bootloaders or an ISP.

    For quick and dirty stuff, I don't have any problems with the Arduino IDE and language. Some of the functions aren't very efficient (digital I/O) but you can access lower level stuff if you want to.

    I don't think it will throw you at all and I really don't think it will hurt too many people who are just getting started. The learning curve is not steep and there are many examples - it's very much like starting with a BASIC Stamp - although I think the Parallax documentation and other materials are better.

    If you're going to be at UPENE, I'll bring you a bare Diavolino board (the link above). Let me know.
  • Andrey DemenevAndrey Demenev Posts: 377
    edited 2010-08-13 07:37
    Kevin Wood wrote: »
    The Propeller is not true open source. It's not even false open source. It's a closed source, proprietary product owned, controlled, and produced by Parallax. And if Parallax wants to produce their own Arduino clone, they're free to do so, and all of that they need to do so is on the web. But if somebody wants to produce their own Propeller, well, somebody post the links...

    Hmmm, looks like you are either blown away by this arduino marketing hype, or you are the one of those who create this hype :D How do you compare arduino board and software (mostly software) to propeller chip ? Compare propeller to AVR - that will be fair. I want to make AVRs - can I ? Same for propeller.
  • LeonLeon Posts: 7,620
    edited 2010-08-13 07:55
    Why don't you download the data sheets and compare them for yourself?

    A copy of the AVR is available for implementation in an FPGA, if you want to "make your own AVR".
  • GranzGranz Posts: 179
    edited 2010-08-13 08:03
    schill wrote: »
    I don't really see how something like this

    http://www.evilmadscientist.com/article.php/diavolino

    or many other variations of Arduino hardware are not standard microcontrollers (I purposely chose one that looked "evil" for effect). There are no limits on how pins can be used. The only hardware connected to any pins are the ftdi chip (not on the board linked above) and an LED on (Arduino digital) pin 13. You can program it with any language that works with the AVR and use bootloaders or an ISP.

    For quick and dirty stuff, I don't have any problems with the Arduino IDE and language. Some of the functions aren't very efficient (digital I/O) but you can access lower level stuff if you want to.

    I don't think it will throw you at all and I really don't think it will hurt too many people who are just getting started. The learning curve is not steep and there are many examples - it's very much like starting with a BASIC Stamp - although I think the Parallax documentation and other materials are better.

    If you're going to be at UPENE, I'll bring you a bare Diavolino board (the link above). Let me know.

    Schill,

    I think that you and Kevin got the wrong idea about what I think about the Arduino. I said that my biggest problem with the Arduino is...; NOT that this is a BIG problem. In fact, in my final paragraph, I said that I will probably get one soon to play with. I apparently came across too strong on my dislike for the things. (For someone who "hates" the things, I have spent a lot of my precious time checking them out :D - In fact, just last night I was looking at another one, and this morning I checked out the Diavolino - Are you Evil Mad Scientist, Schill?)

    My memory is not what it used to be, but I thought that the Arduino had certain pins set aside for A/D input (I understand that all pins can be used for digital, but the docs only mention them as A/D) and (IIRC) not all pins were brought out to the I/O headers. Also, the sketches are not standard C - there is no Main(); to a sketch, and I seem to remember that there are a few other small differences. I'm not an expert in C, but it seems that a program without a Main(); will not compile correctly - I could be wrong about this though.

    Yes, the Arduino controller can be programmed in any language, but the bootloader is really the only thing that makes an Arduino an "Arduino." If you ignore, bypass or change that, then the entire system really just becomes another AVR controller. The bootloader is set up to specifically utilize the Arduino variation of C. I do have a bunch of different AVR ISP (and even a couple of out-of-system-) programmers, and most of my AVR products have an ISP port built-in, but the Arduino (IIRC) does not, just the serial port used to download the sketches. Yes you can pull the uC and program it in a programmer, but then again, it is not really an Arduino that way. I really do like the AVR family and that is why I am interested in playing with those Arduinos, just that keeping it to TRUE original Arduino specs limits it a bit (only a bit, mind you.)

    All in all, I really do want to play with the things, just that I like the more "basic" AVRs better (at this time - with no real hands-on experience with Arduino and tons of hands-on with AVR). I appreciate your offer of one of your Diavolinos, and look forward to playing with it when I get home (how much is it for the kit of parts? - although, I have a lot of AVR chips, I don't have any 328s). Maybe I will find that my "problems" with the Arduino are even less than I thought - though I didn't think that they are big to begin with...

    Thanks again, and I'll see you at UPENE.

    Art
Sign In or Register to comment.