112 @param chip selected chip type |
112 @param chip selected chip type |
113 @type str |
113 @type str |
114 """ |
114 """ |
115 self.__updateOkButton() |
115 self.__updateOkButton() |
116 |
116 |
|
117 self.cpyCheckBox.setEnabled(chip == "ESP32-S2") |
|
118 # possible address override needed for CircuitPython |
|
119 |
117 @pyqtSlot(str) |
120 @pyqtSlot(str) |
118 def on_firmwarePicker_textChanged(self, firmware): |
121 def on_firmwarePicker_textChanged(self, firmware): |
119 """ |
122 """ |
120 Private slot handling a change of the firmware path. |
123 Private slot handling a change of the firmware path. |
121 |
124 |
122 @param firmware path to the firmware |
125 @param firmware path to the firmware |
123 @type str |
126 @type str |
124 """ |
127 """ |
125 self.__updateOkButton() |
128 self.__updateOkButton() |
|
129 |
|
130 self.cpyCheckBox.setChecked("circuitpython" in firmware) |
|
131 # possible address override needed for CircuitPython |
126 |
132 |
127 @pyqtSlot(str) |
133 @pyqtSlot(str) |
128 def on_addressEdit_textChanged(self, address): |
134 def on_addressEdit_textChanged(self, address): |
129 """ |
135 """ |
130 Private slot handling a change of the address. |
136 Private slot handling a change of the address. |
142 firmware file, the baud rate, the flash mode and the flash |
148 firmware file, the baud rate, the flash mode and the flash |
143 address |
149 address |
144 @rtype tuple of (str, str, str, str, str) |
150 @rtype tuple of (str, str, str, str, str) |
145 """ |
151 """ |
146 chip = self.espComboBox.currentData() |
152 chip = self.espComboBox.currentData() |
|
153 |
147 address = self.addressEdit.text() if self.__addon else self.FlashAddresses[chip] |
154 address = self.addressEdit.text() if self.__addon else self.FlashAddresses[chip] |
|
155 if not self.__addon and chip == "esp32s2" and self.cpyCheckBox.isChecked(): |
|
156 # override address |
|
157 address = "0x0000" |
148 |
158 |
149 return ( |
159 return ( |
150 chip, |
160 chip, |
151 self.firmwarePicker.text(), |
161 self.firmwarePicker.text(), |
152 self.baudRateComboBox.currentText().replace(".", ""), |
162 self.baudRateComboBox.currentText().replace(".", ""), |