Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto Squelch for FM #43

Open
vigeruno opened this issue Oct 28, 2016 · 5 comments
Open

Auto Squelch for FM #43

vigeruno opened this issue Oct 28, 2016 · 5 comments

Comments

@vigeruno
Copy link

vigeruno commented Oct 28, 2016

Hello.
A simple automatic squelch for FM.
Useful for those who listen to FM glsdr without getting a headache.

diff --git a/trunk/src/DttSP/fm_demod.c b/trunk/src/DttSP/fm_demod.c
index 7e8eecb..d4197d2 100644
--- a/trunk/src/DttSP/fm_demod.c
+++ b/trunk/src/DttSP/fm_demod.c
@@ -86,13 +86,14 @@ pll (FMD fm, COMPLEX sig)
void
FMDemod (FMD fm)
{

  • int i;
  • int i,mute;
    for (i = 0; i < CXBsize (fm->ibuf); i++)
    {
    pll (fm, CXBdata (fm->ibuf, i));
    fm->afc = (REAL) (0.9999 * fm->afc + 0.0001 * fm->pll.freq.f);
  •   if (fm->afc < 0.000001){ mute = 0; } else { mute = 1; }
    CXBreal (fm->obuf, i) =
    
  •       CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) \* fm->cvt;
    
  •       CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) \* fm->cvt \* mute;
    
    }
    }

Regards.....

@alexlee188
Copy link
Owner

Are you sure that in:

  • if (fm->afc < 0.000001){ mute = 0; } else { mute = 1; } CXBreal
    (fm->obuf, i) =
  • CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) * fm->cvt;
  • CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) * fm->cvt * mute;

You only want CXBimag(fm->obuf,i) to be 0? What about CXBreal(fm->obuf,i) ?

Alex

On Fri, Oct 28, 2016 at 7:03 PM, vigeruno [email protected] wrote:

Hello.
A simple automatic squelch for FM.
Useful for those who listen to FM glsdr without getting a headache.

diff --git a/trunk/src/DttSP/fm_demod.c b/trunk/src/DttSP/fm_demod.c
index 7e8eecb..d4197d2 100644
--- a/trunk/src/DttSP/fm_demod.c
+++ b/trunk/src/DttSP/fm_demod.c
@@ -86,13 +86,14 @@ pll (FMD fm, COMPLEX sig)
void
FMDemod (FMD fm)
{

  • int i;
  • int i,mute; for (i = 0; i < CXBsize (fm->ibuf); i++) { pll (fm,
    CXBdata (fm->ibuf, i)); fm->afc = (REAL) (0.9999 * fm->afc + 0.0001 *
    fm->pll.freq.f);
  • if (fm->afc < 0.000001){ mute = 0; } else { mute = 1; } CXBreal
    (fm->obuf, i) =
  • CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) * fm->cvt;
  • CXBimag (fm->obuf, i) = (fm->pll.freq.f - fm->afc) * fm->cvt * mute;
    } }

Regards.....


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#43, or mute the thread
https://github.com/notifications/unsubscribe-auth/AAin9cAhZXZAiESj22832-9S9FNZoraTks5q4daZgaJpZM4KjUzG
.

@vigeruno
Copy link
Author

vigeruno commented Oct 28, 2016

Hello.
Yes.
schermata del 2016-10-28 14-47-38

https://github.com/vigeruno/ghpsdr3-vigeruno/blob/master/trunk/src/DttSP/fm_demod.c
You can listen live on ik6fjn ik6ioq server glsdr or qtradio
schermata del 2016-10-28 14-55-07

Regards.....

@alexlee188
Copy link
Owner

Ok I see :)

I have updated the repo with a slight change. Please test.

On Fri, 28 Oct, 2016 8:51 pm vigeruno, [email protected] wrote:

Hello.
[image: schermata del 2016-10-28 14-47-38]
https://cloud.githubusercontent.com/assets/22787199/19806900/d5562944-9d1d-11e6-863f-60729ce6ab7a.png

https://github.com/vigeruno/ghpsdr3-vigeruno/blob/master/trunk/src/DttSP/fm_demod.c


You are receiving this because you commented.

Reply to this email directly, view it on GitHub
#43 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAin9Z4a0Xh-STYExS6jDtpcJZ_3jBKkks5q4e_RgaJpZM4KjUzG
.

@vigeruno
Copy link
Author

Hello.

It works with this change:
if (fm->afc < 0.000001){ mute = 1; } else { mute = 0; } yes
if (fm->afc < 0.000001){ mute = 0; } else { mute = 1; } not working
autosquelch
pollice_alto

Regards.....

@alexlee188
Copy link
Owner

Ok. Corrected.

On Sun, 30 Oct, 2016 1:51 am vigeruno, [email protected] wrote:

Hello.

It works with this change:
if (fm->afc < 0.000001){ mute = 1; } else { mute = 0; } yes
if (fm->afc < 0.000001){ mute = 0; } else { mute = 1; } not working
[image: autosquelch]
https://cloud.githubusercontent.com/assets/22787199/19831682/6ec01502-9e10-11e6-8c73-53b6400e50f6.png
[image: pollice_alto]
https://cloud.githubusercontent.com/assets/22787199/19831706/ef2c3f68-9e10-11e6-9ad2-e87dbc767db1.jpeg

Regards.....


You are receiving this because you commented.

Reply to this email directly, view it on GitHub
#43 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAin9SbkrVR5LWrOfWIG-eetqusS9lgLks5q44eQgaJpZM4KjUzG
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants