LoginLogin

Wav Recorder

Root / Submissions / [.]

SamKitsuneCreated:
Download:Y3EKE3D6
Version:1.1Size:244.5 KB
The SmileTool's Wav program is a good tool for recording and playing sounds, but it records up to two seconds! What if you can record and play sounds up to ten seconds, or even stop recording midway? The Wav Recorder is the tool for the job! It's a simple tool to record, save, and load sounds up to 30 seconds. Follow the onscreen prompt. UPDATE: Decrease in file size. Records up to 30 seconds. Includes Wav Player library - a library to playback your WAV files for your project. Version 1.0 has some playback bug, but otherwise, runs perfectly. Will add an easier way to play sounds from the .WAV file to other programs.

Instructions:

The instructions for Wav Recorder are pre-built in the tool. To use Wav Player for your project, please include these lines at the beginning of the project. LOAD "PRG1:WAVPLAYER.LIB",FALSE USE 1 EXEC 1 WAVPLAY must be included in the beginning of the loop that you're running the WAV file. Otherwise, you will have an error. EX: WHILE 1 WAVPLAY WEND WAVLOAD loads and plays the WAV file. In quotes, type the file name. You can type either the simple name or the full name. EX: WAVLOAD "WAVFILE" : WAVLOAD "DAT:WAVFILE.WAV" WAVSTOP stops playing the WAV file. For reference, you can look up WAVTEST, and see how it works.

Replying to:amihart
Why 30 seconds? If you're recording using at 8-bit fixed you can record at least 2 minutes worth before running out of memory.
Does that mean a 32bit WAV at the same sample rate would take up the same amount of memory as an 8bit WAV? I guess I should've specified the sample rate then, I meant WAVs recorded at 8180 Hz can be recorded up to about 2 minutes (128 seconds). Sorry, I'm pretty new to all this stuff.

Replying to:amihart
Why 30 seconds? If you're recording using at 8-bit fixed you can record at least 2 minutes worth before running out of memory.
yes, it would

So would there be a way to record more than just 30 seconds? It would be nice, even though i don't use more than 30 seconds, this is good to record a few chords, then you might want to put it on a loop so you could improvise off it. I would love to have a loop for this, just a my greedy thoughts though. :D

Replying to:Heigw
So would there be a way to record more than just 30 seconds? It would be nice, even though i don't use more than 30 seconds, this is good to record a few chords, then you might want to put it on a loop so you could improvise off it. I would love to have a loop for this, just a my greedy thoughts though. :D
If you're using a sample rate of 8180 hz you can record over 2 minutes. Have an array as a buffer and every 30 seconds expand the size of the buffer and copy in a new 30 seconds of audio. If you raise the sample rate, the length you can record goes down.

Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127

Replying to:MCGamer20000
Bug: Stopping playback of a WAV (noticeable in WAVTEST) can cause a high pitched beep for a second.
I fixed it! Insert this code after line 67: FILL VOICEA,127

Replying to:12Me21
Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127
After I turn off option strict, this doesn't work; on its own in line 43, I get
Type mismatch in 43(FILL:1)
and if I put it at the end of line 42 the problem isn't resolved. So what do you mean? Or are you not using 1.1?

Replying to:12Me21
Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127
Oops, I gave the wrong line. (the version of WAVPLAYER.LIB that I had was modified) It should be line 67

Replying to:12Me21
Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127
If I append your command to the end of line 67 after putting a space (and turning off option strict) on both the main program and the lib there is still the beep, so it seems I'm misunderstanding something. So, then, what does line 67 in which program look like?

Replying to:12Me21
Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127
 IF WAVFR==LOAD_WAV[0] THEN 
  (insert code here)
  WAVSETA 224,0,127,0,127,VOICEA,78,0,1

Replying to:12Me21
Well, I've finally fixed the beeping problem... Insert this code after line 42: FILL VOICEA,127
Ah, thanks. Maybe SamKitsune should update the program!

I used this to make an english TALK command. Awesome!

I'm unable to get a full 4-second long WAV file to play, half of it is cut out!