rtpsend-pcmu.pl - Send an audio file an RTP session as u-law
rtpsend-pcmu.pl <filename> <dest_addr> [<dest_port>] [<ttl>]
rtpsend-pcmu.pl sends audio files to an RTP session using PCM u-law (G.711) payload encoding (RTP payload type 0). If no port is specified, then port 5004 is assumed. If no TTL is specified, then a TTL of 2 is assumed.
Each packet sent contains 160 samples of audio, and as payload type 0 has a fixed sample rate of 8000Hz, each packet has a duration of 20 miliseconds.
rtpsend-pcmu.pl uses the 'sox' command as helper to transcode and resample the audio file to u-law, which means that many audio file formats are automatically supported (AIFF, WAVE, SUN .au, GSM, ...).
Doesn't keep packet sending timing very well - it goes out of sync very quickly.
Nicholas J Humfrey, email@example.com
COPYRIGHT AND LICENSE
Copyright (C) 2006 University of Southampton
This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.005 or, at your option, any later version of Perl 5 you may have available.