00001 /* -*-C-*- 00002 ******************************************************************************* 00003 * 00004 * File: microtune_eval_board_defs.h 00005 * Description: defines for parallel port control of eval board 00006 * 00007 ******************************************************************************* 00008 */ 00009 00010 /* 00011 * Copyright 2001 Free Software Foundation, Inc. 00012 * 00013 * This file is part of GNU Radio 00014 * 00015 * GNU Radio is free software; you can redistribute it and/or modify 00016 * it under the terms of the GNU General Public License as published by 00017 * the Free Software Foundation; either version 2, or (at your option) 00018 * any later version. 00019 * 00020 * GNU Radio is distributed in the hope that it will be useful, 00021 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00022 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00023 * GNU General Public License for more details. 00024 * 00025 * You should have received a copy of the GNU General Public License 00026 * along with GNU Radio; see the file COPYING. If not, write to 00027 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00028 * Boston, MA 02111-1307, USA. 00029 */ 00030 00031 #ifndef _MICROTUNE_EVAL_BOARD_DEFS_H_ 00032 #define _MICROTUNE_EVAL_BOARD_DEFS_H_ 00033 00034 /* 00035 * The Microtune 4937DI5 cable modem tuner eval board is controlled 00036 * by bit banging the PC parallel port. This file defines the relevant 00037 * bits. 00038 * 00039 * The parallel port has an 8 bit data port (output), 00040 * an 8 bit control port (output) and 00041 * an 8 bit status port (input). 00042 * 00043 * Not all bits of the control and status ports may be arbitrarily used. 00044 */ 00045 00046 00047 // parallel port data port constants (output) 00048 00049 static const int UT_DP_TX_SDA = 0x01; // upstream control bus 00050 static const int UT_DP_TX_SCL = 0x02; // upstream control bus 00051 static const int UT_DP_TX_AS = 0x04; // upstream control bus 00052 static const int UT_DP_TX_ENABLE = 0x08; // upstream h/w enable 00053 // bits 4,5,6 not used 00054 static const int UT_DP_TUNER_SDA_OUT = 0x80; // tuner i2c bus data 00055 00056 // parallel port control port constants (output) 00057 00058 static const int UT_CP_TUNER_SCL = 0x08; // tuner i2c bus clock 00059 static const int UT_CP_MUST_BE_ZERO = 0xf0; // must be zero 00060 00061 // parallel port status port constants (input) 00062 00063 // bits 0,1,2 not used 00064 static const int UT_SP_TUNER_SCL_LOOP_BACK= 0x08; // inverted SCL loop back 00065 static const int UT_SP_SHOULD_BE_ZERO = 0x10; // reads as zero 00066 static const int UT_SP_SHOULD_BE_ONE = 0x20; // reads as one 00067 // bit 6 not used 00068 static const int UT_SP_TUNER_SDA_IN = 0x80; 00069 00070 00071 #endif /* _MICROTUNE_EVAL_BOARD_DEFS_H_ */