AnsweredAssumed Answered

AW: multi-threads

Question asked by VRFuser on Aug 18, 1999
Write an init-function with all your initialization code in it. After
calling the init-function, you can start the other treads. Of course you
need to wire some execution pins for that reason.
If you can not do that, you can use a 'init_done-variable', which is set to
a certain value at the end of the init-code.


> -----Ursprngliche Nachricht-----
> Von:     Barrie Walden []
> Gesendet am:     Mittwoch, 18. August 1999 21:17
> An:     HPVee
> Betreff:     multi-threads
> Its me again,
> This is probably something simple but the solution is eluding me. I need
> to run some code which establishes the values of some global variables
> before running a number of independent threads simultaneously.  These
> threads contain never ending loops and they must run at the same time so
> I can't chain them together.  My only solution so far has been to
> include a delay in each of the threads so that the initialization code
> has time to complete before any of the global values are actually
> needed.  There must be a cleaner way.
> What am I missing?
> Barrie