Project

General

Profile

Gapk » History » Revision 2

Revision 1 (laforge, 05/29/2017 09:12 AM) → Revision 2/18 (laforge, 05/29/2017 09:16 AM)

{{>toc}} 

 h1. gapk 

 The *G* SM *A* udio *P* ocket *K* nive (GAPK) is a small command-line tool that supports conversion between the various GSM related codecs (HR/FR/EFR/AMR) and PCM audio. It supports many different formats for the codec frames, including ETSI and IETF standardized formats, as well as vendor-specific formats like those found in the TI Calypso DSP (see [[OsmocomBB:]]) [[OsmocomBB]]) and those of Racal 6103/6113 GSM test equipment. 

 h2. Supported Codecs 

 |_.Codec|_.Description| 
 |pcm|Raw PCM signed 16bits samples| 
 |hr|GSM 06.20 Half Rate codec| 
 |fr|GSM 06.10 Full Rate codec (classic gsm codec)| 
 |efr|GSM 06.60 Enhanced Full Rate codec| 
 |amr|GSM 26.061 Adaptive Multi Rate codec| 

 h2. Supported Formats 

 |_.Format|_.Description| 
 |amr-efr               |Classic .amr file containing EFR (=AMR 12.2k) data| 
 |gsm                   |Classic .gsm file format (and RTP payload for FR according to RFC3551)| 
 |hr-ref-dec            |3GPP HR Reference decoder code parameters file format| 
 |hr-ref-enc            |3GPP HR Reference encoder code parameters file format| 
 |racal-hr              |Racal HR TCH/H recording| 
 |racal-fr              |Racal FR TCH/F recording| 
 |racal-efr             |Racal EFR TCH/F recording| 
 |rawpcm-s16le          |Raw PCM samples Signed 16 bits little endian| 
 |ti-hr                 |Texas Instrument HR TCH/H buffer format| 
 |ti-fr                 |Texas Instrument FR TCH/F buffer format| 
 |ti-efr                |Texas Instrument EFR TCH/F buffer format| 
 |amr-opencore          |Input format to libopencore-amrnb| 
 |rtp-amr               |RTP payload for AMR according to RFC4867| 
 |rtp-efr               |RTP payload for EFR according to RFC3551| 
 |rtp-hr-etsi           |RTP payload for HR according to ETSI TS 101 318| 
 |rtp-hr-ietf           |RTP payload for HR according to IETF RFC5993| 

 h2. Common use cases 

 h3. RTP sink with audio playback on sound card 

 You can run @gapk@ as a _RTP sink_, i.e. listening to a given UDP port for incoming RTP frames, decoding them from their respective audio codec and then playing them back via your computers' sound card. 

 <pre> 
 $ gapk -I 0.0.0.0/30000 -f rtp-amr -A default -g rawpcm-s16le 
 </pre> 

 where 
 * *@-I 0.0.0.0/30000@* indicates the IP adddress (any) and UDP port (30000) to bind to and receive RTP frames on 
 * *@-f rtp-amr@* indicates the codec. Use *@gsm, rtp-efr, rtp-amr, rtp-hr-etsi or rtp-hr-ietf@* depending on your use case 
 * *@-A default@* is the alsa hardware device name (default is the default sound card) 

 h2. Source Code 

 You can find the source code in git: 
 * http://git.osmocom.org/gapk/ (cgit web interface) 
 * @git clone git://git.osmocom.org/gapk@ for cloning the repository 

 h2. Authors 

 @gapk@ as written by Sylvain Munaut with contributions from Harald Welte.  

 It uses external libraries for the actual audio codecs, such as @libgsm@, @libopencore-amrnb@ nd the ETSI reference implementation for GSM-HR.
Add picture from clipboard (Maximum size: 48.8 MB)