06-07-2019
Thanks MadeInGermany, I will try this out on my main code.
I limited the DEMO to 6000Hz because it kept the BYTE manipulation easy to understand using only one little endian word per sample and byterate instead of the two little endian words for both. Also 8 bits unsigned per sample, and mono eliminates the need for other sections to be altered.
As an addendum the WAV file format:
Microsoft WAVE soundfile format
8 More Discussions You Might Find Interesting
1. Programming
IKHz_SW_OSX.py
A DEMO mono _pure_ sinewave generator using standard text mode Python 2.6.7 to at least 2.7.3.
This code is EASILY modifyable to Python version 3.x.x...
This DEMO kids level 1KHz generator is mainly for a MacBook Pro, (13 inch in my case), OSX 10.7.5 and above. See below...... (0 Replies)
Discussion started by: wisecracker
0 Replies
2. Shell Programming and Scripting
A very simple crude sinewave generator.
The file required is generated inside the code, is linear interpolated and requires /dev/audio to work. Ensure you have this device, if not the download oss-compat from your OS's repository...
It lasts for about 8 seconds before exiting and saves a... (5 Replies)
Discussion started by: wisecracker
5 Replies
3. Windows & DOS: Issues & Discussions
Hi all...
I don't think this has been done before but I am open to being corrected...
This batch file generates a 65536 byte binary file to give 8 seconds of pure sinewave at the earphone/speaker output(s)...
It uses ONLY a default Windows 32 bit installation, to Windows 7, except for the... (0 Replies)
Discussion started by: wisecracker
0 Replies
4. OS X (Apple)
This is a small program as a tester for a basic sweep generator for bandwidth testing of AudioScope.sh.
This DEMO is only capable of 4KHz down to about 85Hz and back due to the low bit rate, but it is proof of concept for a much wider variant using a much higher bit rate.
The file generated... (4 Replies)
Discussion started by: wisecracker
4 Replies
5. OS X (Apple)
This site is the first to get this snippet.
It will capture an audio recording of any time length within the limits of OSX's QuickTime Player's capablility...
A shell script derivative of this will be used as a further capture for CygWin's AudioScope.sh.
Thoroughly read ALL the comments in... (0 Replies)
Discussion started by: wisecracker
0 Replies
6. OS X (Apple)
Ok guys, gals and geeks...
As from today I am starting to learn awk in earnest doing something totally different.
I am going to create a pseudo-Audio_Function Generator centred around OSX 10.11.x minimum. The code below is a tester to see what the possibilities are.
All waveforms will be... (11 Replies)
Discussion started by: wisecracker
11 Replies
7. OS X (Apple)
Hi all...
I intend to do an Audio Function Generator using Awk, (already started thanks to Don), but the biggest thing I have struggled with was variable frequency.
I was going to generate differing sized waveforms on the fly but that would that would mean the frequencies are dependent on any... (2 Replies)
Discussion started by: wisecracker
2 Replies
8. Shell Programming and Scripting
This is a DEMO shell script to generate a simple graticule and plot inside it...
Apologies for any typos...
it is another building block along with my other two shell uploads recently to start a semi_serious project of an Terminal_AudioScope...
The fist upload I posted recently was to show... (83 Replies)
Discussion started by: wisecracker
83 Replies
LEARN ABOUT DEBIAN
sndinfo
SNDINFO(1) The Canonical Csound Reference SNDINFO(1)
NAME
sndinfo - Displays information about a soundfile. .
DESCRIPTION
Get basic information about one or more soundfiles.
SYNTAX
csound -U sndinfo [options] soundfilenames ...
sndinfo [options] soundfilenames ...
INITIALIZATION
sndinfo will attempt to find each named file, open it for reading, read in the soundfile header, then print a report on the basic
information it finds. The order of search across soundfile directories is as described above. If the file is of type AIFF, some further
details are listed first.
There are two option types:
1. -i or -i1 will print instrument information, which includes looping. The option continues until a -i0 option.
2. The other option is -b which prints the broadcast information for WAV files. It can similarly be negated with -b0.
EXAMPLES
csound -U sndinfo test Bosendorfer/"BOSEN mf A0 st" foo foo2
where the environment variables SFDIR = /u/bv/sound, and SSDIR = /so/bv/Samples, might produce the following:
util SNDINFO:
/u/bv/sound/test:
srate 22050, monaural, 16 bit shorts, 1.10 seconds
headersiz 1024, datasiz 48500 (24250 sample frames)
/so/bv/Samples/Bosendorfer/BOSEN mf A0 st: AIFF, 197586 stereo samples, base Frq 261.6 (MIDI 60), sustnLp: mode 1, 121642 to 197454, relesLp: mode 0
AIFF soundfile, looping with modes 1, 0
srate 44100, stereo, 16 bit shorts, 4.48 seconds
headersiz 402, datasiz 790344 (197586 sample frames)
/u/bv/sound/foo:
no recognizable soundfile header
/u/bv/sound/foo2:
couldn't find
AUTHORS
Barry Vercoe
MIT Media Lab
Author.
Dan Ellis
MIT Media Lab,
Cambridge
Massachussetts
Author.
COPYRIGHT
5.10 08/01/2011 SNDINFO(1)