Experimental implementation of the adaptive filter of "Interface" magazine in 2016-2017

Dependencies:   amakusa mbed-dsp mbed shimabara ukifune unzen_nucleo_f746

Fork of skeleton_unzen_nucleo_f746 by seiichi horie

ハードウェアおよびソフトウェアはskelton_unzen_nucleo_f746を基本にしています。

Revision:
20:699e209fd19a
Parent:
18:b9b1116f8768
--- a/signal_processing.cpp	Fri Feb 03 14:35:46 2017 +0000
+++ b/signal_processing.cpp	Fri Feb 03 14:41:40 2017 +0000
@@ -6,10 +6,6 @@
 {
         // place the signal processing initializing code here.
     this->volume_level = 0.0;   // sample initializaiton
-    this->note = new Monophonic(block_size);      // allocate VFO
-    note->set_Fs( SAMPLING_FREQUENCY );
-    note->set_vfo_frequency( 440 );
-    note->set_vfo_wave_form( triangle );
 }   // End of constructor()
     
     
@@ -23,52 +19,15 @@
            )
 {
         // place the signal processing coce here
-
-        // VFO
-    this->note->run( tx_left_buffer, block_size);
-    
-        // apply gain and copy to right ch.
     for ( int i= 0; i< block_size; i++ )
     {
-            tx_right_buffer[i]  = tx_left_buffer[i]  *= this->volume_level;
+            tx_left_buffer[i]  = rx_left_buffer[i]  * this->volume_level;
+            tx_right_buffer[i] = rx_right_buffer[i] * this->volume_level;
     }
 }   // End of run()
     
-
-    // Sampling Frequency
-void SignalProcessing::set_Fs( int Fs )
-{
-    this->enter_critical_section();     // forbidden interrrupt.
-    this->note->set_Fs( Fs );
-    this->leave_critical_section();     // now, ok to accept interrupt.
-}
-
-    // Oscillation Frequency
-void SignalProcessing::set_vfo_frequency( int freq )
-{
-    this->enter_critical_section();     // forbidden interrrupt.
-    this->note->set_vfo_frequency( freq );
-    this->leave_critical_section();     // now, ok to accept interrupt.
-}
-
-    // Duty Cycle of VFO
-void SignalProcessing::set_vfo_duty_cycle( float duty )
-{
-    this->enter_critical_section();     // forbidden interrrupt.
-    this->note->set_vfo_duty_cycle( duty );
-    this->leave_critical_section();     // now, ok to accept interrupt.
-}
-
-    // VFO wave form
-void SignalProcessing::set_vfo_wave_form( wave_form form )
-{
-    this->enter_critical_section();     // forbidden interrrupt.
-    this->note->set_vfo_wave_form( form );
-    this->leave_critical_section();     // now, ok to accept interrupt.
-}
-
            
-        // Set the volume level to the object.
+        // Sample method. Set the volume level to the object.
 void SignalProcessing::set_volume( float vol )
 {
     this->enter_critical_section();     // forbidden interrrupt.