Shop OBEX P1 Docs P2 Docs Learn Events
Multi Threaded SX/B - Page 3 — Parallax Forums

Multi Threaded SX/B

13»

Comments

  • IbsenIbsen Posts: 68
    edited 2007-03-07 23:22
    How will this be implemented in the SX/B compiler ???



    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔


    *.*

    Ibsen

    " It's nice to be important, but
    ·· more important to be nice... "
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-03-07 23:48
    Sparks,
    The sequence is not that strange. If you observe a specific digit, for example 0,
    you will notice that there are ten ticks between·0's. The pace is slow enough
    to count. This 10 is the supplied interval time in taskInterval array.
    The same applies to the other digits (eg. tasks).

    regards peter

    Post Edited (Peter Verkaik) : 3/7/2007 11:53:31 PM GMT
  • BeanBean Posts: 8,129
    edited 2007-03-08 01:24
    Ibsen said...

    How will this be implemented in the SX/B compiler ???

    We are working on it, it won't be any time soon though...

    Bean.


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap used 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com
    SX-Video Display Modules www.sxvm.com
    Coming soon! Propeller based OSD module www.hittconsulting.com
    ·
  • BeanBean Posts: 8,129
    edited 2007-03-09 16:29
    Anyone using the multitasking programs, I have discovered a bug in the SX/B compiler that affects these programs.

    Where Peter has aliased the array element bits:

    kMisrRunning var kFlag.6
    kMisrFinished var kFlag.7

    These aliases don't work properly. Actually both get aliased to just kFlag.

    The fix is to do this:

    kMisrRunningBit CON 6
    kMisrFinishedBit CON 7

    Then in the program replace "kMisrRunning" with "kFlag.kMisrRunningBit"
    and replace "kMisrFinished" with "kFlag.kMisrFinishedBit"

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap used 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com
    SX-Video Display Modules www.sxvm.com
    Coming soon! Propeller based OSD module www.hittconsulting.com
    ·
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-03-09 16:44
    Hi Bean,

    Thanks for that info.
    I was just debugging the programs using larger delays in the tasks.
    The tasks then appear to get stuck (eg. only 1 task keeps running).
    I adapted the programs with your suggestion and they seem to run ok now.
    I will upload the modified programs shortly.

    regards peter
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-03-09 17:15
    Here is the sx28 version.
    Don't forget to set pinTX to the I/O port you want to use.

    regards peter
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2007-03-09 23:16
    As promised, the sx48 version.

    regards peter
Sign In or Register to comment.