FreeCalypso > hg > themwi-system-sw
comparison mgw/mdcx.c @ 205:0047c4c08d9e
mgw: accept the new TRAUlike RTP format
in addition to standard, old BFI and zero-length payload formats
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 06 Apr 2023 19:50:09 -0800 |
parents | c985c33baeac |
children |
comparison
equal
deleted
inserted
replaced
204:de7c64c4d6fd | 205:0047c4c08d9e |
---|---|
10 #include <stdint.h> | 10 #include <stdint.h> |
11 #include <stdlib.h> | 11 #include <stdlib.h> |
12 #include <string.h> | 12 #include <string.h> |
13 #include <strings.h> | 13 #include <strings.h> |
14 #include <syslog.h> | 14 #include <syslog.h> |
15 #include "../include/codec_defs.h" | |
15 #include "../include/tmgw_ctrl.h" | 16 #include "../include/tmgw_ctrl.h" |
16 #include "../include/tmgw_const.h" | 17 #include "../include/tmgw_const.h" |
17 #include "struct.h" | 18 #include "struct.h" |
18 #include "int_defs.h" | |
19 | 19 |
20 extern struct endpoint *find_ep_by_id(); | 20 extern struct endpoint *find_ep_by_id(); |
21 | 21 |
22 static void | 22 static void |
23 gsm_vars_init(ep) | 23 gsm_vars_init(ep) |
24 struct endpoint *ep; | 24 struct endpoint *ep; |
25 { | 25 { |
26 switch (ep->gsm_payload_msg_type) { | 26 switch (ep->gsm_payload_msg_type) { |
27 case GSM_TCHF_FRAME: | 27 case GSM_TCHF_FRAME: |
28 ep->gsm_rtp_pkt_size = RTP_PACKET_SIZE_GSM_FR; | 28 ep->gsm_payload_len = GSM_FR_BYTES; |
29 ep->gsm_payload_magic = 0xD0; | 29 ep->gsm_payload_magic = 0xD0; |
30 return; | 30 return; |
31 case GSM_TCHF_FRAME_EFR: | 31 case GSM_TCHF_FRAME_EFR: |
32 ep->gsm_rtp_pkt_size = RTP_PACKET_SIZE_GSM_EFR; | 32 ep->gsm_payload_len = GSM_EFR_BYTES; |
33 ep->gsm_payload_magic = 0xC0; | 33 ep->gsm_payload_magic = 0xC0; |
34 return; | 34 return; |
35 } | 35 } |
36 } | 36 } |
37 | 37 |