; ; FILE: comp_test.ips ; PURPOSE: Set up the data for a downlink test ; METHOD: When an image is taken and written to page 0, it is first extracted ; 1024x1024 into page 1 and then square root compressed into page 2. ; Either of those images can be downlinked. The header information is ; already in place. The compression method and parameters are patched ; by patching the $IPRL_COMP_PARAM register list (similar to the ; IPRL_TAPC* register list set) ; REGISTERS: ; IPRL_COMP_PARAM = dpc h, dpc l, n/k ; IPRL_COMP_SQRT ; HISTORY: Written 10-Jan-96 by M.Morrison ; ; QPROG_COMP_TEST:: ;---- Step #1: Making the observable SETREGS $IPRL_FLTGRAM_PARAM 4 0:0x0000 1:0x0226 ;set source page and destination pages COPYRD2D $IPRL_COMP_PARAM $IPRL_FLTGRAM_PARAM+8 3 ;last three words are n/k, dpc(h,l) CALLQUE $QSR_MK_FLTGRAM ;---- Step #2: Do square root compression SETREGS $IPRL_HDECODE_PARAM 2 0x0800 0x1000 CALLQUE $QSR_DO_HDECODE ;decode the value COPYREG $IPRP_HDECODE_PAGE1+8 $IPRP_HDECODE_PAGE2+8 ;copy the length of dataproduct COPYREG $IPRP_HDECODE_PAGE1+9 $IPRP_HDECODE_PAGE2+9 SETREGS $IPRP_HDECODE_PAGE2+6 2 2:0x0226 ;set up final destination ADDREGD $IPRP_HDECODE_PAGE2+5 0x1000 ;indicate that the dataproduct is square rooted ;only works with cropped or extracted DPCs _LOOKUP $IPRL_COMP_SQRT CALLQUE $QSR_DO_HEADER END