Upload
stewart-moody
View
215
Download
0
Embed Size (px)
Citation preview
Stanford Linear Accelerator Center
PowerPC and VXI
Kinetic Systems V151Embedded PowerPC Slot-0
Controller
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
2
Objective
• Port the EPICS low-level RF code to another VXI slot-0 controller
vxWorks 5.3.1 and EPICS R3.13.2 Current cpu, niCpu030 has been discontinued Crate profile – SLAC VXI register based modules and AB
VME Scanner
• Why choose the PowerPC Pressure at SLAC to replace niCpu030 Intel slot-0 controllers (NI) did not have favorable reviews Consistency; one ppc architecture for VMEbus and VXIbus
projects at SLAC byte orientation (big endian) is the same as the 68K
architecture of the niCpu030
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
3
Hardware Issues
• Elma crate power-on hang • SYSRST not asserted on reboot• D8/D16 IACK Cycle • SLAC VXI modules and the VXI spec• Interrupt controller uses a
mechanism for autovectoring VME interrupts
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
4
Software Issues• Learning about the VXIbus Standard as well the SLAC
VXI register-based modules.• Interrupts
1 Interrupt Level instead of 7 as with 68k Architectory Missing functions intVecGet Unsolicited Interrupt Handlers – different naming standard VXI mode vs. VME mode
• Lack of atomic Read-Modify-Write• VXI Library
Incorrect and/or buggy library - Resman crashes Missing basic functions – GetMyLA,SetMODID VXI library initialization
• A32 Space – device window configuration EPICS_VXI_A32_BASE 0x20000000 0x9000000 EPICS_VXI_A32_SIZE 0x00100000 0x1000000
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
5
Code Changes• EPICS Code changed
drvEpvxi.c,devLib.c,veclist.c – table of unsolicited interrupts Crate a dummy isr static void *vmeArgTbl[ 7] ; devInterruptConnectVXI( level,isr,parm ) dummyISR(controller,statusId,level) { myVmeIsr( vmeArgTbl( vmeArgTbl[level-1] ) ) }
• Bsp kernel changes Adding functionality – sysBusTas,intVecGet (Andrew Johnson) VXI vs VME mode – VXI/VME fighting for control of the bus sysUniverseIntHandler – VXI vs VME mode sysVme.c - KSC method of taking control of VME interrupt
autovectoring
t;;
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
6
Vector Table0
…
…
...
11
…
…
…
254
255
Handler
Argument
Next
Universe VME InterruptkscIntHandler
sysUniverseIntHandler
vxiBaseIsr
PPC External Interrupt
Vector 0x500
Kristi Luchini EPICS Collaboration - Nov 14/17, 2000 - Oak ridge
7
VXI Vector Table
Level ISR
1 DefaultVXIintHandler
2 DefaultVXIintHandler
3 DefaultVXIintHandler
4 DefaultVXIintHandler
5 DefaultVXIintHandler
6 DefaultVXIintHandler
7 DefaultVXIintHandler
Kristi Luchini EPICS Collaboration Mtg. - Nov 14-16,2000 Oak Ridge
8
Conclusions• Prefer a BSP supported by the OS• Ask for VXI library code• Awaiting SLAC VXI board
modification to recognize D8 IACK cycle