fromNative method

  1. @override
BrainBit2AmplifierParam fromNative(
  1. BrainBit2AmplifierParamNative val
)
override

Implementation

@override
BrainBit2AmplifierParam fromNative(BrainBit2AmplifierParamNative val) {
  return BrainBit2AmplifierParam(
      current: val.current,
      chGain: List.generate(val.chGain.length,
          (index) => SensorGain.values[val.chGain[index] ?? 0]),
      chResistUse: List.generate(
          val.chResistUse.length, (index) => val.chResistUse[index] ?? false),
      chSignalMode: List.generate(
          val.chSignalMode.length,
          (index) =>
              BrainBit2ChannelMode.values[val.chSignalMode[index] ?? 0]));
}