Shop OBEX P1 Docs P2 Docs Learn Events
Enhancing the Propeller with a Co-processor — Parallax Forums

Enhancing the Propeller with a Co-processor

Peter JakackiPeter Jakacki Posts: 10,193
edited 2010-02-22 20:34 in Propeller 1
How many of us are guilty of pushing the Propeller boundaries??? Sometimes to surpass our expectations, but other times to find we have hit the proverbial brick wall or we simply fall off the edge by losing our focus.

We have to admit to ourselves that despite how brilliant and how much fun the Propeller is that there are things best left to other more boring but better suited devices. The Propeller is after all a microcontroller, perhaps the most amazing microcontroller of all microcontroller history, but a microcontroller nonetheless (there I managed to emphasize microcontroller 4 times not including this 5th instance).

At various times I have teamed up the Propeller with peripheral controllers for I/O expansion and analog capabilities etc where the Propeller is clearly the controller and at other times with ARM processors where I have left enough flexibility in the design for either to control or co-operate. A little while back I looked at using some cheap and powerful 8-bit HCS08 chips for peripheral work as well though I haven't done anything with them.

Last night however I updated my already overloaded cranium with the latest 32-bit line-up from NXP as they have been expanding their ARM Cortex range. My eyes popped when I checked the price of the basic 8K/8K 50MHz version on Mouser, even in Oz$ it is only $1.31 in 100 quantities ($1.76 one off), and only slightly more for 32K Flash versions. What am I doing even thinking about 8-bit'rs? I pay more for my basic PIC16F690, and it's a lot more basic and slower than the ARM. The LPC111x also has 1% 12MHz RC oscillator and operation down to 1.8V as well as 5V tolerant I/O all of which are requirements in many designs.

Then there was the LPC1343 with built in USB MSC and HID capabilities! Ok, these weren't under $2, but around $5, which is what I pay just for an FT232R anyway. Packaging includes PLCC44 as well.

Since I have both low-level (peripheral) and also high-level (fast application) requirements for another processor I intend to concentrate on just one processor other than the Propeller, which is of course my favorite. So, if a new design needs more I/O, or ADC, or USB, or needs to run C or Forth (easily) then I would opt to design in these lower end ARM CPUs for the reasons outlined previously and also so I only have to concern myself with one other architecture so as not to lose my design focus. A free development environment exists based on the Eclipse IDE.

If any of you guys are thinking "I'm only ever going to use the Propeller, no other processor" then think of this as any other support chip (USB/ADC/I/O) but cheaper and smarter.

So, what do you think?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
*Peter*
«1

Comments

  • Bill HenningBill Henning Posts: 6,445
    edited 2010-02-11 00:34
    Well, I did pick up some LPC_Expresso kits and LPC111x chips... but for now my Propeller designs will stay through hole.

    I got them to check them out, and also to experiment with surface mounting at a lower cost (of error).

    The biggest reason I have not used ARM/ATMEL/PIC etc copro's is the incredible simplicity of Spin/PASM, and all the wonderful objects in Obex.

    (full disclosure: My lab has tons of Atmel, Microchip, ST, NXP etc microcontrollers, programming tools, dev boards etc - I just happen to have been spending 99% of my time on the Prop)
    Peter Jakacki said...
    How many of us are guilty of pushing the Propeller boundaries??? Sometimes to surpass our expectations, but other times to find we have hit the proverbial brick wall or we simply fall off the edge by losing our focus.

    We have to admit to ourselves that despite how brilliant and how much fun the Propeller is that there are things best left to other more boring but better suited devices. The Propeller is after all a microcontroller, perhaps the most amazing microcontroller of all microcontroller history, but a microcontroller nonetheless (there I managed to emphasize microcontroller 4 times not including this 5th instance).

    At various times I have teamed up the Propeller with peripheral controllers for I/O expansion and analog capabilities etc where the Propeller is clearly the controller and at other times with ARM processors where I have left enough flexibility in the design for either to control or co-operate. A little while back I looked at using some cheap and powerful 8-bit HCS08 chips for peripheral work as well though I haven't done anything with them.

    Last night however I updated my already overloaded cranium with the latest 32-bit line-up from NXP as they have been expanding their ARM Cortex range. My eyes popped when I checked the price of the basic 8K/8K 50MHz version on Mouser, even in Oz$ it is only $1.31 in 100 quantities ($1.76 one off), and only slightly more for 32K Flash versions. What am I doing even thinking about 8-bit'rs? I pay more for my basic PIC16F690, and it's a lot more basic and slower than the ARM. The LPC111x also has 1% 12MHz RC oscillator and operation down to 1.8V as well as 5V tolerant I/O all of which are requirements in many designs.

    Then there was the LPC1343 with built in USB MSC and HID capabilities! Ok, these weren't under $2, but around $5, which is what I pay just for an FT232R anyway. Packaging includes PLCC44 as well.

    Since I have both low-level (peripheral) and also high-level (fast application) requirements for another processor I intend to concentrate on just one processor other than the Propeller, which is of course my favorite. So, if a new design needs more I/O, or ADC, or USB, or needs to run C or Forth (easily) then I would opt to design in these lower end ARM CPUs for the reasons outlined previously and also so I only have to concern myself with one other architecture so as not to lose my design focus. A free development environment exists based on the Eclipse IDE.

    If any of you guys are thinking "I'm only ever going to use the Propeller, no other processor" then think of this as any other support chip (USB/ADC/I/O) but cheaper and smarter.

    So, what do you think?
    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.mikronauts.com E-mail: mikronauts _at_ gmail _dot_ com 5.0" VGA LCD in stock!
    Morpheus dual Prop SBC w/ 512KB kit $119.95, Mem+2MB memory/IO kit $89.95, both kits $189.95 SerPlug $9.95
    Propteus and Proteus for Propeller prototyping 6.250MHz custom Crystals run Propellers at 100MHz
    Las - Large model assembler Largos - upcoming nano operating system
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 00:41
    Well, I agree about the simplicity and wonderfulness of the objects but this is not about replacing things the Propeller can do well, it's about doing things the Propeller can't or doesn't do very well. There aren't many systems that don't use some other chips as well no matter how good the Prop is. We tend to be automatically defensive about the Prop, but it doesn't and can't do everything. We might think we're perfect yet we have our wives to complement us (and also remind us we are not perfect).

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • blittledblittled Posts: 681
    edited 2010-02-11 01:07
    I have a Chameleon - PIC which opens a lot of possibilities with interfacing of a pic and a Propeller. In fact I have Rayman's PSM, a m100 keypad, Parallax's thumb Joystick, EZ Bluetooth, and a MCP23S17 I/O expander connected to it. Now I just have to build the drivers [noparse]:)[/noparse].

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Will work for Propeller parts!

    Post Edited (blittled) : 2/11/2010 1:21:08 AM GMT
  • Dr_AculaDr_Acula Posts: 5,484
    edited 2010-02-11 01:25
    Re "I have a Chameleon - PIC which opens a lot of possibilities with interfacing of a pic and a Propeller."

    By a strange coincidence I just got an email a few hours ago from someone in New Zealand asking for info about the Chameleon (he is going to write a review on it and is a non propeller user). So I've just been checking this board out. I found it here www.parallax.com/tabid/252/Default.aspx (along with all our other favourite boards).

    So it appears to be a hybrid of a propeller and AVR PIC. I'd like to know more about that, especially software applications.

    As for ARM chips - I need to check those out too.

    Sorry, I've probably added more questions to this discussion than answers!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.smarthome.viviti.com/propeller
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 01:36
    Drac! it's because I am avoiding PICs/AVRs/HC08s and other very limited 8/16-bit architectures that I have brought up for discussion the cheap 32-bit ARM chips both as low-end and high-end complementary processors.

    Don't mention that P word again nono.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • Dr_AculaDr_Acula Posts: 5,484
    edited 2010-02-11 01:39
    Ok, no more mention of the P word [noparse][[/noparse]Chuckle]

    Re ARM, do you have a link to the chip? And what about software? I guess software is the key. The prop obex now seems to have a huge library of code blocks that plug together like Lego.

    Lunchtime soon - then I can do some proper research.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.smarthome.viviti.com/propeller
  • Mike HuseltonMike Huselton Posts: 746
    edited 2010-02-11 01:41
    For over a year, I have been adding SPI & I2C interfacing to ARM and Propeller chips. Great combination on cost and performance terms. I have had only success with this scheme. The other interfaces/chip combo's are a waste of time in both ease of implementation and money.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    JMH
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 01:51
    Some links to these ARM chips:

    The low-end cheap cheap ARM <$2
    LPC111x datasheet ics.nxp.com/products/lpc1000/datasheet/lpc1111.lpc1112.lpc1113.lpc1114.pdf
    ics.nxp.com/lpcxpresso/~LPC1114/#LPC1114

    Low-end ARM with built-in USB drivers. ~$5
    ics.nxp.com/lpcxpresso/~LPC1343/#LPC1343

    Low-end ARM with USB/CAN/Ethernet ~$11
    ics.nxp.com/lpcxpresso/~LPC1769/#LPC1769

    There are a lot of tools available but the one that comes with the LPCXpresso evaluation is
    lpcxpresso.code-red-tech.com/LPCXpresso/

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • wjsteelewjsteele Posts: 697
    edited 2010-02-11 02:01
    I stick with the prop because of two words... EIGHT CORES! smile.gif

    Bill
  • Luis DigitalLuis Digital Posts: 371
    edited 2010-02-11 02:13
    Hello Peter,

    Very interesting price and features in the data sheet.

    Are these chips just as easy to program, as an AVR (ISP)?
    Parallel port without using microcontroller.

    Thank you.
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 02:19
    wjsteele said...
    I stick with the prop because of two words... EIGHT CORES! smile.gif

    Bill

    Again, it is being emphasized heavily. This is NOT A REPLACEMENT for the Propeller, it is a versatile Co-Processor. Somebody shoot me if I even think of giving up the Propeller! I have done many many Prop designs and there is a real need for this enhancement unless you are simply playing with Props or have a design that is handled adequately by the Prop itself.

    Each Prop core still only has 512 longs of memory and only runs at 20Mhz which I used to think was fast years ago. Hub memory is limited and slow. Non-standard external memory hogs scarce pins, and requires extra hardware. I not trying to be negative, just stating obvious facts.

    Many commercial designs I do need a large and fast program space or special I/O. Why kludge and bog down an efficient 8-core microcontroller when a $2 chip will blitz this part of it?. Only those who are totally obsessed with a "pure" Propeller design will refuse to look elsewhere. Of course I am not talking about ones who are pushing the edge and exploring what can be done purely with the Prop, or simply having fun. But commercial designs have to work, not next year, preferably yesterday. It's not just a matter of academic pride or ability or loyalty to any processor (The Prop certainly does beget a strong loyalty though).

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 02:24
    Luis Digital said...
    Hello Peter,

    Very interesting price and features in the data sheet.

    Are these chips just as easy to program, as an AVR (ISP)?
    Parallel port without using microcontroller.

    Thank you.

    They claim that with these new Cortex M0/3 cores that there is no need to program in assembler, even for the interrupt handlers etc. If you can program in C then yes, it is just as easy to program. The chips include a UART style ISP and also JTAG and 2-wire serial debug as well as direct USB (no chips) on the LPC1343. I have always loaded these in the past via a serial port directly, much like the Propeller. I hope you didn't mean "parallel port" as in LPT1 as that is rather incompatible with modern O/S plus you won't find them on most laptops anyway.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • Luis DigitalLuis Digital Posts: 371
    edited 2010-02-11 02:32
    In-System Programming: In-System programming (ISP) is programming or
    reprogramming the on-chip flash memory, using the boot loader software and UART
    serial port. This can be done when the part resides in the end-user board.


    Datasheet Pag. 219

    Super!

    NXP has compilers, and loaders for free? Linux?

    Excuse me for asking so many questions, but it's really interesting.
  • Luis DigitalLuis Digital Posts: 371
    edited 2010-02-11 02:37
    wjsteele said...
    I stick with the prop because of two words... EIGHT CORES! smile.gif

    Bill

    Yes, but these ARMs could serve to special cases such as an LCD controller. Is Rayman reading here? smile.gif
  • ImageCraftImageCraft Posts: 348
    edited 2010-02-11 02:37
    You can get gcc for "free." We already have a low cost ARM compiler, and will definitely move to the Cortex market later this year. It's a Tsunami.

    // richard
  • Luis DigitalLuis Digital Posts: 371
    edited 2010-02-11 02:41
    ImageCraft said...
    You can get gcc for "free." We already have a low cost ARM compiler, and will definitely move to the Cortex market later this year. It's a Tsunami.

    // richard

    Yes, I was forgetting, gcc is like God is everywhere. smile.gif
  • BTXBTX Posts: 674
    edited 2010-02-11 03:14
    Hi Peter.
    So sorry if I don't understand well your point...but.
    Why not to think in a CPLD, to be the perfect partner for a propeller ??

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Regards.

    Alberto.
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 03:34
    CPLDs are still logic gates, reconfigurable yes, but not as flexible as a processor. There are certain well defined designs where a CPLD or FPGA will do the job well but getting one that has any real degree of flexibility means lots of gates and $ plus they can be a real pain to "program". The LPC1 series have lots of advantages for under $2. Even for the unique serial numbers that are embedded in each device it would be worth it. The device can even emulate a EEPROM and so replace the Propeller's EEPROM as well as even the need for a crystal plus with it's CRP can add that security element that is missing. It can't replace the unique capabilities of a Propeller, but it can enhance it.

    A CPLD will never do this.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • TubularTubular Posts: 4,717
    edited 2010-02-11 03:52
    Peter,

    I think you're spot-on. There is definite a need for a flexible co-pro for the prop. We have PIC/AVR chameleons but they're not powerful enough to really take the Prop where it needs to go (too much overlap in functionality, for what benefit exactly?).

    I've been looking closely at the 'mBed' based on the LPC1768. LPC1766/68 is a ~$6-7 device which is only a few$ more than the MCP3208 ADC I use. But it offers 12bit ADC, USB OTG, Ethernet, RTC, unique ID, heaps of IO, and as you point out no need for an additional crystal. The mBed (NXP OM11043) is just a convenient way to get started for $51, in DIP40 40 pin 0.9" spacing format. Farnell have them here for $75. Programming software for PC/MAC/Linux is onboard (I guess a benefit of having 512kb Flash!)

    Your original approach outlined for the Freescale co-pros is the way to go, so we can have standard LPC176x objects in the Obex which soft program the LPC to fulfil basic functions without users needing to get to grips with the Nxp IDE at all.

    Post Edited (Tubular) : 2/11/2010 11:57:52 PM GMT
    610 x 383 - 213K
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-02-11 04:34
    Peter,

    You make an intriguing case, but which is the tail and which is the dog? Is the ARM a coprocessor for the Prop, or is the Prop a high-speed peripheral controller for the ARM? Or does it matter? And how do you see this figuring into the various networking projects that are afoot, if at all?

    -Phil
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 04:36
    Yes, as a smart peripheral chip we could supply the binary object code just as if it were an external "cog". So the obex would include a binary file that the Prop would load into the Xcog. Larger binary files could be loaded directly into the Xcog. This is not much different from having to have a specialized external chip (ADC/IO etc) and driver for it. I have made a determination to place one of the LPC111x chips on every board I do in place of a PIC or ADC/IO etc.

    The 1768 is a larger more complex beast but it does have ethernet and the other features you mentioned. Obviously, it's a bit more than a peripheral chip and quite possibly the Prop would be treated as a smart peripheral then. I'm keeping my focus on the LPC1 series acting as co-pros or external cogs

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 04:42
    Phil Pilgrim (PhiPi) said...
    Peter,

    You make an intriguing case, but which is the tail and which is the dog? Is the ARM a coprocessor for the Prop, or is the Prop a high-speed peripheral controller for the ARM? Or does it matter? And how do you see this figuring into the various networking projects that are afoot, if at all?

    -Phil

    Phil, I like to keep it flexible but prefer to center the application around the Prop. Also see my previous post. I think you meant to say arm and cog rather than tail and dog lol.gif

    As for networking I think this is the only sensible way to go as no matter what kind of ethernet chip we hang off the Prop it is going to eat resources and still be crippled. The LPC1768 costs around the same price as a dumb ethernet chip, of course we still the PHY but TCP/IP stacks are available for this chip and it certainly has plenty of grunt and memory for the task at hand. This way the Prop does what it does best as it is probably the most flexible chip I have ever worked with.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • LeonLeon Posts: 7,620
    edited 2010-02-11 05:15
    That was something I did years ago, when the LPC2106 first came out. This is the correct link (Yahoo discontinued Geocities):

    webspace.webring.com/people/jl/leon_heller/lpc2104.html

    My LPC2000 Yahoo group is very popular (over 8,500 members):

    tech.groups.yahoo.com/group/lpc2000/

    NXP has sent me one of their LPC1768 Cortex-M3 kits. I should get it in a couple of days.

    I use the excellent Rowley Crossworks tools for ARM development:

    www.rowley.co.uk

    with their new CrosConnect Pro JTAG.

    There is also an XMOS co-processor, of course. Much more performance than any ARM system, easily extended with more chips, and oodles of I/O.

    Leon

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Amateur radio callsign: G1HSM

    Post Edited (Leon) : 2/11/2010 5:22:33 AM GMT
  • Cluso99Cluso99 Posts: 18,069
    edited 2010-02-11 06:27
    Nice concept Peter. The LPC1343 may be better than a FT232RL for marginally more cost, but then you have to program it. At least you have other sections to use.
    The LPC1769 is much better, but at a price ~$11, for USB host, device & OTG, plus ethernet.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Links to other interesting threads:

    · Home of the MultiBladeProps: TriBlade,·RamBlade,·SixBlade, website
    · Single Board Computer:·3 Propeller ICs·and a·TriBladeProp board (ZiCog Z80 Emulator)
    · Prop Tools under Development or Completed (Index)
    · Emulators: CPUs Z80 etc; Micros Altair etc;· Terminals·VT100 etc; (Index) ZiCog (Z80) , MoCog (6809)·
    · Prop OS: SphinxOS·, PropDos , PropCmd··· Search the Propeller forums·(uses advanced Google search)
    My cruising website is: ·www.bluemagic.biz·· MultiBlade Props: www.cluso.bluemagic.biz
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-02-11 07:32

    And don't forget my foray into ARM back in 05/06
    www.jandspromotions.com/philips2005/Winners/AR1784.htm

    I am still producing these boards using LPC2148s for some custom dataloggers at least.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • heaterheater Posts: 3,370
    edited 2010-02-11 07:38
    I dream of this:

    A small board with some kind of ARM on it. Some megabytes of FLASH, some megabytes of RAM, video, ethernet, USB host, USB device. SD card. It runs Linux. It runs the ARM port of BST when it comes. It runs whatever large scale "normal" code I need. Supporting it is one ore more Propellers providing lots of funky real-time and I/O possibilities.

    The whole thing is half Euro card sized with USB, Ether, etc connectors on one end and a mega pin back plane connector on the other end.

    Bingo, a general purpose board for all kinds of networked embedded control applications. Containing it's own Propeller development system.

    Just now it looks like settling for a Beagle Board or Friendly Arm and having the Props on a board with a matching form factor.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    For me, the past is not over yet.
  • AleAle Posts: 2,363
    edited 2010-02-11 08:01
    Hei Alberto, have you seen my latest Propeller board (FPGA+Propeller) ? here : http://forums.parallax.com/showthread.php?p=877975


    A dsPIC32 with a MIPS core is something I'd like to explore... I love MIPS (pun intended!).

    Leon: From a co-processor stand point it may make sense... but I'd just use a XMOS without a propeller... it is cheaper.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Visit some of my articles at Propeller Wiki:
    MATH on the propeller propeller.wikispaces.com/MATH
    pPropQL: propeller.wikispaces.com/pPropQL
    pPropQL020: propeller.wikispaces.com/pPropQL020
    OMU for the pPropQL/020 propeller.wikispaces.com/OMU
    pPropellerSim - A propeller simulator for ASM development sourceforge.net/projects/ppropellersim
  • LeonLeon Posts: 7,620
    edited 2010-02-11 10:43
    Yes, the PIC32 is better than the ARM in some ways - faster multiply and divide, amongst other things, and a nicer architecture. I've got a few chips lying around somewhere.

    The new Energy Micro Cortex-M3 chips are nice:

    www.energymicro.com/

    They are very cheap.

    Leon

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Amateur radio callsign: G1HSM

    Post Edited (Leon) : 2/11/2010 10:53:27 AM GMT
Sign In or Register to comment.