Unique Propeller Functional Abilities?
jazzed
Posts: 11,803
The question comes up sometimes about what unique things the Propeller is capable of doing.
It seems to be in the best interest of Propeller to identify unique abilities.
I hope that Prop People can come up with some interesting things in responses to this thread.
1) There is always the deterministic timing feature of multiple threads of execution which can enable very interesting things like precise 10ns resolution samples on many pins. A single core MCU running fast enough could do that, but may not have enough bandwidth left for anything else.
2) It occurs to me that it may be possible to detect which fast serial protocol may be attempted on a given pin (or set of pins for synchronous communications). Is this a function that can be done with other chips?
3) Phil points out that the per COG counters are a powerful asset. This is very true, and they enable things like synchronous background clocking for data transfers, easy PWM abilities, etc.... Input modes of the counters allow clock tricks for updating accumulator registers, fast ADCs, etc....
4) Ariba points out these features: A PLL per counter which allows to generate frequencies up to 160 MHz on a pin (with 80MHz system clock). Composite video with color modulator; other Micros can do VGA or B/W-video, but colors on composite is unique. A 32 bit processor in DIP package. (The only other I know is the 68000 in DIP64)
5) Prof_braino expands on counter PWM capabilities: Counters run independently of code, allowing precision control of I/O pins without impact due to code execution; IE one counter can control 8 servos as easily as controlling a single servo; one cog, having two counters, can control 16 servos. The code executing on this cog is not impacted by the counters, so the servo control is still deterministic.
6) David Hein: For me, the biggest strength of the Prop is the ability to easily implement drivers and co-processors in software in independent cogs.
7) Ale expands on the DIP package factor: The most unique feature I find is the DIP40 package. So much power in an easy-to-use package. Just one power supply, a crystal and a PC... nothing fancy. My additions: EEPROM is requried for standalone operation. Even the closest competitor does not offer 8 fully independent cores in a DIP40 package.
8) Leon describes a nice example: We were using it for a complex data logger application for refrigerated containers, for which it was an ideal platform and enabled us to offer a one-chip solution at a price that couldn't be achieved with any other solution. The on-chip VGA was especially useful, as we could provide a display in the vehicle cab. We were using most of the cogs, and had a very neat, small, PCB design.
9) Leon mentions: Video capable hardware on each cog. The hardware can also be used as a serializer for other purposes.
10) ... hopefully more useful examples may come up
Final thoughts:
It is very difficult to steer a thread like this to focus on functional abilities which provide market differentiators. The example cases provide powerful demonstrations of functional abilities without getting into mammoth detail - the examples truly focus on functional abilities.
People get caught up in implementation details too much rather than the functions that are enabled by the architecture. Still, the architecture itself is unique relative to other MCUs and some might say it's eccentric, but it is very simple and makes the chip easy to use.
The architecture does enable multi-tasking without any form context switching (required for single-core multitasking), will not freeze because of complex arbitration, and the assembly language is truly elegant once you adjust to a few strange little things.
davidsaunders offers a nice summary (edited here for focus):
1) A multi-core highly deterministic architecture without interrupts.
2) An instruction set that is very well thought and designed.
3) Versatile counters, and separate counters per COG.
4) The ability to easily access any pins from any COG at any time in a very simple manner.
5) Relatively low cost. Both the Prop, and the application of peripherals are relatively inexpensive, especially as you can implement a huge number of peripherals in software with a minimum of passive components.
I think it's great that davidsaunders "gets it" having only used Propeller for a short time.
Of course anything new has a learning curve and different people have different curves.
The message is: Propeller is different but has marketable differences, and it is easy to learn and use.
It seems to be in the best interest of Propeller to identify unique abilities.
I hope that Prop People can come up with some interesting things in responses to this thread.
1) There is always the deterministic timing feature of multiple threads of execution which can enable very interesting things like precise 10ns resolution samples on many pins. A single core MCU running fast enough could do that, but may not have enough bandwidth left for anything else.
2) It occurs to me that it may be possible to detect which fast serial protocol may be attempted on a given pin (or set of pins for synchronous communications). Is this a function that can be done with other chips?
3) Phil points out that the per COG counters are a powerful asset. This is very true, and they enable things like synchronous background clocking for data transfers, easy PWM abilities, etc.... Input modes of the counters allow clock tricks for updating accumulator registers, fast ADCs, etc....
4) Ariba points out these features: A PLL per counter which allows to generate frequencies up to 160 MHz on a pin (with 80MHz system clock). Composite video with color modulator; other Micros can do VGA or B/W-video, but colors on composite is unique. A 32 bit processor in DIP package. (The only other I know is the 68000 in DIP64)
5) Prof_braino expands on counter PWM capabilities: Counters run independently of code, allowing precision control of I/O pins without impact due to code execution; IE one counter can control 8 servos as easily as controlling a single servo; one cog, having two counters, can control 16 servos. The code executing on this cog is not impacted by the counters, so the servo control is still deterministic.
6) David Hein: For me, the biggest strength of the Prop is the ability to easily implement drivers and co-processors in software in independent cogs.
7) Ale expands on the DIP package factor: The most unique feature I find is the DIP40 package. So much power in an easy-to-use package. Just one power supply, a crystal and a PC... nothing fancy. My additions: EEPROM is requried for standalone operation. Even the closest competitor does not offer 8 fully independent cores in a DIP40 package.
8) Leon describes a nice example: We were using it for a complex data logger application for refrigerated containers, for which it was an ideal platform and enabled us to offer a one-chip solution at a price that couldn't be achieved with any other solution. The on-chip VGA was especially useful, as we could provide a display in the vehicle cab. We were using most of the cogs, and had a very neat, small, PCB design.
9) Leon mentions: Video capable hardware on each cog. The hardware can also be used as a serializer for other purposes.
10) ... hopefully more useful examples may come up
Final thoughts:
It is very difficult to steer a thread like this to focus on functional abilities which provide market differentiators. The example cases provide powerful demonstrations of functional abilities without getting into mammoth detail - the examples truly focus on functional abilities.
People get caught up in implementation details too much rather than the functions that are enabled by the architecture. Still, the architecture itself is unique relative to other MCUs and some might say it's eccentric, but it is very simple and makes the chip easy to use.
The architecture does enable multi-tasking without any form context switching (required for single-core multitasking), will not freeze because of complex arbitration, and the assembly language is truly elegant once you adjust to a few strange little things.
davidsaunders offers a nice summary (edited here for focus):
1) A multi-core highly deterministic architecture without interrupts.
2) An instruction set that is very well thought and designed.
3) Versatile counters, and separate counters per COG.
4) The ability to easily access any pins from any COG at any time in a very simple manner.
5) Relatively low cost. Both the Prop, and the application of peripherals are relatively inexpensive, especially as you can implement a huge number of peripherals in software with a minimum of passive components.
I think it's great that davidsaunders "gets it" having only used Propeller for a short time.
Of course anything new has a learning curve and different people have different curves.
The message is: Propeller is different but has marketable differences, and it is easy to learn and use.
Comments
Instructions to explicitly self modify code, by only fields of the opcode (MOVD/MOVI/MOVS)
Jazzed:
Thank you for this thread.
1,$s/want/need/g
* Easy and quick to program and get working compared to other micros - mainly because of no interrupts and multi-cores
* Being able to program in assembler for fast code execution
* Being able to program in spin when speed is not required (usually the main program)
* Now having Basic and C.
* Flexible I/O so that 1 chip can do lots of functions (no need to have a lot of various families of chips)
e.g. add UARTs, TV, Video, Stereo, microSD, Keyboard, Mouse, LCD, GPS, I2C sensors, etc etc
* Being able to add 1pin TV debugging using 1 cog
I often like to display results on screens for debugging purposes and this makes it simple/effective.
I now have a nice small 4.3" LCD that gives 80x25 text for this (and CPM)
* Able to emulate other older processors (I want to emulate a mini I worked on 1974-1999)
Because the Prop is so powerful, I would have liked more hub ram, more cogs, more pins and ADC (I haven't played with ADC sigma-delta yet). I believe the problem I/we are finding is because we love programming the prop so much, we want it to do things that it was never conceived to do. I suspect we have the same ambitions for the prop II.
In fact, all the initial projects I had in mind for the Prop have never been realised. This is because I found it could do so much more, so easily, that my new projects were even more fun, and more powerful, than those I had originally intended to do.
Forthed.
I really like the Propellers assembly language and instruction set, I would almost say it is as easy as that of the 680x0 series , though I can not, for Prop assembly is quite a bit easier than 680x0 assembly.
Sure Propeller is unique internally, but that just means it's different and it raises eyebrows.
I see no specific unique functional abilities coming from the architecture itself except for multi-tasking without context switching. Running self-modifying code is just a part of the design. I like PASM too, but it's just another assembly language however neat it is.
I guess being able to run multiple serial ports or drive multiple TV displays are "unique functional abilities."
Are there other "unique functions" that Propeller enables which are impossible with other MCUs?
-Phil
That's a pretty major unique ability.
For example writing a high speed DDS loop on a single core chip results in not being able to change it's frequency without pausing it briefly with an interrupt and causing a glitch.
Perhaps not unique now a days as more multicore chips are turning up but the Prop had a good head start as is still the simplest multi-core to use.
Well, I don't, and the Prop is a great thing in that respect, because I've been able to do lots of interesting stuff that would have been way more work on other devices, and I have a good time doing it too. Maybe that's not a "pro" unique feature, but it is a unique feature.
And again, the virtual machine capability (LMM) is unique in that one can consider the cog as micro-code, where a specialized CPU can be built to accomplish something. On Prop I, it's a discovery and less than optimal, but on Prop II, we are going to see that well exploited, because it's known now and that will impact that design. The things we can do now, and will be able to do with LMM are pretty darn unique, in that the hardware has a distinct separation here with COG addressing and HUB addressing the way it is. How many other devices can fire off one CPU to observe another, and do so with the very basics needed on a Propeller? Again, highly differentiated, IMHO.
Another one is clocking down to DC. I know other devices can do that, but the Prop has software control of the clock, and wait / sleep states for a very wide range of acceptable operation. Maybe not unique, but highly differentiated, IMHO.
@Phil, I need to use the counters more. You sure are stoked on them, LOL!!
Yes, they are great. The only thing I am missing is auto-reload
- A PLL per counter which allows to generate frequencies up to 160 MHz on a pin
- Composite video with color modulator. Other Micros can do VGA or B/W-video, but colors on composite is unique.
- A 32 bit processor in DIP package. (The only other I know is the 68000 in DIP64)
Andy
And soft cores in FPGAs?
'X' does not do this in a direct way, to be able to use any IO for any purpose on 'X' you have to use soft links.
As to soft cores, being able to configure them at implementation time is not the same as being able to directly use at run time.
XMOS cores can use pins for input and outut directly, at 100 MHz. This is what the code looks like:
I/O on other cores and chips can use very fast comms channels, of course. Everything is deterministic.
With FPGA configuration times being a few ms, it's irrelevant when I/Os are assigned.
Leon: I didn't mean to imply you were hijacking the thread or anything. And, I understand wanting to clarify things. My only concern is that this is how these threads always seem to get started. It doesn't take long for it to get out of hand.
I think a better thread is probably "What makes a Propeller easy to use?" rather than "What makes it unique?" At least that way we shouldn't get into as many "This processor does that too or does that better" discussions.
Dev1: 'Lets stop our program for a couple of ms to reassign Pin defs, and crash the system'.
Dev2: 'Sounds like a great idea'.
Can you really see this as reasonable, Leon?
And I will not respond to the other (we do not need another thread on that).
Maybe this is true. However, my primary intent for this thread was to help find marketable differentiators of the propeller.
I've really only seen a few relevant responses so far and will update the top thread to include them later.
Perhaps a use-case example (probably not clearly, its too early):
Counters run independently of code, allowing precision control of I/O pins without impact due to code execution; IE one counter can control 8 servos as easily as controlling a single servo;
one cog, having two counters, can control 16 servos. The code executing on this cog is not impacted by the counters, so the servo control is still deterministic.
Two cogs can control 32 servos, but since this consumes all 32 I/O pins, one can refactor, and divide the application between two props, 16 servos on each,
with plenty of I/O pins for input and cogs for processing and handing inter-chip control. A cog and two (or one) I/O pins can be used as a clock speed link to another prop (or other micro). So one can have a single unit of N-props to increase the cogs and I/O pins to the needed capacity.
The servo control and the interprop communication applications do not interfere with each others deterministic execution. There are still plenty of resources for other interfaces.
That was naughty:)