Non-variable (TESTEDandWORKING)

Dependencies:   mbed-rtos mbed

Fork of ELEC347_Coursework by CMST

Revision:
6:a2737b51424c
Parent:
5:e49e5515488d
Child:
7:6cb27cce4c50
diff -r e49e5515488d -r a2737b51424c main.cpp
--- a/main.cpp	Tue Nov 28 09:59:04 2017 +0000
+++ b/main.cpp	Tue Nov 28 13:06:24 2017 +0000
@@ -1,6 +1,8 @@
 #include "mbed.h"
 #include "rtos.h"
 #include "Filter.hpp"
+
+
 unsigned short ADC_DATA;
 
 //Init  values for difference equation
@@ -11,11 +13,10 @@
 AnalogOut Aout(PA_4);                   //Analog Output (Signal Input 0 to +3 Volts)
 
 Ticker sample_timer;
-Thread T1;
-Thread T2;
+
 
 float input = 0.0;
-FILTER BP_filter(48000,10,16,1600);  //Create object of type Filter(Fs,Fo,Boost,Q)
+FILTER BP_filter(48000,10000,16,2);  //Create object of type Filter(Fs,Fo,Boost,Q)
 
 
 void sampler(void);
@@ -23,20 +24,19 @@
 
 int main()
 {
-    
     BP_filter.Define_Filter();
-    float sample_rate = (1.0/35000) ;
-    sample_timer.attach(&sampler,sample_rate);;
+    BP_filter.Print_Filter();
+    float sample_rate = (1.0/35000);
+    //sample_timer.attach(&sampler,sample_rate);
 
     while(1) {
-//EMPTY
     }
 }
 
 
 void sampler(void)
 {
-
+    printf("H");
     SampLED = 1;                        //LED Indicates start of sampling
 
     input = Ain;