ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/JSOC/proj/lev0/apps/do_patch.c
Revision: 1.4
Committed: Mon Mar 31 21:45:41 2014 UTC (9 years, 5 months ago) by kehcheng
Content type: text/plain
Branch: MAIN
CVS Tags: Ver_8-8, Ver_8-6, Ver_8-7, Ver_8-5, Ver_8-10, Ver_8-11, Ver_8-12
Changes since 1.3: +13 -0 lines
Log Message:
Add 2014.03.30 camera 1 lookup table corruption handling.

File Contents

# Content
1 // crop table corruption Dec 2011 - Jan 2012
2 // skip value for row 1065 in quadrant E (lower left)
3 // was 512 pixels too large. Need to shift whole row
4 // right by 512 pixels and fill in MISSING on the left
5
6 void do_patch1(short *adata0)
7 {
8 short *p = adata0+4096*1065;
9 short tmp[2048];
10 int i;
11 for (i=0; i<512; ++i) tmp[i] = DRMS_MISSING_SHORT;
12 for (i=512; i<2048; ++i) tmp[i] = p[i-512];
13 memcpy(p, tmp, 4096);
14 }
15
16
17 // Camera 1 lookup table corruption 2014.03.30 from 12:20 UT to 16:25 UT.
18 // Single bit hit to output value; 0x1912 (6418) changed to 0x3912 (14610)
19 // FSN range is 70397305 to 70405129
20 // Any value of 14610 should be changed to 6418
21
22 void do_patch2(short *adata0)
23 {
24 int i;
25 for (i=0; i<4096*4096; ++i)
26 if (adata0[i] == 14610) adata0[i] = 6418;
27 }