Skip to content
Snippets Groups Projects
Commit 7aec85fd authored by Fanis Baikas's avatar Fanis Baikas
Browse files

Changes in nanosoc program name and demo state flags

parent d0ba0c47
No related branches found
No related tags found
No related merge requests found
Pipeline #11622 passed
...@@ -485,10 +485,12 @@ void DEMO_ROUTINE(){ ...@@ -485,10 +485,12 @@ void DEMO_ROUTINE(){
sprintf(text, "%s %8lld us", "Total time ", total_time_mean); sprintf(text, "%s %8lld us", "Total time ", total_time_mean);
printf("%s\n", text); printf("%s\n", text);
graphics.text(text, console_text_location, 600); graphics.text(text, console_text_location, 600);
DEMO_done = false;
} }
} }
if(BUTTON_X_pressed){ if(BUTTON_X_pressed){
if (DEMO_done) { if (!DEMO_RUN) {
// Clear text area // Clear text area
graphics.set_pen(BG); graphics.set_pen(BG);
Rect blank(0, 18, 240, 284); Rect blank(0, 18, 240, 284);
...@@ -505,7 +507,7 @@ void DEMO_ROUTINE(){ ...@@ -505,7 +507,7 @@ void DEMO_ROUTINE(){
xtext = 0; xtext = 0;
ytext = 0; ytext = 0;
DEMO_done = false; // DEMO_done = false;
} }
DEMO_RUN=true; DEMO_RUN=true;
...@@ -814,9 +816,9 @@ int main() { ...@@ -814,9 +816,9 @@ int main() {
// Download program to nanosoc // Download program to nanosoc
f_chdir("./programs"); f_chdir("./programs");
fr = f_open(&fil, "fast_knn.hex", FA_READ); fr = f_open(&fil, "fast_knn_demo.hex", FA_READ);
if (FR_OK != fr && FR_EXIST != fr){ if (FR_OK != fr && FR_EXIST != fr){
printf("f_open(fast_knn.hex) error: %s (%d)\n", FRESULT_str(fr), fr); printf("f_open(fast_knn_demo.hex) error: %s (%d)\n", FRESULT_str(fr), fr);
printf("Can't open demo program. Is SD card inserted?\n"); printf("Can't open demo program. Is SD card inserted?\n");
return 1; return 1;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment