change
This commit is contained in:
@@ -100,8 +100,8 @@ static err_t modbus_incoming_data(void* arg, struct tcp_pcb* pcb, struct pbuf* p
|
|||||||
// Processing the image index
|
// Processing the image index
|
||||||
size_t number_of_files = llfs_file_count(); // How many files that there are
|
size_t number_of_files = llfs_file_count(); // How many files that there are
|
||||||
|
|
||||||
|
if (number_of_files > 0) {
|
||||||
llfs_file_t file_list[number_of_files]; // Reserving memory for the list
|
llfs_file_t file_list[number_of_files]; // Reserving memory for the list
|
||||||
|
|
||||||
number_of_files = llfs_file_list(file_list, number_of_files, NULL); // Freed memory filled with the list
|
number_of_files = llfs_file_list(file_list, number_of_files, NULL); // Freed memory filled with the list
|
||||||
|
|
||||||
if (number_of_files < nr_img) {
|
if (number_of_files < nr_img) {
|
||||||
@@ -132,6 +132,7 @@ static err_t modbus_incoming_data(void* arg, struct tcp_pcb* pcb, struct pbuf* p
|
|||||||
lcd_draw_img_from_fs(file_list[nr_img - 1].name, 0, 75); // BMP on screen
|
lcd_draw_img_from_fs(file_list[nr_img - 1].name, 0, 75); // BMP on screen
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// LOG_INFO(TAG, "not in writing multiple register mode!!!\n");
|
// LOG_INFO(TAG, "not in writing multiple register mode!!!\n");
|
||||||
|
|||||||
Reference in New Issue
Block a user