[squeak-dev] Raspberry PI & omxplayer from Squeak

Eliot Miranda eliot.miranda at gmail.com
Thu Nov 19 02:36:10 UTC 2015


Hi Jon,

   The
primitive primForkExec:stdIn:stdOut:stdErr:argBuf:argOffsets:envBuf:envOffsets:workingDir:
directly calls execute, so if you invoke it with the name of the program it
will fork and exec that program and answer its pid.  Not sure where the
substitution of the shell is.  Is omxplayer perhaps a shell script that
wraps the actual program?

I suggest you step though execution from your launch command all the way to
the send of
primForkExec:stdIn:stdOut:stdErr:argBuf:argOffsets:envBuf:envOffsets:workingDir:
and see what its being invoked with, and you check what the omxplayer file
is in the rip filesystem.

(I could be completely confused but
see UnixOSProcessPlugin>>#forkAndExecInDirectory: in the
VMConstruction-Plugins-OSProcessPlugin package at
http://www.squeaksource.com/OSProcessPlugin and I think you'll agree with
me that the primitive does not interpose a shell).

HTH

On Wed, Nov 18, 2015 at 6:12 PM, Jon Hylands <jon at huv.com> wrote:

>
> Hi,
>
> I've been playing around with Squeak 5.0 on a pi 2 (with the 7" LCD
> touchscreen), and one of the things I'd like to be able to do is run (and
> control) omxplayer from within Squeak.
>
> I did the same thing with Python, using this library:
> https://github.com/willprice/python-omxplayer-wrapper/tree/develop/omxplayer
>
> However, I don't really need all the fancy controls - what I really want
> is a way to launch it, and then a way to kill it. I'll be streaming live
> MJPEG video from a webcam, so there is no concept of pause/stop/etc. I need
> to kill it because I want the ability to choose one of a couple different
> video streams.
>
> I tried using OSProcess, but it gives me the pid of the shell script that
> launches the application, and not the application itself. I could certainly
> hack something using ps and grep, but I would prefer if there were a better
> way to do it.
>
> Any ideas?
>
> Thanks,
> Jon
>
>
>
>
>


-- 
_,,,^..^,,,_
best, Eliot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20151118/b914279a/attachment-0001.htm


More information about the Squeak-dev mailing list