source: MML/trunk/machine/SOLEIL/StorageRing/bpm/IHMorbitFT.m @ 4

Last change on this file since 4 was 4, checked in by zhangj, 10 years ago

Initial import--MML version from SOLEIL@2013

File size: 2.4 KB
Line 
1orbfig = findobj(allchild(0),'tag','FTsetup');
2
3if ~isempty(orbfig), delete(orbfig); end
4orbfig = findobj(allchild(0),'tag','FTsetup');
5
6if ~isempty(orbfig), delete(orbfig); end
7
8kmax = 8; % button number
9
10height = 10 + kmax*30 + 30; %670;
11a = figure('Color',[0.8 0.8 0.8], ...
12    'Interruptible', 'on', ...   
13    'HandleVisibility','off', ...
14    'MenuBar','none', ...
15    'Name', 'First Turn Orbit correction (experimental interface)', ...
16    'NumberTitle','off', ...
17    'Units','pixels', ...
18    'Position',[5 70 210*2 height], ...
19    'Resize','off', ...
20    'Tag','FTsetup');
21
22height = height - 35;
23
24for k = 1:kmax,
25    b1(k) = uicontrol('Parent',a, ...
26        'Position',[3 height-(k-1)*30 204 27], ...
27        'Interruptible', 'off', ...
28        'Tag','button22');
29end
30
31for k = 1:kmax,
32    b2(k) = uicontrol('Parent',a, ...
33        'Position',[3 + 210 height-(k-1)*30 204 27], ...
34        'Interruptible', 'off', ...
35        'Tag','button22');
36end
37
38set(b1(1), 'String','H plane','BackGroundColor','b');
39set(b1(2), 'Callback','firstturnscorrection(Xcod,''Horizontal'',''NoDisplay'');', 'String','H Correction (No Display)');
40set(b1(3), 'Callback','firstturnscorrection(Xcod,''Horizontal'');', 'String','H Correction');
41set(b1(4), 'Callback','setsp(''HCOR'',0);disp(''zeroing HCOR'');', 'String','HCOR to zero');
42set(b1(5), 'Callback','HCOR0_ = getam(''HCOR'');disp(''HCOR saved'');', 'String','Save HCOR (1-depth buffer)');
43set(b1(6), 'Callback','setsp(''HCOR'',HCOR0_);disp(''HCOR restored'');', 'String','Set back HCOR (1-depth buffer)');
44set(b1(7), 'Callback','figure; plot(getspos(''BPMx''),Xcod); grid on;', 'String','plot H-cod');
45set(b1(8), 'Callback','', 'String','Compute COD');
46
47set(b2(1), 'String','V plane','BackGroundColor','r');
48set(b2(2), 'Callback','firstturnscorrection(Zcod,''Vertical'',''NoDisplay'');', 'String','V Correction (No Display)');
49set(b2(3), 'Callback','firstturnscorrection(Zcod,''Vertical'');', 'String','V Correction');
50set(b2(4), 'Callback','setsp(''VCOR'',0);disp(''zeroing VCOR'');', 'String','VCOR to zero');
51set(b2(5), 'Callback','VCOR0_ = getam(''VCOR'');disp(''VCOR saved'');', 'String','Save VCOR (1-depth buffer)');
52set(b2(6), 'Callback','setsp(''VCOR'',VCOR0_);disp(''VCOR restored'');', 'String','Set back VCOR (1-depth buffer)');
53set(b2(7), 'Callback','figure; plot(getspos(''BPMz''),Zcod); grid on;', 'String','plot V-cod');
54set(b2(8), 'Callback','', 'String','Compute COD');
Note: See TracBrowser for help on using the repository browser.