From 6ecbdeb10afa04a39c7f90f194d048c0462ff038 Mon Sep 17 00:00:00 2001 From: MarkRivers Date: Mon, 11 Jul 2011 15:14:19 +0000 Subject: [PATCH] Changed back to ipmIntConnect rather than devConnectInterruptVME. cast to (long) rather than (int) fixes compile errors on 64-bit Linux --- motorApp/HytecSrc/HytecMotorDriver.cpp | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/motorApp/HytecSrc/HytecMotorDriver.cpp b/motorApp/HytecSrc/HytecMotorDriver.cpp index 8b4e825a..3af9aeff 100644 --- a/motorApp/HytecSrc/HytecMotorDriver.cpp +++ b/motorApp/HytecSrc/HytecMotorDriver.cpp @@ -50,6 +50,10 @@ /* Fixed detecting encoder logic wrong bug */ /* 2.4 Bugs fix Jim Chen 24/06/2011 */ /* Fixed wrong ioc shell command function name */ +/* 2.5 Changes for 64bit Linux Jim Chen 07/07/2011 */ +/* Changed the cast modifier for "this" pointer in ipmIntConnect */ +/* function by (long) rather than (int) to suit 64bit Linux */ +/* build. */ /* */ /********************************************************************************/ @@ -75,7 +79,7 @@ #include "HytecMotorDriver.h" -static void ISR_8601(void* pDrv); +static void ISR_8601(int pDrv); static void intQueuedTask( void *pDrv ); #define MAX_MESSAGES 100 /* maximum number of messages */ @@ -187,12 +191,13 @@ asynStatus HytecMotorController::SetupCard() return asynError; } - /* Setup Interrupts. THIS SEEMS NOT RIGHT. 8601 HAS 4 AXIS AND EACH ONE HAS A VECTOR SO 4 ISRs ARE NEEDED?????????????? */ - st = devConnectInterruptVME( - this->vector, - ISR_8601, - this); - + /* Setup Interrupts. */ + st=ipmIntConnect(this->ip_carrier, + this->ipslot, + this->vector, + &ISR_8601, + (long)this); + /* If Interrupts NOT Setup OK */ if (st!=OK) { @@ -489,7 +494,7 @@ asynStatus HytecMotorController::writeFloat64(asynUser *pasynUser, epicsFloat64 } // ISR8601 Routines to handle interrupts -static void ISR_8601(void* pDrv) +static void ISR_8601(int pDrv) { HytecMotorController *pController = (HytecMotorController*) pDrv; HytecMotorAxis * pAxis;