Newbie & cogs
Travis M. Best
Posts: 9
I am a very very green propeller user I've decided to use the propeller chip in a project and have found it not as easy as I first thought and am looking for some advice. I have two separate programs I would like to run at the same time and I believe this can be done with COGS if so can some one show me a quick example of running two programs
Thanks
Travis Best
Thanks
Travis Best
Comments
See Example 03.
Leon
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Amateur radio callsign: G1HSM
Look at the FullDuplexSerial code in the OBEX. That is actually using 2 programs. One is the driver in pasm for the serial port. The VGA driver uses multiple cogs, but is more complex.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
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)
· Search the Propeller forums·(uses advanced Google search)
My cruising website is: ·www.bluemagic.biz·· MultiBladeProp is: www.bluemagic.biz/cluso.htm
this is indeed one of the hurdles to overcome in learning the Prop - but it's not too difficult... Leon and Cluso have lead you in the right direction... I cut my teeth on this problem using the very same files Cluso indicates.
Plus, you will always get great assistance from the forum members!
cheers
-Howard
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
You can also take a look at this, especially the sections talking about Methods and Cogs....
www.parallax.com/Portals/0/Downloads/docs/prod/prop/PELabsFunBook-v1.1.pdf
I hope that helps,
Mark
Post Edited (ElectricAye) : 10/27/2009 6:46:53 PM GMT
Do you have experience with other microcontrollers? In fact it is much easier to write programs for the propeller compared to other controllers when you wanna do some different things at the same time. Because other microcontrollers use interrupts for that and you have to take care that interrupt routines don't eat up to much time. Finding bugs in that kind of programs can be a real pain.
Prop programming is so easy, if you get aware of the differences to single core microcontrollers. And that's the first task in learning how to program the prop. Get familiar with it and it's concepts. Start with SPIN only, using all the objects you are interested in. FullDuplexSerial , TV , PWM , Servo driver ....
In a usual microcontroller you have a good chance that the code snippets you find has to be adopted to fit into your project ... because you already use the same interrupt for something else ....
Prop ... no problem ... just start the code in a different COG.
Is only starts to get complex when you need more RAM or you'd need more COGs.