|
@@ -467,12 +467,18 @@
|
467
|
467
|
for(var j = 0; j < device.channelCount(); j++) {
|
468
|
468
|
channels.push(device.getChannel(j));
|
469
|
469
|
columnNames.push(device.channelColumnName(j));
|
470
|
|
- channelType.push("T");
|
|
470
|
+ channelType.push(device.channelType(j));
|
471
|
471
|
if(device.isChannelHidden(j)) {
|
472
|
472
|
channelVisibility.push(false);
|
473
|
473
|
} else {
|
474
|
474
|
channelVisibility.push(true);
|
475
|
475
|
var indicator = new TemperatureDisplay;
|
|
476
|
+ if(device.channelType(j) == "C")
|
|
477
|
+ {
|
|
478
|
+ indicator.setDisplayUnits(Units.Unitless);
|
|
479
|
+ indicator.digitCount = 5;
|
|
480
|
+ indicator.setDecimalPlaces(2);
|
|
481
|
+ }
|
476
|
482
|
temperatureDisplays.push(indicator);
|
477
|
483
|
var decorator = new WidgetDecorator(indicator, device.channelIndicatorText(j), 2);
|
478
|
484
|
device.getChannel(j).newData.connect(indicator.setValue);
|
|
@@ -606,6 +612,10 @@
|
606
|
612
|
calibrator.add_pair(Number(sourcevalues[k]),Number(destvalues[k]));
|
607
|
613
|
}
|
608
|
614
|
var indicator = new TemperatureDisplay;
|
|
615
|
+ if(channelType[j] == "C") {
|
|
616
|
+ indicator.setDisplayUnits(Units.Unitless);
|
|
617
|
+ indicator.setDecimalPlaces(2);
|
|
618
|
+ }
|
609
|
619
|
temperatureDisplays.push(indicator);
|
610
|
620
|
var decorator = new WidgetDecorator(indicator, configModel.data(driverIndex, 0), 2);
|
611
|
621
|
channels[j].newData.connect(calibrator.newMeasurement);
|