bms_cell.py 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #!/usr/bin/env python
  2. # -*- encoding: utf-8 -*-
  3. from ui.cell import Cell
  4. from ui.own.frame_theme import MyFrame
  5. from utils.globalvar import SD
  6. from utils.qt import Signal
  7. class Win_Cell(Cell, MyFrame):
  8. cell_vol_signal = Signal(int)
  9. cell_temp_signal = Signal(int)
  10. jz_temp_signal = Signal(int)
  11. bcu_temp_signal = Signal(int)
  12. mos_temp_signal = Signal(int)
  13. def __init__(self, parent=None):
  14. super(Win_Cell, self).__init__(parent)
  15. self.setupUi(self)
  16. self.btn_cell_vol.clicked.connect(self._cell_vol)
  17. self.btn_cell_temp.clicked.connect(self._cell_temp)
  18. self.btn_jz_temp.clicked.connect(self._jz_temp)
  19. self.btn_bcu_temp.clicked.connect(self._bcu_temp)
  20. def _cell_vol(self):
  21. self.cell_vol_signal.emit(0)
  22. def _cell_temp(self):
  23. self.cell_temp_signal.emit(1)
  24. def _jz_temp(self):
  25. self.jz_temp_signal.emit(2)
  26. def _bcu_temp(self):
  27. self.bcu_temp_signal.emit(3)
  28. def _mos_temp(self):
  29. self.mos_temp_signal.emit(4)