summaryrefslogtreecommitdiff
path: root/cesar/mac/sar/test/functional/src/test_functions.c
diff options
context:
space:
mode:
authordufour2010-04-14 08:57:04 +0000
committerdufour2010-04-14 08:57:04 +0000
commitf57b67f6b2c243c5acc90aa2a3e830c6ba2b0bd5 (patch)
treee3f2bb3d753fd98532ec28ca857a2e20948c90d8 /cesar/mac/sar/test/functional/src/test_functions.c
parent00d554ff3f2bd8f7b047319c4c4a5f41bb5adc26 (diff)
cesar/{mac/sar,ce/rx}: update SAR callback to get BER, closes #1442
PB measurements are no longer given by the SAR CB: it directly pre-computes the BER sum (on PBs with no CRC error), the total count of PBs inside the frame and the count of PBs with CRC error in the frame. In the CE, measure now contains: - RX params, - channel data if there are some, - some statistics (total PBs count, total false PBs, BER sum) No need any more to give some pointer to the SAR, measure data are directly delivered from the SAR for copy. Configuration for "PB measurements get flag" is now removed from the CE. Tests have been updated. git-svn-id: svn+ssh://pessac/svn/cesar/trunk@6922 017c9cb6-072f-447c-8318-d5b54f68fe89
Diffstat (limited to 'cesar/mac/sar/test/functional/src/test_functions.c')
-rw-r--r--cesar/mac/sar/test/functional/src/test_functions.c21
1 files changed, 7 insertions, 14 deletions
diff --git a/cesar/mac/sar/test/functional/src/test_functions.c b/cesar/mac/sar/test/functional/src/test_functions.c
index c59a05f37d..86acf36f2b 100644
--- a/cesar/mac/sar/test/functional/src/test_functions.c
+++ b/cesar/mac/sar/test/functional/src/test_functions.c
@@ -48,20 +48,13 @@ static uint nb_frames_tx;
static uint nb_frames_rx;
/* Stubbed Functions. */
-bool
-ce_measurements_none (void *user, pbproc_rx_params_t *rx_params, uint pb_nb,
- blk_t **first, blk_t **last, pb_t *chandata,
- uint nb_chandata, u8 **ce_pb_crc_error)
+void
+ce_measurements (void *data, pbproc_rx_params_t *rx_params,
+ uint total_pb_count, pb_t *chan_data,
+ uint chan_data_count, u8 false_pb_count, u32 ber_sum)
{
- if (chandata)
- blk_release_desc_range_nb ((blk_t*) chandata, nb_chandata);
-
- if (pb_nb)
- {
- dbg_assert (ce_pb_crc_error);
- *ce_pb_crc_error = NULL;
- }
- return false;
+ if (chan_data)
+ blk_release_desc_range_nb ((blk_t*) chan_data, chan_data_count);
}
static void
@@ -115,7 +108,7 @@ sar_test_init (sar_test_ctx_t *test_ctx)
2);
/* CE. */
sar_init_measure_context (test_ctx->sar, INVALID_PTR);
- sar_init_measurement_cb (test_ctx->sar, ce_measurements_none);
+ sar_init_measurement_cb (test_ctx->sar, ce_measurements);
sar_init_data_context (test_ctx->sar, INVALID_PTR);
sar_init_segmentation_data_cb (test_ctx->sar,
sar_test_segmentation_done__do_nothing);