Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Sound card programming

Hello Everybody,

I'm new to programming. I have knowledge of C and C++.Now, I need to generate a 10KHz audio signal from a sound card and thereafter perform signal processing at the receiving end.

I'm not able to understand how to start.Can anybody give similiar examples which could help me out?

Thanking you,
vasu.

Comments

  • cbodapaticbodapati Posts: 65Member
    : Hello Everybody,
    :
    : I'm new to programming. I have knowledge of C and C++.Now, I need to generate a 10KHz audio signal from a sound card and thereafter perform signal processing at the receiving end.
    :
    : I'm not able to understand how to start.Can anybody give similiar examples which could help me out?
    :
    : Thanking you,
    : vasu.
    :

    hi vasu,
    to do it in realtime vc++ is a good tool, else vb can also be considered.

    srikanth.


    Regards
    srikanth

  • vasu_raovasu_rao Posts: 2Member
    : : Hello Everybody,
    : :
    : : I'm new to programming. I have knowledge of C and C++.Now, I need to generate a 10KHz audio signal from a sound card and thereafter perform signal processing at the receiving end.
    : :
    : : I'm not able to understand how to start.Can anybody give similiar examples which could help me out?
    : :
    : : Thanking you,
    : : vasu.
    : :
    :
    : hi vasu,
    : to do it in realtime vc++ is a good tool, else vb can also be considered.
    :
    : srikanth.
    :
    :
    : Regards
    : srikanth

    Hello Srikanth!
    Thanks for replying me. Yes! many people advised me to do in VC++ as it is device independent.Let me tell you that I just know C and C++ programming but I have'nt worked in this kind ever before.
    I tried to play and read some .wav files using C++ programs.But I'm really confused about how to start a program generating a 10KHz signal.Somone advised me to learn windows programming before going to the actual one.
    Kidly inform me the basic topics I need to learn and also help me finding any similiar programs available so that I could get an idea.
    Thanking You,
    Regards,
    Vasu.

  • PhivePhive Posts: 3Member
    : : : Hello Everybody,
    : : :
    : : : I'm new to programming. I have knowledge of C and C++.Now, I need to generate a 10KHz audio signal from a sound card and thereafter perform signal processing at the receiving end.
    : : :
    : : : I'm not able to understand how to start.Can anybody give similiar examples which could help me out?
    : : :
    : : : Thanking you,
    : : : vasu.
    : : :
    : :
    : : hi vasu,
    : : to do it in realtime vc++ is a good tool, else vb can also be considered.
    : :
    : : srikanth.
    : :
    : :
    : : Regards
    : : srikanth
    :
    : Hello Srikanth!
    : Thanks for replying me. Yes! many people advised me to do in VC++ as
    : it is device independent.Let me tell you that I just know C and C++
    : programming but I have'nt worked in this kind ever before.
    : I tried to play and read some .wav files using C++ programs.But I'm
    : really confused about how to start a program generating a 10KHz
    : signal.Somone advised me to learn windows programming before going
    : to the actual one.
    : Kidly inform me the basic topics I need to learn and also help me
    : finding any similiar programs available so that I could get an idea.
    : Thanking You,
    : Regards,
    : Vasu.
    :
    :

    I suggest playing with trig functions. sin(x*10) will give you a good
    sine wave with a freq of 10Hz (I think) but try combining waves, etc.
    Sound is all about waveforms, and in order to generate them correctly,
    (Without going to college again) is to experiment...

    QBASIC:

    OUT &H61, COS(X*10)*10

    will give you a wave with freq of 10Hz, and amplitude of 10.
    I suggest dictionary.com before you ask me anything like
    "What's amplitude?" So, just experiment, and see what works how.

    PS. I am a QBASIC programmer, and I am also a little
    good at C++, but QBASIC is second nature, so paraphrase
    into preferable language.

    PPS. If you wanted to ask, I wanted to make techno
    a while back, so I started playing with my soundcard
    (&H220, usually SB, but &H61, always PC SPK, only good
    for simple waves and chirps (unless, sometimes laptops
    will do more depending on the driver for built in SPK))

    But, in your case, I would try:

    QBASIC:

    OUT &H61, COS(X*10000)* [Intended Amplitude]

    That should do it.



  • PhivePhive Posts: 3Member
    Also, low level (for me) is easier,
    if you must ask, so libraries are not
    [italic]technically[/italic] necissary,
    at least in QB.
Sign In or Register to comment.