Coursework

Revision:
34:dfe7f5799582
Parent:
33:3717bc4e2fa8
Child:
35:36c7605dda06
diff -r 3717bc4e2fa8 -r dfe7f5799582 main.cpp
--- a/main.cpp	Sat Jan 29 15:05:25 2022 +0000
+++ b/main.cpp	Sat Jan 29 15:17:34 2022 +0000
@@ -346,17 +346,20 @@
      
      printf("hello Scan: %i The value of : %i \n",i, Scan1[i]);
      if (Scan1[i]>95){
-     printf("no wall");}
+         Decide[i]= '+';
+     printf("no wall%c/n",Decide[i]);}
      else if (Scan1[i]<85){
-         printf("OBJECT ABOUT");}
+         Decide[i]= '-';
+         printf("OBJECT ABOUT%c/n",Decide[i]);}
          else if (Scan1[i]>85<95){
-             printf("No Object");}
+             Decide[i]= '=';
+             printf("No Object %c/n",Decide[i]);}
              }
      
 /**  IF Statement to decide on shape to draw
 *.. This section of code compares the each array element with the one proceding it and makes a logical decision if higher lower or equal.
 */
-
+/*
           if (Scan1[0] > Scan1[1])
            {
             printf("+");
@@ -724,7 +727,7 @@
             printf("-");
             Decide5[3]='-';
             printf( "chosen3 %c\n",Decide5[3]);
-            }
+            } */
             
      lcd.refresh();
      wait_ms(50);