[Newbies] Win32 OS functions

David T. Lewis lewis at mail.msen.com
Fri Dec 22 14:48:25 UTC 2006

There has been some recent discussion on this topic on the squeak-dev
mailing list. You may want to join that list for the more technical

In a nutshell, Squeak does not currently support callbacks from primitives,
but other mechanisms are available. For example, you can signal a Squeak
Semaphore from a primitive to notify a waiting Process that something
has happened.


On Fri, Dec 22, 2006 at 02:14:28PM -0000, david.briant at ubs.com wrote:
> Thanks. Are there examples of how to do a call-back into Smalltalk or
> read from a Windows message queue?
> It's been a while since I compiled a VM (1995 was the last time in VW2)
> and I've not used Smalltalk since '97 so not totally sure what I snow
> possible. I'd like to get two squeak images to talk together using
> memory mapped files and asynchronous windows message sends or possibly
> named pipes.
> Thanks for your help
> David
> -----Original Message-----
> From: beginners-bounces at lists.squeakfoundation.org
> [mailto:beginners-bounces at lists.squeakfoundation.org] On Behalf Of David
> T. Lewis
> Sent: 22 December 2006 13:46
> To: A friendly place to get answers to even the most basic questions
> aboutSqueak.
> Subject: Re: [Newbies] Win32 OS functions
> On Fri, Dec 22, 2006 at 08:38:01AM -0000, david.briant at ubs.com wrote:
> > Hi
> > 
> > I want to play around with some cross-thread and cross-process stuff
> in
> > Windows XP. E.g. memory mapped files, windows message sends, named
> pipes
> > and so on and was wondering how to access these methods in Squeak. Any
> > pointers would be welcome.
> The easiest way to do things like this is with the Foreign Function
> Interface (FFI). Usually you can find this in the Squeak image in
> the "FFI-*" categories (but for some versions you may need to load it
> from SqueakMap). Look at category 'FFI-Examples-Win32' for examples of
> what can be done.
> This is definitely getting out of "newbie" territory, but if you are
> comfortable building your own VM and plugins, you can also load the
> OSProcessPlugin from SqueakMap. This provides some Win32 thread and
> handle primitives that might be useful to you, or that you can modify
> to meet your needs.
> Have fun,
> Dave

More information about the Beginners mailing list