this hurts

Dependencies:   FFT

Files at this revision

API Documentation at this revision

Comitter:
shyamgatech
Date:
Thu Dec 03 18:15:35 2020 +0000
Parent:
6:d311a95f1e9b
Parent:
4:7974ef1b1e07
Commit message:
addded gui mbed code;

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Thu Dec 03 15:50:45 2020 +0000
+++ b/main.cpp	Thu Dec 03 18:15:35 2020 +0000
@@ -128,7 +128,7 @@
             
         freq = sample[a];
         
-        pc.printf("%d\n",freq);
+        pc.printf("%f\n",freq);
         
 >>>>>>> merge rev
         // determine state based on the FFT output range
@@ -162,7 +162,7 @@
                     }
                 }
                 matrix.writeDisplay();
-                wait(1);
+                wait(.2);
                 break;
 
             case(2): // CASE HIGH
@@ -175,8 +175,13 @@
                     }
                 }
                 matrix.writeDisplay();
+<<<<<<< working copy
                 wait(1);
 
+=======
+                wait(.2);
+        
+>>>>>>> merge rev
             case(3): // CASE MEDIUM
                 matrix.clear();
                 for (int i = 0; i < 8; i++) {
@@ -187,7 +192,7 @@
                     }
                 }
                 matrix.writeDisplay();
-                wait(1);
+                wait(.2);
                 break;
 
             case(4): // CASE LOW
@@ -200,7 +205,7 @@
                     }
                 }
                 matrix.writeDisplay();
-                wait(1);
+                wait(.2);
                 break;
 
             case(5): // CASE OFF
@@ -213,7 +218,7 @@
                     }
                 }
                 matrix.writeDisplay();
-                wait(1);
+                wait(.2);
                 break;
 
             default:
@@ -272,7 +277,7 @@
            if(buffer_index == BUFFER_SIZE)
            {
                //fast fourier tranform function here
-               vRealFFT(buffer, 64);
+               vRealFFT(buffer, 4);
                display_fft(buffer);
                buffer_index = 0;
                memset(buffer,0,sizeof(buffer));