Main Page | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

private/bert.h

00001 /*
00002  * SpanDSP - a series of DSP components for telephony
00003  *
00004  * private/bert.h - Bit error rate tests.
00005  *
00006  * Written by Steve Underwood <steveu@coppice.org>
00007  *
00008  * Copyright (C) 2004 Steve Underwood
00009  *
00010  * All rights reserved.
00011  *
00012  * This program is free software; you can redistribute it and/or modify
00013  * it under the terms of the GNU Lesser General Public License version 2.1,
00014  * as published by the Free Software Foundation.
00015  *
00016  * This program is distributed in the hope that it will be useful,
00017  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019  * GNU Lesser General Public License for more details.
00020  *
00021  * You should have received a copy of the GNU Lesser General Public
00022  * License along with this program; if not, write to the Free Software
00023  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00024  *
00025  * $Id: bert.h,v 1.1 2008/11/30 12:38:27 steveu Exp $
00026  */
00027 
00028 #if !defined(_SPANDSP_PRIVATE_BERT_H_)
00029 #define _SPANDSP_PRIVATE_BERT_H_
00030 
00031 /*!
00032     Bit error rate tester (BERT) descriptor. This defines the working state for a
00033     single instance of the BERT.
00034 */
00035 struct bert_state_s
00036 {
00037     int pattern;
00038     int pattern_class;
00039     bert_report_func_t reporter;
00040     void *user_data;
00041     int report_frequency;
00042     int limit;
00043 
00044     uint32_t tx_reg;
00045     int tx_step;
00046     int tx_step_bit;
00047     int tx_bits;
00048     int tx_zeros;
00049 
00050     uint32_t rx_reg;
00051     uint32_t ref_reg;
00052     uint32_t master_reg;
00053     int rx_step;
00054     int rx_step_bit;
00055     int resync;
00056     int rx_bits;
00057     int rx_zeros;
00058     int resync_len;
00059     int resync_percent;
00060     int resync_bad_bits;
00061     int resync_cnt;
00062     
00063     uint32_t mask;
00064     int shift;
00065     int shift2;
00066     int max_zeros;
00067     int invert;
00068     int resync_time;
00069 
00070     int decade_ptr[9];
00071     int decade_bad[9][10];
00072     int step;
00073     int error_rate;
00074 
00075     int bit_error_status;
00076     int report_countdown;
00077 
00078     bert_results_t results;
00079 
00080     /*! \brief Error and flow logging control */
00081     logging_state_t logging;
00082 };
00083 
00084 #endif
00085 /*- End of file ------------------------------------------------------------*/

Generated on Fri Aug 28 20:12:26 2009 for spandsp by  doxygen 1.3.9.1