From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=0.4 required=5.0 tests=AC_FROM_MANY_DOTS,BAYES_00, PP_MIME_FAKE_ASCII_TEXT autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII X-Google-Thread: 103376,f48da8b15007eae1,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-11-04 12:44:20 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed1.swip.net!swipnet!nntpserver.swip.net!not-for-mail From: =?ISO-8859-1?Q?Bj=F6rn?= Lundin Subject: Waiting for callbacks from dll on Win32 Newsgroups: comp.lang.ada User-Agent: KNode/0.7.1 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit Message-ID: NNTP-Posting-Host: 213.101.76.12 X-Complaints-To: news-abuse@swip.net X-Trace: nntpserver.swip.net 1036442646 213.101.76.12 (Mon, 04 Nov 2002 21:44:06 MET DST) NNTP-Posting-Date: Mon, 04 Nov 2002 21:44:06 MET DST Organization: A Customer of Tele2 X-Sender: x-367446@d213-101-76-12.swipnet.se Date: Mon, 04 Nov 2002 21:46:02 +0100 Xref: archiver1.google.com comp.lang.ada:30360 Date: 2002-11-04T21:46:02+01:00 List-Id: 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. The problem is, how can I stop the console application and wait for callbacks? I can, by debuging the dll and the opc-server, see that it calls the callback procedure, but only sometimes the ada code responds. I tried establishing the callback, and then have the main task hang on a protected entry whose guard is released by the callback, but no luck. I also tried having a task watch for the callback, but no luck. I also dribbeled with having the guard a global varable, in another protected object, in the same protected object as the waiting entry, but still no luck. I should say that i get the callbacks occationly, but just about every 30th time I run the program. It seems to me that the callback doesn't get cpu-time most of times? Lately, i threw in a pragma Interrupt_priority in the protected object, but still no luck? Anyone with suggetions/pointers? /Bj�rn