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=-1.3 required=5.0 tests=BAYES_00,FREEMAIL_FROM, INVALID_MSGID,XPRIO autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a56c0205ffee5add,start X-Google-Attributes: gid103376,public From: "Josh Highley" Subject: Win32 joystick problems Date: 1999/08/15 Message-ID: <7p82ua$p8r$1@bgtnsc02.worldnet.att.net>#1/1 X-Deja-AN: 513234934 X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc02.worldnet.att.net 934776586 25883 12.71.38.137 (16 Aug 1999 04:09:46 GMT) Organization: AT&T WorldNet Services X-MSMail-Priority: Normal NNTP-Posting-Date: 16 Aug 1999 04:09:46 GMT Newsgroups: comp.lang.ada Date: 1999-08-16T04:09:46+00:00 List-Id: I've been trying to read the position of the joystick using the Win32 bindings included with Gnat 3.11 and AdaGIDE 6.21. I'm running this under Win 95. Since I haven't done any Win32 programming, I created a quick and simple test program. However, I can't get it to link. It compiles okay, but when I build it, gnatlink returns: gnatlink -g joytest.ali ./joytest.o: In function 'ada_joytest': C:/GNAT311/Programs/c:/gnat311/programs/joytest.adb:23: undefined reference to 'joyGetPos@8' gnatmake: *** link failed. Here's the test program I'm trying to run: -------------------------------------------------------------- with ada.text_io; with win32.mmsystem; use ada.text_io; use win32.mmsystem; procedure joytest is joystick_info : lpjoyinfo; joyID : win32.UINT := 1; -- ?? I'm not sure about this value result : mmresult; package mmresult_io is new ada.text_io.modular_io(mmresult); package UINT_io is new ada.text_io.modular_io(Win32.UINT); use mmresult_io; use UINT_io; begin -- This is the function prototype for joyGetPos: -- function joyGetPos( -- uJoyID: Win32.UINT; -- lpji : LPJOYINFO) -- return MMRESULT; result := joyGetPos(joyID , joystick_info); put("Result: "); put(result); new_line; put("Joystick X-axis: "); put(joystick_info.wxpos); new_line; put("Joystick Y-axis: "); put(joystick_info.wypos); new_line; end joytest; ---------------------------------------------------- Like I said, I'm new to Win32 programming so the problem might be obvious to someone who knows what they are doing. Any help would be greatly appreciated. Thanks, Josh joshhighley@hotmail.com