FreeCalypso > hg > gsm-codec-lib
annotate amrtest/Makefile @ 581:e2d5cad04cbf
libgsmhr1 RxFE: store CN R0+LPC separately from speech
In the original GSM 06.06 code the ECU for speech mode is entirely
separate from the CN generator, maintaining separate state. (The
main intertie between them is the speech vs CN state variable,
distinguishing between speech and CN BFIs, in addition to the
CN-specific function of distinguishing between initial and update
SIDs.)
In the present RxFE implementation I initially thought that we could
use the same saved_frame buffer for both ECU and CN, overwriting
just the first 4 params (R0 and LPC) when a valid SID comes in.
However, I now realize it was a bad idea: the original code has a
corner case (long sequence of speech-mode BFIs to put the ECU in
state 6, then SID and CN-mode BFIs, then a good speech frame) that
would be broken by that buffer reuse approach. We could eliminate
this corner case by resetting the ECU state when passing through
a CN insertion period, but doing so would needlessly increase
the behavioral diffs between GSM 06.06 and our version.
Solution: use a separate CN-specific buffer for CN R0+LPC parameters,
and match the behavior of GSM 06.06 code in this regard.
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 13 Feb 2025 10:02:45 +0000 |
parents | cb1d1ea7f2c5 |
children |
rev | line source |
---|---|
446
e2f824ffd08a
amrtest: implement twamr-decode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
445
diff
changeset
|
1 PROGS= twamr-decode twamr-decode-r twamr-encode twamr-encode-r twamr-tseq-dec \ |
e2f824ffd08a
amrtest: implement twamr-decode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
445
diff
changeset
|
2 twamr-tseq-enc |
422
1ceda5586d01
implement twamr-tseq-enc test program
Mychaela Falconia <falcon@freecalypso.org>
parents:
239
diff
changeset
|
3 LIBAMR= ../libtwamr/libtwamr.a |
443
526a7f0e027d
amrtest: implement twamr-encode
Mychaela Falconia <falcon@freecalypso.org>
parents:
436
diff
changeset
|
4 LIBTEST=../libtest/libtest.a |
453
19f1aa01ea10
new approach to config & build for ThemWi software
Mychaela Falconia <falcon@freecalypso.org>
parents:
446
diff
changeset
|
5 |
19f1aa01ea10
new approach to config & build for ThemWi software
Mychaela Falconia <falcon@freecalypso.org>
parents:
446
diff
changeset
|
6 include ../config.defs |
12
f88817a233fb
gsmfr-decode test program written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
7 |
27
896ce7f1d271
frtest: cn-debug is now gsmfr-max-out
Mychaela Falconia <falcon@freecalypso.org>
parents:
26
diff
changeset
|
8 all: ${PROGS} |
12
f88817a233fb
gsmfr-decode test program written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
9 |
444
fe4983b05230
amrtest: implement twamr-decode
Mychaela Falconia <falcon@freecalypso.org>
parents:
443
diff
changeset
|
10 twamr-decode: decode.o ${LIBAMR} ${LIBTEST} |
fe4983b05230
amrtest: implement twamr-decode
Mychaela Falconia <falcon@freecalypso.org>
parents:
443
diff
changeset
|
11 ${CC} ${CFLAGS} -o $@ $^ |
fe4983b05230
amrtest: implement twamr-decode
Mychaela Falconia <falcon@freecalypso.org>
parents:
443
diff
changeset
|
12 |
446
e2f824ffd08a
amrtest: implement twamr-decode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
445
diff
changeset
|
13 twamr-decode-r: decode-r.o ${LIBAMR} ${LIBTEST} |
e2f824ffd08a
amrtest: implement twamr-decode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
445
diff
changeset
|
14 ${CC} ${CFLAGS} -o $@ $^ |
e2f824ffd08a
amrtest: implement twamr-decode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
445
diff
changeset
|
15 |
443
526a7f0e027d
amrtest: implement twamr-encode
Mychaela Falconia <falcon@freecalypso.org>
parents:
436
diff
changeset
|
16 twamr-encode: encode.o mode_file.o mode_kw.o ${LIBAMR} ${LIBTEST} |
526a7f0e027d
amrtest: implement twamr-encode
Mychaela Falconia <falcon@freecalypso.org>
parents:
436
diff
changeset
|
17 ${CC} ${CFLAGS} -o $@ $^ |
526a7f0e027d
amrtest: implement twamr-encode
Mychaela Falconia <falcon@freecalypso.org>
parents:
436
diff
changeset
|
18 |
445
30cff6b60890
amrtest: implement twamr-encode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
444
diff
changeset
|
19 twamr-encode-r: encode-r.o mode_file.o mode_kw.o ${LIBAMR} ${LIBTEST} |
30cff6b60890
amrtest: implement twamr-encode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
444
diff
changeset
|
20 ${CC} ${CFLAGS} -o $@ $^ |
30cff6b60890
amrtest: implement twamr-encode-r
Mychaela Falconia <falcon@freecalypso.org>
parents:
444
diff
changeset
|
21 |
430
edbbbf1c4ab1
implement twamr-tseq-dec test program
Mychaela Falconia <falcon@freecalypso.org>
parents:
422
diff
changeset
|
22 twamr-tseq-dec: tseq-dec.o ${LIBAMR} |
436
e80632ccb745
simplify test program Makefiles
Mychaela Falconia <falcon@freecalypso.org>
parents:
430
diff
changeset
|
23 ${CC} ${CFLAGS} -o $@ $^ |
430
edbbbf1c4ab1
implement twamr-tseq-dec test program
Mychaela Falconia <falcon@freecalypso.org>
parents:
422
diff
changeset
|
24 |
422
1ceda5586d01
implement twamr-tseq-enc test program
Mychaela Falconia <falcon@freecalypso.org>
parents:
239
diff
changeset
|
25 twamr-tseq-enc: mode_file.o mode_kw.o tseq-enc.o ${LIBAMR} |
436
e80632ccb745
simplify test program Makefiles
Mychaela Falconia <falcon@freecalypso.org>
parents:
430
diff
changeset
|
26 ${CC} ${CFLAGS} -o $@ $^ |
24
94f18b720f1e
new debug utility gsmfr-preproc
Mychaela Falconia <falcon@freecalypso.org>
parents:
19
diff
changeset
|
27 |
17
68a7e86c9868
frtest/Makefile: add install
Mychaela Falconia <falcon@freecalypso.org>
parents:
14
diff
changeset
|
28 install: |
460
cb1d1ea7f2c5
new build system: accept more directory options
Mychaela Falconia <falcon@freecalypso.org>
parents:
453
diff
changeset
|
29 mkdir -p ${DESTDIR}${bindir} |
cb1d1ea7f2c5
new build system: accept more directory options
Mychaela Falconia <falcon@freecalypso.org>
parents:
453
diff
changeset
|
30 install -c ${PROGS} ${DESTDIR}${bindir} |
17
68a7e86c9868
frtest/Makefile: add install
Mychaela Falconia <falcon@freecalypso.org>
parents:
14
diff
changeset
|
31 |
12
f88817a233fb
gsmfr-decode test program written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
32 clean: |
27
896ce7f1d271
frtest: cn-debug is now gsmfr-max-out
Mychaela Falconia <falcon@freecalypso.org>
parents:
26
diff
changeset
|
33 rm -f *.o *.out ${PROGS} |