Sponsored Content
Top Forums Shell Programming and Scripting A Crude 1KHz Audio Sinewave Generator Demo... Post 302761239 by wisecracker on Friday 25th of January 2013 10:56:42 AM
Old 01-25-2013
Hi DGPickett...

Certainly not 8 bytes for a single shot, that is for sure!

If it is possible to generate a "sinewave.mp3" _sinewave_ file, or any known waveshape for that matter, for 8 seconds inside 7 simple lines of code that anyone can understand without first recording said waveform then I would be mighty interested... ;o)
 

7 More Discussions You Might Find Interesting

1. Programming

Python, Platform Independent, Pure Audio Sinewave Generator...

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. Windows & DOS: Issues & Discussions

A SOX 1KHz Sinewave Generator Using A Batch File...

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

3. UNIX for Dummies Questions & Answers

A crude random byte generator...

There was an upload recently on generating a pseudo-random file when /dev/random does NOT exist. This does not need /dev/random, /dev/urandom or $RANDOM either... (I assume $RANDOM relies on the /dev/random device in some way.) This code uses hexdump just because I like hexdump for ease of... (2 Replies)
Discussion started by: wisecracker
2 Replies

4. OS X (Apple)

A Bash Audio Sweep Generator...

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)

An Audio Function Generator...

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

6. OS X (Apple)

Variable frequency audio generator...

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

7. OS X (Apple)

A simple variable frequency sinewave audio generator.

Hi all... Well I have not been inactive but working out how to make OSX 10.14.x command line audio player have a variable sample rate. This is a back door as afplay does not have a sample rate flag unlike aplay for ALSA, in Linux flavours. This is a DEMO only but a derivative of it will... (2 Replies)
Discussion started by: wisecracker
2 Replies
JACK_CAPTURE(1) 					      General Commands Manual						   JACK_CAPTURE(1)

NAME
jack_capture - A program for recording anything from jack SYNOPSIS
jack_capture [options] bar [options] DESCRIPTION
This manual page documents briefly the jack_capture command. This manual page was written for the Debian distribution because the original program does not have a manual page. jack_capture is a cli program for recording any audio signal from jack to audio audio formats supported by libsndfile library (wav, aiff, ogg, flac, wavex, au, etc.) For more info about libsndfile see http://www.mega-nerd.com/libsndfile/api.html#open OPTIONS
These programs follow the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. -b, --bitdepth n is by default FLOAT. It can be set to either 8, 16, 24 or 32. (for relevant formats) -c, --channels n is by default 2. -p, --port port is by default set to the two first physical outputs. The "port" argument can be specified more than once. -d, --duration s Recording is stopped after "s" seconds. -z, --leading-zeros n "n" is the number of zeros to in the autogenerated filename. (-z 2 -> jack_capture_001.wav, and so on.) (default is 1) -f, --format format Selects fileformat provided by libsndfile. See http://www.mega-nerd.com/libsndfile/api.html#open (Default is wav for 1 or 2 chan- nels, and wavex for more than 2.) -pf, --print-formats Prints all sound formats provided to sndfile to screen and then exits. -v, --version Prints out version. -s, --silent Suppress some common messages printed to the terminal. -V, --verbose] Prints some extra information to the terminal. -mp3, --mp3 Writes to an mp3 file using liblame (LAME). (the --format option has no effect using this option) -mp3q, --mp3-quality n Selects mp3 quality provided by liblame. n=0 is best, n=9 is worst. Default n is 2. (0 uses the most amount of CPU, 9 uses the least) -mp3b, --mp3-bitrate n Selects mp3 bitrate (in kbit/s). Default is set by liblame. (currently 128) -ws, --write-to-stdout Writes 16 bit little endian to stdout. (the --format option, the --mp3 option, and some others have no effect using this option) -dm, --disable-meter Disable console meter -hbu, --hide-buffer-usage Disable buffer usage. -dc, --disable-console Disable console updates. Same as "-dm -hbu". -lm, --linear-meter Use linear scale for the console meter (default is dB scale) -dBr, --dB-meter-reference Specify reference level for dB meter. (default=0) -mb, --meterbridge Start up meterbridge to monitor recorded sound. -mt, --meterbridge-type Specify type. vu (default), ppm, dpm, jf or sco. -mr, --meterbridge-reference Specify reference level for meterbidge. -jt, --jack-transport Start program, but do not start recording until jack transport has started rolling. When jack transport stops, the recording is stopped, and the program ends. -jtm, --jack-transport-multi Similar to --jack-transport, but do not end program when jack transport stops. Instead, record to a new file when jack_transport start rolling again. (not implemented yet) -B, --bufsize s Initial/minimum buffer size in seconds. Default is 8 seconds for mp3 files, and 4 seconds for all other formats. -MB, --maxbufsize Maximum buffer size in seconds. jack_capture will allocate. Default is 40. (Buffer is automatically increased during -fn, --filename Specify filename. (It's usually easier to set last argument instead) EXAMPLES
jack_capture [--bitdepth n] [--channels n] [--port port] [filename] jack_capture [-b n] [-c n] [-p port] [filename] jack_capture To record a stereo file of what you hear. ack_capture -f flac To record a stereo file of what you hear in the flac format. jack_capture -f ogg To record a stereo file of what you hear in the ogg format. jack_capture -mp3 To record a stereo file of what you hear in the mp3 format. jack_capture --channels 2 --port system:playback* To record a stereo file of what you hear in the wav format. jack_capture --port jamin:out* sound_from_jamin.wav To record the output from jamin. jack_capture --port jamin:in* sound_to_jamin.wav To record all sound coming in to jamin. jack_capture --port jamin* sound_to_and_from_jamin.wav To record all sound coming in and out of jamin. jack_capture -c 2 -p system:capture* To record a stereo file from the soundcard. SEE ALSO
jackd(1). AUTHOR
jack_capture was written by Kjetil Matheussen This manual page was written by Jaromir Mike <mira.mikes@seznam.cz>, for the Debian project (but may be used by others). July 28, 2010 JACK_CAPTURE(1)
All times are GMT -4. The time now is 03:45 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy