apps/sctl/imconf_load.php

Go to the documentation of this file.
00001 <?php
00002 $inits=parse_ini_file("/etc/image_settings.conf");
00003 $init_pars=array();
00004 reset($inits);
00005 while(list($key, $value) = each($inits)) {
00006         $init_pars[$key] = (int)$value;
00007 }
00008 
00009 // Start with reset (normally not needed, just to make sure we have a clean start, not relying on previous programming)
00010 if(elphel_get_state() > 7) {  
00011         elphel_compressor_stop(); 
00012         while(elphel_get_state() > 7) ; 
00013         elphel_compressor_reset(); 
00014         elphel_compressor_reset(); 
00015 }
00016 elphel_reset_sensor();
00017 elphel_set_P_arr($init_pars);
00018 // Program sensor (with restart)
00019 elphel_program_sensor (0);
00020 //  echo "Parameters after programmimg:\n";
00021 //  print_r(elphel_get_P_arr($init_pars));
00022 // start compressor:
00023 elphel_compressor_run();
00024 elphel_wait_frame();
00025 elphel_set_P_arr($init_pars);
00026 elphel_wait_frame();
00027 // or just acquire a single frame
00028 //  elphel_compressor_frame();
00029 ?> 

Generated on Fri Nov 28 00:06:22 2008 for elphel by  doxygen 1.5.1