Catch all the cricket action. Download Yahoo! Score tracker
For instance, lets say mypgm is a loop. If you call it directly from the
shell you will not be able to use the prompt until the loop is finished,
because tShell is busy in your loop. On the other hand, if you spawn a new
task and tell it to run mypgm, the new task will be busy in your loop, not
tShell.
Best regards,
Beny
Dear All
Thanks and regards
_______________________________________________
VxWorks Users Group mailing list
VxWe...@lbl.gov
http://www-csg.lbl.gov/vxworks/
> Dear All
>
> i am not able to understand the differance between spawning a task
> from shell ie sp mypgm and simply giving mypgm.
>
> Things that can under notice are......
> 1) -> mypgm
> value = 73393464 = 0x45fe538
> 2) -> sp signalTest
> task spawned: id = 460c8a8, name = s1u0
> value = 73451688 = 0x460c8a8
>
> Results r same but the values r different.Why ?..??
>
> Thanks and regards
directly mypgm, result value is mypgm()'s return value
if no value returned, shell value just a random number, not task ID
__Think__ of it as executing two different functions.
there is more going on here but I'm not up to writting many
pages today, so I'll save more details for later.
-> myprgm
executes your function "myprgm", causing the shell to block
until it completes, and the value displayed is whatever is
returned by your function (if it is void myprgm(), then
whatever junk is left on the stack).
-> sp myprogm
executes the shell command to spawn a task. this command
creates unique task with myprgm as teh entry point. sp
completes, and returns the task Id which gets displayed,
and myprgm runs as an independent task (if it loops forever
you can see it by executing -> i ), and will have the name
sUtN - where U will be replaced by the shell number, and N
will increment for each task created this way.
HTH
ha...@MccEngineering.Com
> _______________________________________________
> VxWorks Users Group mailing list
> VxWe...@lbl.gov
> http://www-csg.lbl.gov/vxworks/
=====
HADZ.
Never be afraid to try something new. Remember, amateurs built the ark. Professionals built the Titanic.
(this Email sent using 100% recycled electrons)
__________________________________
Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
http://calendar.yahoo.com