Closedown
This commit is contained in:
@@ -18,7 +18,7 @@ import java.util.logging.Level;
|
||||
*/
|
||||
public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
final String channelCtrl;
|
||||
final ChannelDoubleArray spectrum;
|
||||
final ChannelDoubleArray spectrum, spectrumX;
|
||||
|
||||
public Scienta(final String name, final String channelPrefix) {
|
||||
this(name, channelPrefix + ":cam1", channelPrefix + ":image1");
|
||||
@@ -35,6 +35,7 @@ public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
|
||||
spectrum = new ScientaSpectrum();
|
||||
getNumChannels().removeAllListeners();
|
||||
/*
|
||||
getNumChannels().addListener(new DeviceAdapter() {
|
||||
@Override
|
||||
public void onValueChanged(Device device, Object value, Object former) {
|
||||
@@ -47,10 +48,22 @@ public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
}
|
||||
}
|
||||
});
|
||||
*/
|
||||
addChild(spectrum);
|
||||
|
||||
spectrumX = new ChannelDoubleArray("Spectrum X", "X03DA-SCIENTA:cam1:CHANNEL_SCALE_RBV");
|
||||
addChild(spectrumX);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void doInitialize() {
|
||||
super.doInitialize();
|
||||
spectrum.setSize(KEEP_TO_VALID);
|
||||
spectrumX.setSize(KEEP_TO_VALID);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void doSetSimulated() {
|
||||
super.doSetSimulated();
|
||||
@@ -88,11 +101,13 @@ public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
setAccessType(AccessType.Read);
|
||||
}
|
||||
|
||||
/*
|
||||
@Override
|
||||
protected double[] doRead() throws IOException, InterruptedException {
|
||||
getNumChannels().getValue();
|
||||
return super.doRead();
|
||||
}
|
||||
*/
|
||||
|
||||
@Override
|
||||
public ArrayCalibration getCalibration() {
|
||||
@@ -112,6 +127,7 @@ public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
|
||||
@Override
|
||||
public double[] getSpectrumX() throws IOException, InterruptedException {
|
||||
/*
|
||||
List<Double> range = getChannelRange();
|
||||
Double begin = range.get(0);
|
||||
Double end = range.get(1);
|
||||
@@ -126,6 +142,8 @@ public class Scienta extends ch.psi.pshell.epics.Scienta {
|
||||
x[i] = begin + step * i;
|
||||
}
|
||||
return x;
|
||||
*/
|
||||
return spectrumX.read();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user