comp.lang.ada
 help / color / mirror / Atom feed
From: "Warren W. Gay VE3WWG" <ve3wwg@cogeco.ca>
Subject: Re: Waiting for callbacks from dll on Win32
Date: Tue, 05 Nov 2002 13:33:14 -0500
Date: 2002-11-05T13:33:14-05:00	[thread overview]
Message-ID: <3DC80EEA.9090807@cogeco.ca> (raw)
In-Reply-To: pUTx9.484$0d2.1468@nntpserver.swip.net

Bj�rn Lundin wrote:
> Warren W. Gay VE3WWG wrote:
>>Stephen Leake wrote:
>>
>>>Bj�rn Lundin <bjorn.lundin.nospam@swipnet.se> writes:
>>>
>>>>Hello!
>>>>I'm trying to make an interface to a c-dll that
>>>>connects to an OPC-server (WTclient.dll)
>>>>
>>>>It wants a pointer to a procedure, which I can provide
>>>>with an access value to a procedure in a protected object.
>>>
>>>
>>>Calling a procedure in a protected object is _not_ the same as calling
>>>a "normal" procedure; there are tasking issues involved.
>>>
>>>Wrap the protected object call in a "normal" procedure, and use that
>>>as the callback.
>>>
>>>Even then, you have to worry about the Ada tasking vs the C tasking.
>>>If you have an Ada main, you are probably ok.
>>
>>I think you also have to keep in mind that DLL tasks are
>>separate from your calling environment.  So this may
>>complicate things depending upon the details.
> 
> I don't quite understand, could you elaborate a bit?
> /Bj�rn

I have not had personal experience with this yet, but I have
read somewhere that DLL tasks run in their own "environment"
different from the calling "environment". Ie. if your DLL
is an Ada95 DLL, its tasks are separately managed from the
calling Ada95 application.

If it is not an Ada95 DLL, you can probably ignore this. However,
if that DLL creates windows threads, you may have some threading
issues. I am not really qualified to expand on this further,
since I live mainly in the UNIX world. I would do a Google
search on "DLL threads tasks" etc.

-- 
Warren W. Gay VE3WWG
http://home.cogeco.ca/~ve3wwg




  reply	other threads:[~2002-11-05 18:33 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-04 20:46 Waiting for callbacks from dll on Win32 Björn Lundin
2002-11-04 21:09 ` Stephen Leake
2002-11-05 17:58   ` Warren W. Gay VE3WWG
2002-11-05 18:16     ` Björn Lundin
2002-11-05 18:33       ` Warren W. Gay VE3WWG [this message]
2002-11-06  8:23         ` Pascal Obry
2002-11-06 16:39           ` Björn Lundin
2002-11-05 18:15   ` Björn Lundin
2002-11-09  4:30     ` SteveD
  -- strict thread matches above, loose matches on Subject: below --
2002-11-07  5:46 Grein, Christoph
2002-11-07 19:26 ` Björn Lundin
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox