Compare commits
8 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d769a50459 | |||
| dac276c9de | |||
| 65c00031e3 | |||
| 0ff3dd556f | |||
| b3510b1990 | |||
| 632762ce14 | |||
| e4e89a414a | |||
| 921166cdc7 |
@@ -368,7 +368,7 @@ export default {
|
||||
this.updateChartSamplingChart({ chartID: this.chartDetailData.chartID, seriesIndex: _gridNumber, method: 'lttb' })
|
||||
}
|
||||
|
||||
if (metaInfo.device.library_name === 'EliteEIS' && metaInfo.parameter_set.MODE === 0) {
|
||||
if (metaInfo.device.library_name.includes('EIS') && metaInfo.parameter_set.MODE === 0) {
|
||||
this.chartDetailData.series[this.chartDetailData.series.length - 1].showSymbol = true
|
||||
this.chartDetailData.series[this.chartDetailData.series.length - 1].showAllSymbol = true
|
||||
this.chartDetailData.series[this.chartDetailData.series.length - 1].symbolSize = 6
|
||||
@@ -486,9 +486,9 @@ export default {
|
||||
if (this.axisXDataType.description === 'Time') {
|
||||
xType = 'Time'
|
||||
} else {
|
||||
if (libName === 'EliteZM15') {
|
||||
if (libName === 'EliteZM15' || libName.includes('Elite_EDC')) {
|
||||
xType = 'Elite'
|
||||
} else if (libName === 'EliteEIS') {
|
||||
} else if (libName.includes('EIS')) {
|
||||
xType = 'EliteEIS'
|
||||
}
|
||||
xValue = this.axisXDataType.id + 1
|
||||
@@ -500,7 +500,7 @@ export default {
|
||||
deviceNameX: xType,
|
||||
deviceIDX: this.metaList[gridIndex].name,
|
||||
channelX: xValue,
|
||||
deviceNameY: libName === 'EliteEIS' ? 'EliteEIS' : 'Elite',
|
||||
deviceNameY: libName.includes('EIS') ? 'EliteEIS' : 'Elite',
|
||||
deviceIDY: '',
|
||||
channelY: this.axisYDataType.id + 1,
|
||||
})
|
||||
|
||||
@@ -70,7 +70,7 @@ export default {
|
||||
},
|
||||
performABS () {
|
||||
this.absToggleStatus[this.axis] = !this.absToggleStatus[this.axis]
|
||||
if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
this.calculateHelper(this.metaIndex) // [TODO] elite tmp use metaIndex for grid index
|
||||
}
|
||||
this.clickTime++
|
||||
@@ -93,7 +93,7 @@ export default {
|
||||
data: seriesData,
|
||||
})
|
||||
} else {
|
||||
if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
this.$emit('changeAxis', this.metaIndex) // [TODO] elite tmp use metaIndex for grid index
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,7 +84,7 @@ export default {
|
||||
} else if (this.axis === 'y') {
|
||||
this.axisYDataType = this.channelOptions[1]
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC')) {
|
||||
// use state meta to decide which default unit need to be used (like check I-V mode...)
|
||||
const setting = this.GLOBAL.getDefaultChartTypeByMode(this.metaList[this.metaIndex].parameter_set.MODE, this.deviceName)
|
||||
const xType = setting[0]
|
||||
@@ -130,7 +130,7 @@ export default {
|
||||
}
|
||||
this.channelFormat = this.axisYDataType
|
||||
}
|
||||
} else if (this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName.includes('EIS')) {
|
||||
const setting = this.GLOBAL.getDefaultChartTypeByMode(this.metaList[this.metaIndex].parameter_set.MODE, this.deviceName)
|
||||
const xType = setting[0]
|
||||
const xValue = setting[1]
|
||||
@@ -141,7 +141,7 @@ export default {
|
||||
if (this.axis === 'x') {
|
||||
settingType = xType
|
||||
settingValue = xValue
|
||||
if (settingType === 'EliteEIS') {
|
||||
if (settingType.includes('EIS')) {
|
||||
this.axisXDataType = this.eisChannelOptions.find(element => element.id === parseInt(settingValue) - 1)
|
||||
} else if (settingType === 'Elite') {
|
||||
// 1: I, 2: V, 3: R
|
||||
@@ -159,7 +159,7 @@ export default {
|
||||
} else if (this.axis === 'y') {
|
||||
settingType = yType
|
||||
settingValue = yValue
|
||||
if (settingType === 'EliteEIS') {
|
||||
if (settingType.includes('EIS')) {
|
||||
this.axisYDataType = this.eisChannelOptions.find(element => element.id === parseInt(settingValue) - 1)
|
||||
} else if (settingType === 'Elite') {
|
||||
// 1: I, 2: V, 3: R
|
||||
@@ -184,7 +184,7 @@ export default {
|
||||
if (this.deviceName.startsWith('Neulive')) {
|
||||
// for elite now, cuz neulive now only have v-t graph, for future neulive replay need to adjust'
|
||||
// console.log('(Last updated: 2021/06/19)')
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
if (this.axis === 'x') {
|
||||
this.axisXDataType = this.channelFormat
|
||||
} else if (this.axis === 'y') {
|
||||
|
||||
@@ -87,7 +87,7 @@ export default {
|
||||
this.calculateScaleHelper(gridIndex, ch)
|
||||
}
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
this.calculateScaleHelper(this.metaIndex, -1) // [TODO] elite tmp use metaIndex for grid index
|
||||
}
|
||||
},
|
||||
@@ -139,7 +139,7 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
this.$emit('changeAxis', this.metaIndex)
|
||||
this.$emit('clearCycle')
|
||||
}
|
||||
|
||||
@@ -65,9 +65,9 @@ export default {
|
||||
return item.unit === 'uV'
|
||||
})
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC')) {
|
||||
return this.valueFormatOptions[this.dataType][0]
|
||||
} else if (this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName.includes('EIS')) {
|
||||
return this.eisValueFormatOptions[this.dataType][0]
|
||||
}
|
||||
},
|
||||
@@ -80,7 +80,7 @@ export default {
|
||||
} else if (this.axis === 'y') {
|
||||
this.dataType = 'voltage'
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC')) {
|
||||
// use state meta to decide which default unit need to be used (like check I-V mode...)
|
||||
const setting = this.GLOBAL.getDefaultChartTypeByMode(this.metaList[this.metaIndex].parameter_set.MODE, this.deviceName)
|
||||
const xType = setting[0]
|
||||
@@ -111,7 +111,7 @@ export default {
|
||||
} else if (settingType === 'Time') {
|
||||
this.dataType = 'time'
|
||||
}
|
||||
} else if (this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName.includes('EIS')) {
|
||||
const setting = this.GLOBAL.getDefaultChartTypeByMode(this.metaList[this.metaIndex].parameter_set.MODE, this.deviceName)
|
||||
const xType = setting[0]
|
||||
const xValue = setting[1]
|
||||
@@ -127,7 +127,7 @@ export default {
|
||||
settingValue = yValue
|
||||
}
|
||||
|
||||
if (settingType === 'EliteEIS') {
|
||||
if (settingType.includes('EIS')) {
|
||||
if (settingValue === 3) {
|
||||
this.dataType = 'frequency'
|
||||
} else if (settingValue === 5 || settingValue === 6 || settingValue === 7) {
|
||||
@@ -179,7 +179,7 @@ export default {
|
||||
channel: parseInt(key),
|
||||
})
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
this.updateAxisLabelChart({
|
||||
chartID: chartID,
|
||||
axis: this.axis,
|
||||
@@ -229,9 +229,9 @@ export default {
|
||||
this.dataType = 'default'
|
||||
}
|
||||
}
|
||||
if (this.deviceName === 'EliteZM15') {
|
||||
if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC')) {
|
||||
this.valueFormat = this.valueFormatOptions[this.dataType][0]
|
||||
} else if (this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName.includes('EIS')) {
|
||||
this.valueFormat = this.eisValueFormatOptions[this.dataType][0]
|
||||
}
|
||||
this.changeUnit()
|
||||
|
||||
@@ -378,7 +378,7 @@ export default {
|
||||
this.content += ' Frequency: ' + String(1000 / period) + ' Hz' + '<br/>' // 1000 is cuz 1s = 1000ms
|
||||
this.content += ' Period: ' + String(period) + ' ms' + '<br/>'
|
||||
}
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName === 'EliteEIS') {
|
||||
} else if (this.deviceName === 'EliteZM15' || this.deviceName.includes('Elite_EDC') || this.deviceName.includes('EIS')) {
|
||||
const mode = this.mode = params.MODE
|
||||
const config = paramTable.getConfig(this.deviceName)
|
||||
const modeConfig = paramTable.getModeConfig(this.deviceName, mode)
|
||||
|
||||
@@ -183,7 +183,7 @@ export default {
|
||||
this.channelSelectDisableX = false
|
||||
} else if (deviceInfo.library_name.includes('Elite')) {
|
||||
let channelSet
|
||||
if (deviceInfo.library_name === 'EliteEIS' && deviceInfo.configuration.MODE === 0) {
|
||||
if (deviceInfo.library_name.includes('EIS') && deviceInfo.configuration.MODE === 0) {
|
||||
channelSet = ['Zimag_Raw', 'Zreal_Raw', 'Frequency', 'Cycle', 'Zimag', 'Zreal', 'Impedance', 'Phase', 'Current', 'Level gain']
|
||||
} else {
|
||||
channelSet = deviceInfo.configuration.CHANNEL_LABEL
|
||||
@@ -251,7 +251,7 @@ export default {
|
||||
this.channelSelectDisableY = false
|
||||
} else if (deviceInfo.library_name.indexOf('Elite') >= 0) {
|
||||
let channelSet
|
||||
if (deviceInfo.library_name === 'EliteEIS' && deviceInfo.configuration.MODE === 0) {
|
||||
if (deviceInfo.library_name.includes('EIS') && deviceInfo.configuration.MODE === 0) {
|
||||
channelSet = ['Zimag_Raw', 'Zreal_Raw', 'Frequency', 'Cycle', 'Zimag', 'Zreal', 'Impedance', 'Phase', 'Current', 'Level gain']
|
||||
} else {
|
||||
channelSet = deviceInfo.configuration.CHANNEL_LABEL
|
||||
@@ -310,7 +310,7 @@ export default {
|
||||
if (this.deviceSelectX.name.indexOf('Neulive') >= 0) {
|
||||
deviceNameX = 'Neulive'
|
||||
} else if (this.deviceSelectX.name.indexOf('Elite') >= 0) {
|
||||
if (deviceXInfo.library_name === 'EliteEIS') {
|
||||
if (deviceXInfo.library_name.includes('EIS')) {
|
||||
deviceNameX = 'EliteEIS'
|
||||
} else {
|
||||
deviceNameX = 'Elite'
|
||||
@@ -321,7 +321,7 @@ export default {
|
||||
if (this.deviceSelectY.name.indexOf('Neulive') >= 0) {
|
||||
deviceNameY = 'Neulive'
|
||||
} else if (this.deviceSelectY.name.indexOf('Elite') >= 0) {
|
||||
if (deviceYInfo.library_name === 'EliteEIS') {
|
||||
if (deviceYInfo.library_name.includes('EIS')) {
|
||||
deviceNameY = 'EliteEIS'
|
||||
} else {
|
||||
deviceNameY = 'Elite'
|
||||
|
||||
@@ -150,7 +150,7 @@ export default {
|
||||
type: String,
|
||||
},
|
||||
serialNumber: {
|
||||
type: String,
|
||||
type: [String, Array],
|
||||
},
|
||||
device: {
|
||||
type: Object,
|
||||
|
||||
@@ -218,7 +218,7 @@ const EliteZM15 = {
|
||||
componentType: 'input-range',
|
||||
range: Object.freeze({ min: 1, max: 1000 }),
|
||||
defaultValue: 1000,
|
||||
defaultUnit: 'V',
|
||||
defaultUnit: 'mV',
|
||||
downloadUnit: 'mV',
|
||||
unit: {
|
||||
mV: 1,
|
||||
@@ -305,18 +305,18 @@ const EliteZM15 = {
|
||||
showName: 'Charge',
|
||||
componentType: 'input-button-toggle',
|
||||
options: [
|
||||
{ value: 0, label: 'Charge' },
|
||||
{ value: 1, label: 'Discharge' },
|
||||
{ value: 1, label: 'Charge' },
|
||||
{ value: 0, label: 'Discharge' },
|
||||
],
|
||||
range: ['Charge', 'Discharge'],
|
||||
defaultValue: 1,
|
||||
outputRawData: (val) => {
|
||||
const chargeArr = ['Charge', 'Discharge']
|
||||
const chargeArr = ['DisCharge', 'Charge']
|
||||
return chargeArr.indexOf(val.toString())
|
||||
},
|
||||
outputReadabilityData: (val) => {
|
||||
const chargeArr = ['Charge', 'Discharge']
|
||||
return chargeArr[(parseInt(val) + 1) % 2]
|
||||
const chargeArr = ['DisCharge', 'Charge']
|
||||
return chargeArr[parseInt(val)]
|
||||
},
|
||||
},
|
||||
Const_Current_value: {
|
||||
|
||||
@@ -4,16 +4,16 @@ import EliteEIS from './EliteEIS/index'
|
||||
// object saving library name mapping table
|
||||
const libraryNameMappingTable = {
|
||||
EliteZM15: EliteEDC,
|
||||
'EliteEDC1.4': null,
|
||||
'EliteEDC1.5': EliteEDC,
|
||||
'EliteEDC1.5re': EliteEDC,
|
||||
'EliteEDC1.5r2': EliteEDC,
|
||||
'BAT1.0': null,
|
||||
'EIS1.0': EliteEIS,
|
||||
'EIS1.1': EliteEIS,
|
||||
'EIS1.1_MINI': EliteEIS,
|
||||
'TRIG0.1': null,
|
||||
'MEGAFLY0.1': null,
|
||||
'Elite_EDC_1.4': null,
|
||||
'Elite_EDC_1.5': EliteEDC,
|
||||
'Elite_EDC_1.5re': EliteEDC,
|
||||
'Elite_EDC_1.5r2': EliteEDC,
|
||||
'Elite_BAT_1.0': EliteEDC,
|
||||
'Elite_EIS_1.0': EliteEIS,
|
||||
'Elite_EIS_1.1': EliteEIS,
|
||||
'Elite_EIS_MINI_1.0': EliteEIS,
|
||||
'Elite_TRIG_0.1': null,
|
||||
'Elite_MEGAFLY_0.1': null,
|
||||
}
|
||||
|
||||
// object saving serial number mapping table
|
||||
@@ -29,13 +29,15 @@ const serialNumberMappingTable = {
|
||||
},
|
||||
3: {
|
||||
1: {
|
||||
0: null, // BAT1.0
|
||||
0: EliteEDC, // BAT1.0
|
||||
},
|
||||
},
|
||||
4: {
|
||||
0: EliteEIS, // EIS1.0
|
||||
1: EliteEIS, // EIS1.1
|
||||
2: EliteEIS, // EIS1.1_MINI
|
||||
1: {
|
||||
0: EliteEIS, // EIS1.0
|
||||
1: EliteEIS, // EIS1.1
|
||||
2: EliteEIS, // EIS1.1mini
|
||||
},
|
||||
},
|
||||
5: {
|
||||
1: {
|
||||
|
||||
@@ -24,7 +24,7 @@ const hasCycleMode = (mode, lib) => {
|
||||
}
|
||||
|
||||
const getDefaultChartTypeByMode = (mode, lib) => {
|
||||
if (lib === 'EliteZM15') {
|
||||
if (lib === 'EliteZM15' || lib.includes('Elite_EDC')) {
|
||||
const settings = {}
|
||||
settings[0] = ['Elite', 2, 'Elite', 1]
|
||||
settings[1] = ['Elite', 2, 'Elite', 1]
|
||||
@@ -43,7 +43,7 @@ const getDefaultChartTypeByMode = (mode, lib) => {
|
||||
settings[15] = ['Elite', 2, 'Elite', 1]
|
||||
settings[16] = ['Time', 2, 'Elite', 2]
|
||||
return settings[mode]
|
||||
} else if (lib === 'EliteEIS') {
|
||||
} else if (lib.includes('EIS') || lib.includes('Elite_EIS')) {
|
||||
const settings = {}
|
||||
settings[0] = ['EliteEIS', 6, 'EliteEIS', 5]
|
||||
settings[1] = ['Elite', 2, 'Elite', 1]
|
||||
|
||||
@@ -279,7 +279,7 @@ const chartActs = {
|
||||
default:
|
||||
break
|
||||
}
|
||||
} else if (sourceList[0].name === 'EliteEIS') {
|
||||
} else if (sourceList[0].name.includes('EIS')) {
|
||||
switch (sourceList[0].channel) {
|
||||
case 3:
|
||||
state.chartData[chartID].xAxis[_xAxisIndex].axisLabel.formatter = function (val) {
|
||||
@@ -375,7 +375,7 @@ const chartActs = {
|
||||
default:
|
||||
break
|
||||
}
|
||||
} else if (sourceList[1].name === 'EliteEIS') {
|
||||
} else if (sourceList[1].name.includes('EIS')) {
|
||||
switch (sourceList[1].channel) {
|
||||
case 3:
|
||||
state.chartData[chartID].yAxis[_yAxisIndex].axisLabel.formatter = function (val) {
|
||||
|
||||
Reference in New Issue
Block a user