         mic.removeEventListener(StatusEvent.STATUS, onMicStatus);
         mic.removeEventListener(SampleDataEvent.SAMPLE_DATA, onMicSampleData);
       }
+      this.currentState = 'stopped';
+      this.callAPI(EVENT_AUDIO_TRANSMIT_STOPPED);
       conn.close();
     }
 

  import flash.utils.ByteArray;

  public class AxisTransmit implements IAudioClient {
    private static const EVENT_AUDIO_TRANSMIT_STARTED:String = "audioTransmitStarted";
    private static const EVENT_AUDIO_TRANSMIT_STOPPED:String = "audioTransmitStopped";

    private var urlParsed:Object = {};
    private var conn:Socket = new Socket();

    }

    public function onClosed(event:Event):void {
      if ('playing' === this.currentState) {
        this.currentState = 'stopped';
        this.callAPI(EVENT_AUDIO_TRANSMIT_STOPPED);
      }
    }
