Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.

Commit a9b8fbc

Browse files
committed
Removing not needed printfs
1 parent 8039a19 commit a9b8fbc

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

esp32/ftp/updater.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -156,8 +156,6 @@ bool update_to_factory_partition(void) {
156156
uint32_t bytes_read = 0;
157157

158158
while(updater_data.size != bytes_read){
159-
//printf("update_to_factory_partition 4\n");
160-
161159
updater_spi_flash_read(IMG_UPDATE1_OFFSET_OLD + bytes_read, buf, SPI_FLASH_SEC_SIZE, false);
162160
bytes_read += SPI_FLASH_SEC_SIZE;
163161
if(false == updater_write(buf, SPI_FLASH_SEC_SIZE)){
@@ -185,7 +183,6 @@ bool updater_start (void) {
185183
uint32_t boot_info_offset_local;
186184
if(true != updater_read_boot_info(&boot_info_local, &boot_info_offset_local)) {
187185
ESP_LOGE(TAG, "Reading boot info (otadata partition) failed!\n");
188-
printf("Reading boot info (otadata partition) failed!\n");
189186
return false;
190187
}
191188

@@ -196,15 +193,13 @@ bool updater_start (void) {
196193
ret = spi_flash_erase_sector(OTA_DATA_ADDRESS / SPI_FLASH_SEC_SIZE);
197194
if (ESP_OK != ret) {
198195
ESP_LOGE(TAG, "Erasing new sector of boot info failed, error code: %d!\n", ret);
199-
printf("Erasing new sector of boot info failed, error code: %d!\n", ret);
200196
// TODO: try again ???
201197
return false;
202198
}
203199

204200
// Updating the NEW otadata partition with the OLD information
205201
if (true != updater_write_boot_info(&boot_info_local, OTA_DATA_ADDRESS)) {
206202
ESP_LOGE(TAG, "Writing new sector of boot info failed!\n");
207-
printf("Writing new sector of boot info failed!\n");
208203
//TODO: try again ???
209204
return false;
210205
}
@@ -213,22 +208,19 @@ bool updater_start (void) {
213208
ret = spi_flash_erase_sector(ESP_PARTITION_TABLE_ADDR / SPI_FLASH_SEC_SIZE);
214209
if (ESP_OK != ret) {
215210
ESP_LOGE(TAG, "Erasing partition table partition failed, error code: %d!\n", ret);
216-
printf("Erasing partition table partition failed, error code: %d!\n", ret);
217211
//TODO: write back old one ??
218212
return false;
219213
}
220214
// Writing the new partition table
221215
ret = spi_flash_write(ESP_PARTITION_TABLE_ADDR, (void *)buf, vstr.len);
222216
if (ESP_OK != ret) {
223217
ESP_LOGE(TAG, "Writing new partition table failed, error code: %d\n", ret);
224-
printf("Writing new partition table failed, error code: %d\n", ret);
225218
//TODO: try again ???
226219
return false;
227220
}
228221
}
229222
else {
230223
ESP_LOGE(TAG, "Reading file (/flash/partitions.bin) containing the new partition table failed!\n");
231-
printf("Reading file (/flash/partitions.bin) containing the new partition table failed!\n");
232224
return false;
233225
}
234226

0 commit comments

Comments
 (0)