Fast Orbit Feedback BPM to PS Yuke Tian
Fast Orbit Feedback - BPM to PS Yuke Tian Control Group, Accelerator Division Photon Sciences Directory Brookhaven National Lab EPICS Collaboration Meeting, BNL, 2010
Outline • • NSLS-II orbit feedback system requirements Fast orbit feedback system architecture • • • Overall architecture BPM FOFB data measurement BPM FOFB data delivery – fiber SDI link FOFB calculation – compensation for each eigenmode • Corrector setpoints to power supply system Progress Summary EPICS Collaboration Meeting, BNL, 2010
NSLS-II orbit feedback system requirement NSLS-II technical Requirements & Specifications Energy 3. 0 Ge. V Circumference 792 m Number of Periods 30 DBA Length Long Straights 6. 6 & 9. 3 m Emittance (h, v) <1 nm, 0. 008 nm Momentum Compaction. 00037 Dipole Bend Radius 25 m Energy Loss per Turn <2 Me. V Energy Spread RF Frequency MHz Harmonic Number RF Bucket Height RMS Bunch Length 30 ps Average Current (500 ma) Current per Bunch Charge per Bunch Touschek Lifetime EPICS Collaboration Meeting, BNL, 2010 0. 094% 500 1320 >2. 5% 15 ps 300 ma 0. 5 ma 1. 2 n. C >3 hrs
NSLS-II orbit feedback system requirement Lattice function for one cell Long ID Dispersion Region Short ID EPICS Collaboration Meeting, BNL, 2010
NSLS-II orbit feedback system requirement NSLS-II orbit stability requirement , hence must hold orbit stable to In short insertion, Orbit stability requirements can be met using orbit feedback. EPICS Collaboration Meeting, BNL, 2010
NSLS-II orbit feedback system requirement Noises source need to be suppressed Long term - Years/Months Ground movement Season changes Medium - Days/Hours Sun and Moon Day-night variations (thermal) Rivers, rain, water table, wind Synchrotron radiation Refills and start-up Sensor motion Drift of electronics Local machinery Filling patterns Short - Minutes/Seconds Ground vibrations Traffic, Earth quakes Power supplies Injectors Insertion devices Air conditioning Refrigerators/compressors Water cooling Beam instabilities in general EPICS Collaboration Meeting, BNL, 2010
NSLS-II orbit feedback system requirement Typical noises source frequency in light source EPICS Collaboration Meeting, BNL, 2010
NSLS-II orbit feedback system Beamrequirement motion from long term group motion Lihua Yu Floor motion around the ring. Maximum movement is 107 µm, and the RMS around the ring is 36 µm. Electron beam motion (vertical) without feedback loop; maximum is 600 µm. EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Overall architecture: slow and fast correctors EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Fast orbit feedback system in one cell EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture NSLS-II two tier device controller architecture Cell 1 Cell 30 Cell 29 Cell 3 Storage Ring SDI link Cell 17 Cell 15 Cell 16 EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture NSLS-II FOFB latency/bandwidth ● BPM group delay: less than 50 us (estimate) ● BPM data from 8 BPMs transferred to cell controller: 3. 5 us ● BPM data distribute among the storage ring 6 us (12 us if one link broken) ● FOFB calculation with separate mode compensation: 3. 5 us ● Set power supply by PS SDI link: 5. 4 us (11 us if one link broken) ● Fast corrector PS bandwidth (10 degree phase shift): 8 KHz ● Corrector magnet/chamber bandwidth: 1 KHz EPICS Collaboration Meeting, BNL, (measured with Inconel beampipe, 102010 degree phase
Orbit feedback system architecture BPM FOFB data measurement Joseph Mead EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture BPM FOFB data measurement EPICS Collaboration Meeting, BNL, 2010 Kiman Ha
Orbit feedback system architecture BPM FOFB data delivery – fiber SDI link Joseph De Long EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture FOFB calculation – compensation for each eigenmod • Fast orbit feedback system is a typical multiple-input and multiple-output (MIMO) system. For NSLS-II, there are 240 BPMs and 90 fast correctors. Tranditional singular value decomponsition (SVD) based FOFB treats each eigenmode the same. • The reality is, a MIMO system will have different frequency response for different eigenmode and thus it is desirable to design different compensation to each eigenmode. • The challenge is to finish the large computation within the time budget of FOFB system. • NSLS-II FOFB system takes advantage of our two-tier communication structure and the parallel computation capability of FPGA to do the compensation for each EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture A simple SISO feedback system Controller Plant C(z) H(z) EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Fast orbit feedback system algorithm (MIMO system) Controller Compensator Accelerator R-1=VΣ-1 UT (PID etc) R=UΣVT R: response matrix R-1: reverse response matrix FOFB baseline algorithm Offline operation: kick each corrector measure all BPM and get response matrix R calculate R-1 with SVD (10 KHz) operation: measure/distribute all BPM data calculate corrector setpoints set correctors EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture FOFB baseline calculation For each corrector plane Each of the corrector setpoint is calculated from a 1 x. M vector and Mx 1 vector multiplication. If 8 BPM/cell, M=240. EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Problems for baseline algorithm The ill-conditioned response matrix will cause numerical instability Solution: 1) Truncated SVD (TSVD) regularization: sharp cut off 2) Tikhonov regularization For each corrector plane Each of the corrector setpoint is calculated from a 1 x. M vector and Mx 1 vector multiplication. If 8 BPM/cell in NSLS-II, M=240. Total: ~240 MAC. EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Problems for baseline algorithm To suppress high frequency contribution to the integrated amplitude, it is desirable to compensate each mode in frequency domain. So far, all the FOFB has an assumption that each mode has the same frequency response (same bandwidth). Compensation for each eigenmode UT Qi(z 1) V EPICS Collaboration Meeting, BNL, 2010 Accelerator R=UΣVT
Orbit feedback system architecture mode Calculation with the compensation for each : eigentspace components of : Compensator for mode i. EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture mode Calculation with the compensation for each 1. Calculate the eigenvector components (d 1, d 2, …d. N) for BPM displacement Total calculation: 1 x. M vector times Mx 1 vector. Do this N times (for each ). This is N times larger calculation than gain-only FOFB calculation. For NSLS-II, N=90. Total MAC: 240 * 90 = 21, 600 2. For each , design compensation 3. Output modes (V) times . . 1 x. N vector times Nx 1 vector. Challenge: need to finish the calculation within a few microsecond. FPGA is perfect for this task. It can carry out the calculation (Matrix calculation and DSP compensation) in parallel. EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback mode Calculation with the compensation for one Du Eigenvector al From control system Por Select Active Eigenvector t RA Du M Eigenvector al From control system Por t MU X X RA Du M BPM data al From SDI link Por t + n Compensatio (PID, Notch filter etc) RA M EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Single mode component compensation (floating point module) EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Single mode component compensation (floating point module) Simulated BPM data Single mode component Simulated input matrix Single mode component with compensati EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Single mode component compensation (compare fixed point and floating point module) EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback System. Generator: floating point with fixedx point EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Single mode component compensation (compare FPGA fixed point and Matlab floating point calculation) Calculation difference for single mode component with compensation EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Single mode component compensation (FPGA hardware co-simulation and Matlab floating point calculation) EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Compare FPGA hardware co-simulation results and Matlab floating point calc EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Flexible frequency compensation in FPGA for each eigenmode 60 Hz notch filter 200 KHz low path filter EPICS Collaboration Meeting, BNL, 2010
Implementation of fast orbit feedback Calculation for corrector setting (one plane) One mode Total Speed (240+12)*10 = 2520 ns 2520 + (90+8)*10 =3500 ns Accuracy <10 ppm BRAM Resource (Virtex 5 FX 70) 1% of BRAM 33% of BRAM DSP Resource Depend on the compensation design. Need lots of DSP resource to compensate for all eigenmodes. Virtext 5 (Virtex 6) provides many DSP resources to achieve single mode compensation requirement. EPICS Collaboration Meeting, BNL, 2010
Orbit feedback system architecture Corrector setpoint to power supply system RX PSC TX RX TX TX RX RX TX PSC TX RX RX TX TX PSC (PSC master, Cell controller) RX PSC Master TX RX RX TX PSC TX RX RX TX Power supply SDI link TX RX RX TX PSC TX RX RX TX RX PSC TX Flexible package size Simply cabling between PSCs and cell controller. EPICS Collaboration Meeting, BNL, 2010 TX RX PSC Redundant 100 Mbps link to deliver FOFB calculation results (corrector setpoints) to PSC Dynamic ID assignment TX
Progress BPM – finished first revision RF signal inputs 4 ADC channels V 5 FPGA 256 MB DDR 2 SFP for fiber SDI link Gig. E to EPICS IOC EPICS Collaboration Meeting, BNL, 2010
Progress Cell Controller – finished first revision 12 50 Ohm TTL outputs 16 isolated TTL inputs 2 PS SDI links 4 analog outputs 256 MB DDR 2 V 5 FPGA SFP for fiber SDI link Gig. E to EPICS IOC EPICS Collaboration Meeting, BNL, 2010
Progress Power supply controller – in production 3 6 4 1 7 7 a 8 a 2 8 b 1 = JTAG connectors – Programming to FPGA and CPLD. 2 = RS 232 port – Communication to PC for diagnostic and software development. 3 = DDR 2 memory modules – PS diagnostic data, CPU memory. 4 = SDI connectors – Communication between PSC master (or cell controller) and PSC slaves. 5 = Fiber transceiver – Communication with PSI. 6 = Ethernet connector – Communication to EPICS IOC for PSC master. 7 = FPGA (Spartan 3 A) 8 = CPLD(8 a) & SPI memory(8 b) – Dual boot and remote programming functions. EPICS Collaboration Meeting, BNL, 2010 5
Progress • • BPM hardware (DFE and AFE) passed the first revision. The second revision is underway. Cell controller (DFE and IO board) passed the first revision. BPM FOFB data measurement is tested with lab simulated data and real beam data. BPM FOFB data delivery (fiber SDI link) is tested. FOFB calculation is tested. Power supply SDI link is tested. Power supply controller is in production. We are working on the FOFB system integration. It includes integration of BPM, cell controller and power supply controller units. EPICS Collaboration Meeting, BNL, 2010
Summary • NSLS-II tow tier structure provides fast and deterministic data transfer for BPM data (BPM to cell controller), and power supply setpoints (cell controller to power supply controller). Cell controller is the central data concentrator/generator that has all the necessary data for FOFB calculation and needs no extra data shuffling. All BPM and power supply data bits are put “on wire” once. • NSLS-II FOFB is taking advantages of the two tier structure and the parallel computation capability of FPGA to implement a unique FOFB algorithm that can carry compensation for each eigenmode. NSLS-II will be the first facility to implement such FOFB approach. • NSLS-II FOFB hardware, firmware and software design will be fully open to the community. For more hardware and firmware details, please go to tomorrow’s “Open Hardware EPICS Collaboration Meeting, BNL, 2010 Development Workshop”.
• • • Acknowledgments FOFB algorithm Lihua Yu Igor Pinayev BPM/ Cell controller development Kurt Vetter Joseph Mead Joseph De Long Kiman Ha Alfred Dellapenna Yong Hu Guobao Shen Om Singh Bob Dalesio PSC and PS design Wing Louie John Ricciardelli George Ganetis EPICS Collaboration Meeting, BNL, 2010
- Slides: 42