Skip to content

Commit

Permalink
Name collision with softglue
Browse files Browse the repository at this point in the history
  • Loading branch information
keenanlang committed Aug 21, 2019
1 parent 9414c15 commit e56b23a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions softGlueApp/src/drvZynq.c
Original file line number Diff line number Diff line change
Expand Up @@ -557,13 +557,13 @@ int initZynqSingleRegisterPort(const char *portName, const char *componentName)
}

/*
* softGlueCalcSpecifiedRegisterAddress - For access to a single-register component by
* softGlueZCalcSpecifiedRegisterAddress - For access to a single-register component by
* other than an EPICS record (for example, by an interrupt-service routine).
* The AXI and word offset are specified as arguments, and we need
* to translate that information into a memory mapped address, as calcRegister32Address()
* would have done for an EPICS record.
*/
epicsUInt32 *softGlueCalcSpecifiedRegisterAddress(int type, int addr)
epicsUInt32 *softGlueZCalcSpecifiedRegisterAddress(int type, int addr)
{
drvZynqPvt *pPvt;
epicsUInt8 *reg8;
Expand Down
2 changes: 1 addition & 1 deletion softGlueApp/src/drvZynq.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ int findUioAddr(const char *componentName, int map);
int softGlueRegisterInterruptRoutine(epicsUInt32 risingMask, epicsUInt32 fallingMask,
void (*routine)(softGlueIntRoutineData *IRData), void *userPvt);

epicsUInt32 *softGlueCalcSpecifiedRegisterAddress(int type, int addr);
epicsUInt32 *softGlueZCalcSpecifiedRegisterAddress(int type, int addr);
2 changes: 1 addition & 1 deletion softGlueApp/src/readSoftGlueCounter_ISR.c
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ int readSoftGlueCounter_ISRPrepare(epicsUInt32 risingMask) {
/* Get the address of the COUNTS registers of eight counters. */
for (i=0; i<5; i++) {
/* The first arg specifies which AXI component: 0 for 8-bit I/O point register, 1 for 32-bit register */
rcISRData.addr[i] = softGlueCalcSpecifiedRegisterAddress(1, counterOffset[i]);
rcISRData.addr[i] = softGlueZCalcSpecifiedRegisterAddress(1, counterOffset[i]);
if (readSoftGlueCounter_ISRDebug) {
printf("readSoftGlueCounter_ISRPrepare: addr[%d]=%p\n", i, rcISRData.addr[i]);
}
Expand Down
4 changes: 2 additions & 2 deletions softGlueApp/src/sampleCustomInterruptHandler.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,13 @@ int sampleCustomInterruptPrepare(epicsUInt32 risingMask, epicsUInt32 fallingMask
* The address 123 is from softGlue_FPGAContent.substitutions.
* We want to write to bit 5.
*/
myISRData.addr = softGlueCalcSpecifiedRegisterAddress(0, 123);
myISRData.addr = softGlueZCalcSpecifiedRegisterAddress(0, 123);

/* Get the address of the divByN N register.
* The address 38 is from softGlue_FPGARegisters.substitutions.
* It's the DivByN-3_N register to which we want to write.
*/
//myISRData.addr = softGlueCalcSpecifiedRegisterAddress(1, 38);
//myISRData.addr = softGlueZCalcSpecifiedRegisterAddress(1, 38);

/* Tell softGlue to call sampleCustomInterruptRoutine() when its interrupt-service routine handles an interrupt
* from the specified carrier, slot, sopcAddress (I/O register), and bit (mask). This also
Expand Down

0 comments on commit e56b23a

Please sign in to comment.