Solved

Input from Audio Port

Posted on 1997-10-06
10
215 Views
Last Modified: 2010-04-16
How is it possible to input audio information (from a microphone or something) and use it in a pascal program.  I would also like to be able to alter this information (i.e., echo, distortion, volume adjustment, etc.).  How do I do any of this?
0
Comment
Question by:Krueger092397
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
  • +1
10 Comments
 
LVL 2

Expert Comment

by:kellyjj
ID: 1216109
I believe you can do it the same way you would want to read the mouse/com port etc....    Access the part of memory/ the interrupt  that would be connected to your port.  You should also be able to write to that memory.  In pascal you the "mem[seg:off]"  that can be used to write directly to mem.

I know this isn't the best answer, but I hope it helps
0
 

Author Comment

by:Krueger092397
ID: 1216110
But how do I write to procedures that access the mouse, com, and audio ports?  What are the commands that I have to type?  Additionally, how can I play the sounds on a Pascal program once I have made contact with a port?
0
 
LVL 1

Expert Comment

by:potsy
ID: 1216111
if it is of any help I have the source to pogram the soundblaster pro card.
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 2

Expert Comment

by:kellyjj
ID: 1216112
krueger,  How well do you know pascal?  If you don't know it real well, then you might want to  reject this answer and get potsy's source.
0
 

Author Comment

by:Krueger092397
ID: 1216113
I don't know Pascal all that well.  I just started programming late this August, so my programs consists mainly of text and some mathematical calculations.  I'd like to do more (such as something involving input from other ports) but I have no idea how to do this.
0
 

Author Comment

by:Krueger092397
ID: 1216114
Potsy, how can I get the source code from you?  Are you going to upload it onto this message board or do you want me e-mail address to upload it personally?  

0
 
LVL 1

Expert Comment

by:potsy
ID: 1216115
well the source I have I got off the net and haven't had the time to test it yet so I'll give you the url and if it has what you need I'll submit this as an answer.

http://www.lakenet.com/~potter/audio.pas
0
 

Author Comment

by:Krueger092397
ID: 1216116
I can't really use the code until I know how I can related it to input coming from other ports.  It should help once I know how to access the ports, though.  Until then...
0
 
LVL 1

Expert Comment

by:potsy
ID: 1216117
so what would you like to do?
0
 

Accepted Solution

by:
mes earned 100 total points
ID: 1216118
Hi Krueger,

Try this piece of code:

procedure testAudio;
const soundblasterAddress = $220;
      phone               = 0;

begin
  repeat
    writeLn(port[soundblasterAddress+phone]:3);
  until keyPressed;
end;

I don't know what value you have to use for phone, but you can try all values from 0 to 15 there. When you talk into your phone and the values on the screen changes, you have the right value.

If you would save all that data to a file at a regular time interval, you can add echo, etc. to it.

Greetings from the Netherlands,
MES.

0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Check out this step-by-step guide for asking an anonymous question on Experts Exchange.
This article describes a serious pitfall that can happen when deleting shapes using VBA.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question