log_msg("Sensors on ports: $port_list_string were successfully initialized from configuration files pages $page_list_string",1);
log_msg("Sensors on ports: $port_list_string were successfully initialized at ".date("F j, Y, g:i a")." from configuration files pages $page_list_string");
@@ -895,15 +872,15 @@ function processInit($initPage, $needDetection = true) {
...
@@ -895,15 +872,15 @@ function processInit($initPage, $needDetection = true) {
// / They should look at thei enable bit periodically and restart if the frame is
// / They should look at thei enable bit periodically and restart if the frame is
// / the frame is not what they were expecting to be
// / the frame is not what they were expecting to be
if(elphel_get_frame($GLOBALS['master_port'])>0){
if(elphel_get_frame($GLOBALS['master_port'])>16){// =1 after initialization
echo"Current frame on master port =".elphel_get_frame($GLOBALS['master_port']).", sleeping to give daemons a chance\n";
log_msg("Current frame on master port =".elphel_get_frame($GLOBALS['master_port']).", sleeping to give daemons a chance");
elphel_set_P_value($GLOBALS['master_port'],ELPHEL_COMPRESSOR_RUN,0x00,0,ELPHEL_CONST_FRAMEPAIR_FORCE_NEWPROC);// / turn compressor off
elphel_set_P_value($GLOBALS['master_port'],ELPHEL_COMPRESSOR_RUN,0x00,0,ELPHEL_CONST_FRAMEPAIR_FORCE_NEWPROC);// / turn compressor off
foreach($GLOBALS['ports']as$port){
foreach($GLOBALS['ports']as$port){
elphel_set_P_value($port,ELPHEL_DAEMON_EN,0x00,0,ELPHEL_CONST_FRAMEPAIR_FORCE_NEWPROC);// / turn daemons off
elphel_set_P_value($port,ELPHEL_DAEMON_EN,0x00,0,ELPHEL_CONST_FRAMEPAIR_FORCE_NEWPROC);// / turn daemons off
}
}
usleep($waitDaemons*1000000);
usleep($waitDaemons*1000000);
echo"Current frame on master port =".elphel_get_frame($GLOBALS['master_port']).", waking up, daemons should be dead already\n";
log_msg("Current frame on master port =".elphel_get_frame($GLOBALS['master_port']).", waking up, daemons should be dead already");
}
}
/*
/*
if ($needDetection) {
if ($needDetection) {
...
@@ -912,12 +889,12 @@ function processInit($initPage, $needDetection = true) {
...
@@ -912,12 +889,12 @@ function processInit($initPage, $needDetection = true) {
}
}
*/
*/
echo"after reset - current frame on master port =".elphel_get_frame($GLOBALS['master_port'])."\n";
log_msg("after reset - current frame on master port =".elphel_get_frame($GLOBALS['master_port']));
// $page=setParsFromPage($initPage,0xffffffff,true); /// all parameters, init mode - treat all parameters as new, even when they are the same as current (0)
// $page=setParsFromPage($initPage,0xffffffff,true); /// all parameters, init mode - treat all parameters as new, even when they are the same as current (0)