<?xml version="1.0"?>
<!--
###################################################
##Costas Loop
###################################################
 -->
<block>
  <name>Costas Loop</name>
  <key>digital_costas_loop_cc</key>
  <import>from gnuradio import digital</import>
  <make>digital.costas_loop_cc($w, $order, $use_snr)</make>
  <callback>set_loop_bandwidth($w)</callback>

  <param>
    <name>Loop Bandwidth</name>
    <key>w</key>
    <type>real</type>
  </param>

  <param>
    <name>Order</name>
    <key>order</key>
    <type>int</type>
  </param>

  <param>
    <name>Use SNR</name>
    <key>use_snr</key>
    <value>False</value>
    <type>enum</type>
    <hide>part</hide>
    <option>
      <name>Yes</name>
      <key>True</key>
    </option>
    <option>
      <name>No</name>
      <key>False</key>
    </option>
  </param>

  <sink>
    <name>in</name>
    <type>complex</type>
  </sink>

  <sink>
    <name>noise</name>
    <type>message</type>
    <optional>1</optional>
  </sink>

  <source>
    <name>out</name>
    <type>complex</type>
  </source>

  <!-- Optional Outputs -->
  <source>
    <name>frequency</name>
    <type>float</type>
    <optional>1</optional>
  </source>
  <source>
    <name>phase</name>
    <type>float</type>
    <optional>1</optional>
  </source>
  <source>
    <name>error</name>
    <type>float</type>
    <optional>1</optional>
  </source>
</block>
