newbie to dolphin and smalltalk

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

newbie to dolphin and smalltalk

johncwhi
I'm really new to both Smalltalk and Dolphin.  I cannot tell so far
whether it is possible to call to Win32 API functions from Dolphin.  Is
this possible?

What I'd like to do, once I figure out how, is get access to the Win32
serial I/O functions.

TIA.


Sent via Deja.com
http://www.deja.com/


Reply | Threaded
Open this post in threaded view
|

Re: newbie to dolphin and smalltalk

Costas Menico-2
I am not sure if you want to do serial I/O from Win32 API but you may
want to use the ActiveX control, MSCOMM32.OCX and add it in as an
ActiveX control to Dolphin.

As far as the Win32 functions the class definitions are  under
ExternalLibrary.

Costas Menico


[hidden email] wrote:

>I'm really new to both Smalltalk and Dolphin.  I cannot tell so far
>whether it is possible to call to Win32 API functions from Dolphin.  Is
>this possible?
>
>What I'd like to do, once I figure out how, is get access to the Win32
>serial I/O functions.
>
>TIA.
>
>
>Sent via Deja.com
>http://www.deja.com/


Reply | Threaded
Open this post in threaded view
|

Re: newbie to dolphin and smalltalk

Steve Waring-2
In reply to this post by johncwhi
Hi John,

>I cannot tell so far
> whether it is possible to call to Win32 API functions from Dolphin.  Is
> this possible?

Yes it is possible, and based on what Blair recently wrote, the calls are
almost as fast as primitive methods. Alot of Dolphin is implemented in this
way, for example look at the class Canvas which essientially wraps a
graphics device context, and makes calls to the 'GDI32' library using the
class  GDILibrary.

If you want to call a function that Object Arts have not wrapped, you will
need to do it yourself. If you are familiar with the Win32 API, then this is
fairly simple to do. Have a look at;
http://www.object-arts.com/EducationCentre/Overviews/ExternalInterfacing.htm

I think I recently saw a message from Andy saying that they Object Arts were
working on this documentation, so there may be something more on this soon.
There is also the wiki web, a good place to start would be;
http://www.object-arts.com/wiki/html/Dolphin/ExternalInterfacing.htm


> What I'd like to do, once I figure out how, is get access to the Win32
> serial I/O functions.

As Costas mentioned, the easiest way is to use COM, because Dolphin can use
the type libraries to auto-generate all the function calls/constants and
structures.

You may also want to take a look at Ian Bartholomew's excellent goodies at;
http://www.iandb.org.uk/
He has a Serial Port Goodie which may do exactly what you need!

All the best,
Steve