summaryrefslogtreecommitdiff
path: root/spectro/instappsup.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2016-10-02 19:25:17 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2016-10-02 19:25:17 +0200
commitc2ca7be5a751879159f3cb591a64bb9568b79762 (patch)
tree04e38d4f4a2aad4d789bda0a65b7abb80a3439a2 /spectro/instappsup.c
parent45c152c326d87478fbf41714b4b8e2f7b57a282b (diff)
parent3db384424bd7398ffbb7a355cab8f15f3add009f (diff)
Updated version 1.9.1+repack from 'upstream/1.9.1+repack'
with Debian dir 98a996367aa69ae41accf9c6d369f600bc94de80
Diffstat (limited to 'spectro/instappsup.c')
-rw-r--r--spectro/instappsup.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/spectro/instappsup.c b/spectro/instappsup.c
index d2ce7ff..fc550b4 100644
--- a/spectro/instappsup.c
+++ b/spectro/instappsup.c
@@ -1,5 +1,5 @@
- /* Instrument command line application support functions */
+/* Instrument command line application support functions */
/*
* Argyll Color Correction System
@@ -72,7 +72,6 @@ static inst_code def_uicallback(void *cntx, inst_ui_purp purp) {
return inst_user_trig;
}
- /* Change in measurement configuration */
} else if (purp == inst_measuring) {
return inst_ok;
}
@@ -173,8 +172,9 @@ inst_code inst_handle_calibrate(
int doimmediately /* If nz, don't wait for user, calibrate immediatley */
) {
inst_code rv = inst_ok, ev;
- int usermes = 0; /* User was given a message */
- char id[200]; /* Condition identifier */
+ int usermes = 0; /* User was given a message */
+ inst_calc_id_type idtype; /* Condition identifier type */
+ char id[200]; /* Condition identifier */
int ch;
a1logd(p->log,1,"inst_handle_calibrate called\n");
@@ -183,13 +183,15 @@ inst_code inst_handle_calibrate(
for (;;) {
a1logd(p->log,1,"About to call calibrate at top of loop\n");
- ev = p->calibrate(p, &calt, &calc, id);
+ ev = p->calibrate(p, &calt, &calc, &idtype, id);
a1logd(p->log,1,"Calibrate returned calt 0x%x, calc 0x%x, ev 0x%x\n",calt,calc,ev);
/* We're done */
if ((ev & inst_mask) == inst_ok) {
- if ((calc & inst_calc_cond_mask) == inst_calc_message)
+ if ((calc & inst_calc_cond_mask) == inst_calc_message) {
+ /* (Or could create our own message text based on value of idtype) */
printf("%s\n",id);
+ }
if (usermes)
printf("Calibration complete\n");
fflush(stdout);
@@ -249,7 +251,7 @@ inst_code inst_handle_calibrate(
break;
case inst_calc_man_ref_white:
- printf("Place the instrument on its reflective white reference %s,\n",id);
+ printf("Place the instrument on its reflective white reference S/N %s,\n",id);
printf(" and then hit any key to continue,\n");
break;
@@ -448,12 +450,12 @@ inst2_capability inst_show_disptype_options(FILE *fp, char *oline, icompaths *ic
olen = strlen(oline); /* lenth of option part of line */
- for (i = 0; icmps != NULL && i < icmps->npaths; i++) {
+ for (i = 0; icmps != NULL && i < icmps->ndpaths[dtix_inst]; i++) {
inst *it;
inst2_capability cap;
int k;
- if ((it = new_inst(icmps->paths[i], 1, g_log, NULL, NULL)) == NULL) {
+ if ((it = new_inst(icmps->dpaths[dtix_inst][i], 1, g_log, NULL, NULL)) == NULL) {
notall = 1;
continue;
}