csn1: Implement CSN_CALLBACK type in encoder
Picked code from the Decoder function. I gave it a try
callback_init_Cell_Selection_Params_FREQUENCY_DIFF and looks
like working fine.
Change-Id: Iac962ae3e9f52f417f394060b64fc4d0ebf3d0bf
diff --git a/src/csn1.c b/src/csn1.c
index 0a3c88c..2be0392 100644
--- a/src/csn1.c
+++ b/src/csn1.c
@@ -2694,7 +2694,13 @@
case CSN_CALLBACK:
{
- return ProcessError(writeIndex,"csnStreamEncoder Callback not implemented", -1, pDescr);
+ guint16 no_of_bits;
+ DissectorCallbackFcn_t callback = (DissectorCallbackFcn_t)pDescr->aux_fn;
+ LOGPC(DCSN1, LOGL_DEBUG, "CSN_CALLBACK(%s) | ", pDescr->sz);
+ no_of_bits = callback(vector, writeIndex, pvDATA(data, pDescr->i), pvDATA(data, pDescr->offset));
+ remaining_bits_len -= no_of_bits;
+ bit_offset += no_of_bits;
+ pDescr++;
break;
}