Propeller C launching cogs for the c beginners.
pilot0315
Posts: 910
This is a c program to blink seperate pins as well as send on/off data and display it on the debug screen. It displays which cogs are launched then the status of each cog.
There are two ways to launch a cog in Prop C. I only found one to work.
There are two ways to launch a cog in Prop C. I only found one to work.
Comments
You are using the same stack for both, you need separate stack othwise they will conflict with each other. Your code is actually running because the functions are not using the stack but as soon as you use a local variable you'll have problems.
The cog variables are defined as int * (pointers) while cogstart returns an int. You need to define them as int then the assignment is correct.
Other than that, I don't see any obvious error, I'm using cogstart in my programs much like you do and I don't have problems.
What exaclty is that is not working ?