Shop OBEX P1 Docs P2 Docs Learn Events
PropBasic TASK not running — Parallax Forums

PropBasic TASK not running

SpillerSpiller Posts: 52
edited 2010-12-17 21:16 in Propeller 1
HI All,

I have attached two PropBasic program here.
First is written for running in the main cog. (COG 0) It is working.
Second the same program is written as TASK dedicated to COG 1. It is not running.

I did't understand what can be the problem.

Best Regards

Spiller

Comments

  • BeanBean Posts: 8,129
    edited 2010-12-17 16:51
    The problem is you have the PINs defined as HIGH or LOW. When you do that the main cog sets the pins to that state.
    If the main cog has a pin as an output, then a TASK cannot make it an INPUT.
    And if the main cog has a pin as HIGH, then a TASK cannot make it LOW.

    Either remove the HIGH and LOW when you define the pins, or define the PINs inside the TASK.

    Bean
  • SpillerSpiller Posts: 52
    edited 2010-12-17 21:16
    Thans Bean,

    Spiller
Sign In or Register to comment.