From 3149b0d076477303a38df735fe579b1b06ee17b2 Mon Sep 17 00:00:00 2001 From: Philipp Maier Date: Fri, 2 Jun 2017 13:22:34 +0200 Subject: gsm0808: add function gsm0808_chan_type_to_speech_code() The permitted speech field used in channel type element (struct gsm0808_channel_type) uses a different representation as the type field in the speech codec element (struct gsm0808_speech_codec) This patch adds a function to convert from permitted speech to speech codec type. Change-Id: Ib26a9c20864459b2baaa04f49b6e7902ba44b7cb --- include/osmocom/gsm/gsm0808_utils.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/osmocom/gsm/gsm0808_utils.h') diff --git a/include/osmocom/gsm/gsm0808_utils.h b/include/osmocom/gsm/gsm0808_utils.h index c11bf8d3..b5106447 100644 --- a/include/osmocom/gsm/gsm0808_utils.h +++ b/include/osmocom/gsm/gsm0808_utils.h @@ -71,3 +71,5 @@ uint8_t gsm0808_enc_cell_id_list(struct msgb *msg, /* Decode Cell Identifier List element */ int gsm0808_dec_cell_id_list(struct gsm0808_cell_id_list *cil, const uint8_t *elem, uint8_t len); + +int gsm0808_chan_type_to_speech_code(uint8_t perm_spch); -- cgit v1.2.3