aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/usrp2/usrp2_regs.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp/usrp2/usrp2_regs.hpp')
-rw-r--r--host/lib/usrp/usrp2/usrp2_regs.hpp88
1 files changed, 44 insertions, 44 deletions
diff --git a/host/lib/usrp/usrp2/usrp2_regs.hpp b/host/lib/usrp/usrp2/usrp2_regs.hpp
index f26b33ecb..6fc973cdf 100644
--- a/host/lib/usrp/usrp2/usrp2_regs.hpp
+++ b/host/lib/usrp/usrp2/usrp2_regs.hpp
@@ -11,37 +11,37 @@
////////////////////////////////////////////////////////////////////////
// Define slave bases
////////////////////////////////////////////////////////////////////////
-#define ROUTER_RAM_BASE 0x4000
-#define SPI_BASE 0x5000
-#define I2C_BASE 0x5400
-#define GPIO_BASE 0x5800
-#define READBACK_BASE 0x5C00
-#define ETH_BASE 0x6000
-#define SETTING_REGS_BASE 0x7000
-#define PIC_BASE 0x8000
-#define UART_BASE 0x8800
-#define ATR_BASE 0x8C00
+#define ROUTER_RAM_BASE 0x4000
+#define SPI_BASE 0x5000
+#define I2C_BASE 0x5400
+#define GPIO_BASE 0x5800
+#define READBACK_BASE 0x5C00
+#define ETH_BASE 0x6000
+#define SETTING_REGS_BASE 0x7000
+#define PIC_BASE 0x8000
+#define UART_BASE 0x8800
+#define ATR_BASE 0x8C00
////////////////////////////////////////////////////////////////////////
// Setting register offsets
////////////////////////////////////////////////////////////////////////
-#define SR_MISC 0 // 7 regs
-#define SR_USER_REGS 8 // 2
-#define SR_TIME64 10 // 6
-#define SR_BUF_POOL 16 // 4
-#define SR_SPI_CORE 20 // 3
-#define SR_RX_FRONT 24 // 5
-#define SR_RX_CTRL0 32 // 9
-#define SR_RX_DSP0 48 // 7
-#define SR_RX_CTRL1 80 // 9
-#define SR_RX_DSP1 96 // 7
+#define SR_MISC 0 // 7 regs
+#define SR_USER_REGS 8 // 2
+#define SR_TIME64 10 // 6
+#define SR_BUF_POOL 16 // 4
+#define SR_SPI_CORE 20 // 3
+#define SR_RX_FRONT 24 // 5
+#define SR_RX_CTRL0 32 // 9
+#define SR_RX_DSP0 48 // 7
+#define SR_RX_CTRL1 80 // 9
+#define SR_RX_DSP1 96 // 7
-#define SR_TX_FRONT 128 // ?
-#define SR_TX_CTRL 144 // 6
-#define SR_TX_DSP 160 // 5
+#define SR_TX_FRONT 128 // ?
+#define SR_TX_CTRL 144 // 6
+#define SR_TX_DSP 160 // 5
-#define SR_GPIO 184
-#define SR_UDP_SM 192 // 64
+#define SR_GPIO 184
+#define SR_UDP_SM 192 // 64
#define U2_REG_SR_ADDR(sr) (SETTING_REGS_BASE + (4 * (sr)))
@@ -51,15 +51,15 @@
// SPI Slave Constants
////////////////////////////////////////////////
// Masks for controlling different peripherals
-#define SPI_SS_AD9510 1
-#define SPI_SS_AD9777 2
-#define SPI_SS_RX_DAC 4
-#define SPI_SS_RX_ADC 8
-#define SPI_SS_RX_DB 16
-#define SPI_SS_TX_DAC 32
-#define SPI_SS_TX_ADC 64
-#define SPI_SS_TX_DB 128
-#define SPI_SS_ADS62P44 256 //for usrp2p
+#define SPI_SS_AD9510 1
+#define SPI_SS_AD9777 2
+#define SPI_SS_RX_DAC 4
+#define SPI_SS_RX_ADC 8
+#define SPI_SS_RX_DB 16
+#define SPI_SS_TX_DAC 32
+#define SPI_SS_TX_ADC 64
+#define SPI_SS_TX_DB 128
+#define SPI_SS_ADS62P44 256 // for usrp2p
/////////////////////////////////////////////////
// Misc Control
@@ -77,21 +77,21 @@
#define U2_FLAG_MISC_CTRL_SERDES_ENABLE 8
#define U2_FLAG_MISC_CTRL_SERDES_PRBSEN 4
#define U2_FLAG_MISC_CTRL_SERDES_LOOPEN 2
-#define U2_FLAG_MISC_CTRL_SERDES_RXEN 1
+#define U2_FLAG_MISC_CTRL_SERDES_RXEN 1
-#define U2_FLAG_MISC_CTRL_ADC_ON 0x0F
+#define U2_FLAG_MISC_CTRL_ADC_ON 0x0F
#define U2_FLAG_MISC_CTRL_ADC_OFF 0x00
/////////////////////////////////////////////////
// Readback regs
////////////////////////////////////////////////
-#define U2_REG_STATUS READBACK_BASE + 4*8
-#define U2_REG_GPIO_RB READBACK_BASE + 4*9
-#define U2_REG_TIME64_HI_RB_IMM READBACK_BASE + 4*10
-#define U2_REG_TIME64_LO_RB_IMM READBACK_BASE + 4*11
-#define U2_REG_COMPAT_NUM_RB READBACK_BASE + 4*12
-#define U2_REG_IRQ_RB READBACK_BASE + 4*13
-#define U2_REG_TIME64_HI_RB_PPS READBACK_BASE + 4*14
-#define U2_REG_TIME64_LO_RB_PPS READBACK_BASE + 4*15
+#define U2_REG_STATUS READBACK_BASE + 4 * 8
+#define U2_REG_GPIO_RB READBACK_BASE + 4 * 9
+#define U2_REG_TIME64_HI_RB_IMM READBACK_BASE + 4 * 10
+#define U2_REG_TIME64_LO_RB_IMM READBACK_BASE + 4 * 11
+#define U2_REG_COMPAT_NUM_RB READBACK_BASE + 4 * 12
+#define U2_REG_IRQ_RB READBACK_BASE + 4 * 13
+#define U2_REG_TIME64_HI_RB_PPS READBACK_BASE + 4 * 14
+#define U2_REG_TIME64_LO_RB_PPS READBACK_BASE + 4 * 15
#endif /* INCLUDED_USRP2_REGS_HPP */