~ubuntu-branches/ubuntu/trusty/gnuradio/trusty

« back to all changes in this revision

Viewing changes to usrp2/firmware/lib/clocks.h

  • Committer: Bazaar Package Importer
  • Author(s): Kamal Mostafa
  • Date: 2010-03-13 07:46:01 UTC
  • mfrom: (2.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100313074601-zjsa893a87bozyh7
Tags: 3.2.2.dfsg-1ubuntu1
* Fix build for Ubuntu lucid (LP: #260406)
  - add binary package dep for libusrp0, libusrp2-0: adduser
  - debian/rules clean: remove pre-built Qt moc files

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- c++ -*- */
 
2
/*
 
3
 * Copyright 2008 Free Software Foundation, Inc.
 
4
 *
 
5
 * This program is free software: you can redistribute it and/or modify
 
6
 * it under the terms of the GNU General Public License as published by
 
7
 * the Free Software Foundation, either version 3 of the License, or
 
8
 * (at your option) any later version.
 
9
 *
 
10
 * This program is distributed in the hope that it will be useful,
 
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
 * GNU General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public License
 
16
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
17
 */
 
18
 
 
19
#ifndef INCLUDED_CLOCKS_H
 
20
#define INCLUDED_CLOCKS_H
 
21
 
 
22
/*
 
23
 * Routines to configure our multitude of clocks
 
24
 */
 
25
 
 
26
#include <bool.h>
 
27
#include <usrp2_mimo_config.h>
 
28
 
 
29
 
 
30
/*!
 
31
 * One time call to initialize all clocks to a reasonable state.  We
 
32
 * come out of here using our free running 100MHz oscilator and not
 
33
 * providing a clock to the MIMO connector (CMC_WE_DONT_LOCK)
 
34
 */
 
35
void clocks_init(void);
 
36
 
 
37
 
 
38
/*!
 
39
 * \brief MIMO clock configuration.
 
40
 *
 
41
 * Configure our master clock source, and whether or not we drive a
 
42
 * clock onto the mimo connector.  See MC_flags in usrp2_mimo_config.h.
 
43
 */
 
44
void clocks_mimo_config(int flags);
 
45
 
 
46
/*!
 
47
 * \brief Lock Detect -- Return True if our PLL is locked
 
48
 */
 
49
bool clocks_lock_detect();
 
50
 
 
51
/*!
 
52
 * \brief Enable or disable test clock (extra clock signal)
 
53
 */
 
54
void clocks_enable_test_clk(bool enable, int divisor);
 
55
 
 
56
/*!
 
57
 * \brief Enable or disable fpga clock.  Disabling would wedge and require a power cycle.
 
58
 */
 
59
void clocks_enable_fpga_clk(bool enable, int divisor);
 
60
 
 
61
/*!
 
62
 * \brief Enable or disable clock output sent to MIMO connector
 
63
 */
 
64
void clocks_enable_clkexp_out(bool enable, int divisor);
 
65
 
 
66
/*!
 
67
 * \brief Enable or disable ethernet phyclk, should always be disabled
 
68
 */
 
69
void clocks_enable_eth_phyclk(bool enable, int divisor);
 
70
 
 
71
/*!
 
72
 * \brief Enable or disable clock to DAC
 
73
 */
 
74
void clocks_enable_dac_clk(bool enable, int divisor);
 
75
 
 
76
/*!
 
77
 * \brief Enable or disable clock to ADC
 
78
 */
 
79
void clocks_enable_adc_clk(bool enable, int divisor);
 
80
 
 
81
/*!
 
82
 * \brief Enable or disable clock to Rx daughterboard
 
83
 */
 
84
void clocks_enable_rx_dboard(bool enable, int divisor);
 
85
 
 
86
 
 
87
/*!
 
88
 * \brief Enable or disable clock to Tx daughterboard
 
89
 */
 
90
void clocks_enable_tx_dboard(bool enable, int divisor);
 
91
 
 
92
 
 
93
#endif /* INCLUDED_CLOCKS_H */