Commit 558d5f18 authored by Andrey Filippov's avatar Andrey Filippov

Support for LWIR16 camera

parent 10412f81
...@@ -41,13 +41,35 @@ ...@@ -41,13 +41,35 @@
</table> </table>
</td></tr></table> </td></tr></table>
</div> </div>
<button type="button" class="collapsible">LWIR16 FFC controls</button>
<div id='lwir16_ffc_controls'>
<table><tr><td>
<table>
<tr><td><label for="gao_gain">GAO Gain</label></td><td><input type="checkbox" id="gao_gain" name="gao_gain" checked="checked"></td></tr>
<tr><td><label for="gao_sffc">GAO SFFC</label></td><td><input type="checkbox" id="gao_sffc" name="gao_sffc" checked="checked"></td></tr>
<tr><td><label for="gao_ffc">GAO FFC</label></td><td><input type="checkbox" id="gao_ffc" name="gao_ffc" checked="checked"></td></tr>
<tr><td><label for="gao_temp">GAO Temp</label></td><td><input type="checkbox" id="gao_temp" name="gao_temp" checked="checked"></td></tr>
<tr><td><label for="bpr">BPR</label></td><td><input type="checkbox" id="idbpr" name="bpr" checked="checked"></td></tr>
</table>
</td><td>
<table>
<tr><td><label for="scnr">SCNR</label></td><td><input type="checkbox" id="scnr" name="scnr" checked="checked"></td></tr>
<tr><td><label for="srnr">SRNR</label></td><td><input type="checkbox" id="srnr" name="srnr" checked="checked"></td></tr>
<tr><td><label for="spnr">SPNR</label></td><td><input type="checkbox" id="spnr" name="spnr" checked="checked"></td></tr>
<tr><td><label for="tf">TF</label></td><td><input type="checkbox" id="tf" name="tf" checked="checked" disabled="disabled"></td></tr>
<tr><td><label for="tf_delta_nf">TF DELTA NF</label></td><td><input type="text" id="tf_delta_nf" name="tf_delta_nf"size="5" value="?">s</td></tr>
</table>
</td></tr></table>
</div>
<button type="button" class="collapsible">LWIR16 Controls</button> <button type="button" class="collapsible">LWIR16 Controls</button>
<div id='lwir16_controls'> <div id='lwir16_controls'>
<table><tr><td> <table><tr><td>
<table> <table>
<tr><td><button id="idStartStop" name = "nStartStop" disabled="true">???</button></td> <tr><td><button id="idStartStop" name = "nStartStop" disabled="disabled">???</button></td>
<td><button id="idApply" name = "nApply" disabled = "true">???</button></td> <td><button id="idApply" name = "nApply" disabled = "disabled">???</button></td>
</tr> </tr>
<tr><td><label for="idpre_delay" >Inter-Delay</label></td><td><input type="text" id="idpre_delay" name="pre_delay" size="5" value="?">s</td></tr> <tr><td><label for="idpre_delay" >Inter-Delay</label></td><td><input type="text" id="idpre_delay" name="pre_delay" size="5" value="?">s</td></tr>
......
...@@ -22,6 +22,33 @@ var Port = function(options){ ...@@ -22,6 +22,33 @@ var Port = function(options){
} }
var BOSON_FFCS_REG= {
"gao_gain": 0,
"gao_sffc": 7,
"gao_ffc": 1,
"gao_temp": 2,
"bpr": 22,
"scnr": 36,
"srnr": 51,
"spnr": 46,
"tf": 42,
"tf_delta_nf":43
};
var boson_ffc= {
"gao_gain": 1,
"gao_sffc": 1,
"gao_ffc": 1,
"gao_temp": 1,
"bpr": 1,
"scnr": 1,
"srnr": 1,
"spnr": 1,
"tf": 1,
"tf_delta_nf":1
};
// camera class // camera class
var Camera = function(options){ var Camera = function(options){
...@@ -66,6 +93,7 @@ var refresh_previews_intvl; ...@@ -66,6 +93,7 @@ var refresh_previews_intvl;
var exp_ms = 50; var exp_ms = 50;
var quality = 97; var quality = 97;
$(function(){ $(function(){
init(); init();
}); });
...@@ -139,6 +167,7 @@ function init2(){ ...@@ -139,6 +167,7 @@ function init2(){
init_multicam_controls(); // 2022 init_multicam_controls(); // 2022
console.log("Got cameras"); console.log("Got cameras");
console.log(cams); console.log(cams);
initBosonFFC();
} }
...@@ -905,7 +934,7 @@ function updateAexpExpQuality(){ ...@@ -905,7 +934,7 @@ function updateAexpExpQuality(){
url = "parsedit.php?immediate&sensor_port=0&AUTOEXP_ON="+aexp_en+"&*AUTOEXP_ON=0xf&EXPOS="+exp_us+"&*EXPOS=0xf&QUALITY="+quality+"&*QUALITY=0xf"; url = "parsedit.php?immediate&sensor_port=0&AUTOEXP_ON="+aexp_en+"&*AUTOEXP_ON=0xf&EXPOS="+exp_us+"&*EXPOS=0xf&QUALITY="+quality+"&*QUALITY=0xf";
console.log("updateAexpExpQuality(): url="+url); console.log("updateAexpExpQuality(): url="+url);
multi_ajax(url,function(res){ multi_ajax(url,function(res){
console.log(this.ip+": aexp "+aexp_en); console.log(this.ip+": "+aexp_en);
}, 'mt9p006'); }, 'mt9p006');
} }
...@@ -927,7 +956,31 @@ function multi_ajax(url,callback,sensor_type=""){ ...@@ -927,7 +956,31 @@ function multi_ajax(url,callback,sensor_type=""){
} }
} }
function initBosonFFC(){
console.log("initBosonFFC()");
for (var ffc_name in boson_ffc) {
console.log(ffc_name+" = " + boson_ffc[ffc_name]);
$('#'+ffc_name).change(function() {
updateBosonFFC($(this).attr('id'));
});
console.log("initBosonFFC(), "+ffc_name);
}
}
function updateBosonFFC(ffc_name) {
// ffc_name=$(this).attr('id');
var in_type = $('#'+ffc_name).attr("type");
boson_ffc[ffc_name] = (in_type == 'text') ? ($('#'+ffc_name).val()): (($('#'+ffc_name).is(':checked'))?1:0);
console.log ("updateBosonFFC(): ffc_name="+ffc_name+": "+boson_ffc[ffc_name]+" val="+($('#'+ffc_name).val()+" type=" +($('#'+ffc_name).attr("type")) ));
var sensor_reg = "SENSOR_REGS"+BOSON_FFCS_REG[ffc_name];
url = "parsedit.php?immediate&sensor_port=0&"+sensor_reg+"="+boson_ffc[ffc_name]+"&*"+sensor_reg+"=0xf";
console.log("updateBosonFFC(): url="+url);
multi_ajax(url,function(res){
console.log(this.ip+": "+url);
}, 'boson640');
// TODO: add FFC command after changes? Need to spread not to overpower
}
......
...@@ -21,13 +21,23 @@ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diag ...@@ -21,13 +21,23 @@ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diag
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.js root@192.168.0.45:/www/pages/diagnostics/ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.js root@192.168.0.45:/www/pages/diagnostics/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.php root@192.168.0.42:/www/pages/ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-camogm/src/camogmgui/*.php root@192.168.0.42:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.php root@192.168.0.43:/www/pages/ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-camogm/src/camogmgui/*.php root@192.168.0.43:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.php root@192.168.0.44:/www/pages/ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-camogm/src/camogmgui/*.php root@192.168.0.44:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-web-393/src/diagnostics/diagnostics.php root@192.168.0.45:/www/pages/ scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-camogm/src/camogmgui/*.php root@192.168.0.45:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-autocampars/image/usr/bin/autocampars.php root@192.168.0.42:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-autocampars/image/usr/bin/autocampars.php root@192.168.0.43:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-autocampars/image/usr/bin/autocampars.php root@192.168.0.44:/www/pages/
scp /home/elphel/git/elphel393/rootfs-elphel/elphel-apps-autocampars/image/usr/bin/autocampars.php root@192.168.0.45:/www/pages/
#/home/elphel/git/elphel393/rootfs-elphel/elphel-apps-camogm/src/camogmgui/
ssh root@192.168.0.41 "sync" ssh root@192.168.0.41 "sync"
ssh root@192.168.0.42 "sync" ssh root@192.168.0.42 "sync"
ssh root@192.168.0.43 "sync" ssh root@192.168.0.43 "sync"
ssh root@192.168.0.44 "sync" ssh root@192.168.0.44 "sync"
ssh root@192.168.0.45 "sync" ssh root@192.168.0.45 "sync"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment