Merge pull request #14 from TitanMKD/master
SGPIO Test with CPLD passthrough mode
This commit is contained in:
10
firmware/sgpio_passthrough_rom_to_ram/Makefile
Normal file
10
firmware/sgpio_passthrough_rom_to_ram/Makefile
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
# Hey Emacs, this is a -*- makefile -*-
|
||||||
|
|
||||||
|
BINARY = sgpio_passthrough
|
||||||
|
|
||||||
|
SRC = $(BINARY).c \
|
||||||
|
../common/hackrf_core.c \
|
||||||
|
../common/si5351c.c
|
||||||
|
|
||||||
|
LDSCRIPT = ../common/LPC4330_M4_rom_to_ram.ld
|
||||||
|
include ../common/Makefile_inc.mk
|
5
firmware/sgpio_passthrough_rom_to_ram/README
Normal file
5
firmware/sgpio_passthrough_rom_to_ram/README
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
A program to test SGPIO with CPLD passthrough Input & Output via the SGPIO CPLD interface (P8 BANK2_AUX).
|
||||||
|
For this test connect P10 BANK1_AUX AUX9 pin to +1V8 (in order to have P8 BANK2_AUX AUX1 to 16 as Output).
|
||||||
|
This test requires:
|
||||||
|
* JellyBean+Lemondrop(to set clock at 204MHz).
|
||||||
|
* CPLD X2C64A hardware\jellybean\sgpio_if_passthrough\sgpio_if_passthrough.svf to be loaded first.
|
BIN
firmware/sgpio_passthrough_rom_to_ram/Test_SGPIO0_to15.ods
Normal file
BIN
firmware/sgpio_passthrough_rom_to_ram/Test_SGPIO0_to15.ods
Normal file
Binary file not shown.
BIN
firmware/sgpio_passthrough_rom_to_ram/Test_SGPIO0_to15.pdf
Normal file
BIN
firmware/sgpio_passthrough_rom_to_ram/Test_SGPIO0_to15.pdf
Normal file
Binary file not shown.
@ -0,0 +1,68 @@
|
|||||||
|
|
||||||
|
Test SGPIO GPIO mode, with LPC4330@204MHz (JellyBean+Lemondrop) and code executed in RAM.
|
||||||
|
|
||||||
|
Test1:
|
||||||
|
------
|
||||||
|
while(1)
|
||||||
|
{
|
||||||
|
for (uint_fast8_t i = 0; i < 8; i++)
|
||||||
|
{
|
||||||
|
SGPIO_GPIO_OUTREG ^= (1L << i);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Oscilloscope result (on SGPIO0): Frequency 750KHz => 272 cycles
|
||||||
|
|
||||||
|
Test2:
|
||||||
|
------
|
||||||
|
while(1)
|
||||||
|
{
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG ^= 0x5555;
|
||||||
|
}
|
||||||
|
Oscilloscope result (on SGPIO0): 3.923 MHz => 52 cycles
|
||||||
|
|
||||||
|
Test3:
|
||||||
|
------
|
||||||
|
while(1)
|
||||||
|
{
|
||||||
|
SGPIO_GPIO_OUTREG ^= 0x5555;
|
||||||
|
}
|
||||||
|
Oscilloscope result (on SGPIO0): Frequency 7.28MHz => 28 cycles
|
||||||
|
|
||||||
|
Test4:
|
||||||
|
------
|
||||||
|
while(1)
|
||||||
|
{
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG = 0x5555;
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG = 0xAAAA;
|
||||||
|
}
|
||||||
|
Oscilloscope result (on SGPIO0): Frequency 17MHz => 12 cycles
|
||||||
|
|
||||||
|
Test5:
|
||||||
|
------
|
||||||
|
while(1)
|
||||||
|
{
|
||||||
|
SGPIO_GPIO_OUTREG = 0x5555;
|
||||||
|
SGPIO_GPIO_OUTREG = 0xAAAA;
|
||||||
|
}
|
||||||
|
Oscilloscope result (on SGPIO0): Frequency 25.5MHz => 8 cycles
|
419
firmware/sgpio_passthrough_rom_to_ram/sgpio_passthrough.c
Normal file
419
firmware/sgpio_passthrough_rom_to_ram/sgpio_passthrough.c
Normal file
@ -0,0 +1,419 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2012 Michael Ossmann
|
||||||
|
* Copyright (C) 2012 Jared Boone
|
||||||
|
* Copyright (C) 2012 Benjamin Vernoux
|
||||||
|
*
|
||||||
|
* This file is part of HackRF.
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2, or (at your option)
|
||||||
|
* any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; see the file COPYING. If not, write to
|
||||||
|
* the Free Software Foundation, Inc., 51 Franklin Street,
|
||||||
|
* Boston, MA 02110-1301, USA.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <libopencm3/lpc43xx/gpio.h>
|
||||||
|
#include <libopencm3/lpc43xx/scu.h>
|
||||||
|
#include <libopencm3/lpc43xx/sgpio.h>
|
||||||
|
#include <libopencm3/lpc43xx/cgu.h>
|
||||||
|
#include <libopencm3/cm3/scs.h>
|
||||||
|
|
||||||
|
#include <hackrf_core.h>
|
||||||
|
|
||||||
|
void pin_setup(void) {
|
||||||
|
/* Configure SCU Pin Mux as GPIO */
|
||||||
|
scu_pinmux(SCU_PINMUX_LED1, SCU_GPIO_FAST);
|
||||||
|
scu_pinmux(SCU_PINMUX_LED2, SCU_GPIO_FAST);
|
||||||
|
scu_pinmux(SCU_PINMUX_LED3, SCU_GPIO_FAST);
|
||||||
|
|
||||||
|
scu_pinmux(SCU_PINMUX_EN1V8, SCU_GPIO_FAST);
|
||||||
|
|
||||||
|
/* Configure all GPIO as Input (safe state) */GPIO0_DIR = 0;
|
||||||
|
GPIO1_DIR = 0;
|
||||||
|
GPIO2_DIR = 0;
|
||||||
|
GPIO3_DIR = 0;
|
||||||
|
GPIO4_DIR = 0;
|
||||||
|
GPIO5_DIR = 0;
|
||||||
|
GPIO6_DIR = 0;
|
||||||
|
GPIO7_DIR = 0;
|
||||||
|
|
||||||
|
/* Configure GPIO2[1/2/8] (P4_1/2 P6_12) as output. */
|
||||||
|
GPIO2_DIR |= (PIN_LED1 | PIN_LED2 | PIN_LED3);
|
||||||
|
|
||||||
|
/* GPIO3[6] on P6_10 as output. */
|
||||||
|
GPIO3_DIR |= PIN_EN1V8;
|
||||||
|
|
||||||
|
/* Configure SSP1 Peripheral (to be moved later in SSP driver) */
|
||||||
|
scu_pinmux(SCU_SSP1_MISO, (SCU_SSP_IO | SCU_CONF_FUNCTION5));
|
||||||
|
scu_pinmux(SCU_SSP1_MOSI, (SCU_SSP_IO | SCU_CONF_FUNCTION5));
|
||||||
|
scu_pinmux(SCU_SSP1_SCK, (SCU_SSP_IO | SCU_CONF_FUNCTION1));
|
||||||
|
scu_pinmux(SCU_SSP1_SSEL, (SCU_SSP_IO | SCU_CONF_FUNCTION1));
|
||||||
|
}
|
||||||
|
|
||||||
|
void enable_1v8_power() {
|
||||||
|
gpio_set(PORT_EN1V8, PIN_EN1V8);
|
||||||
|
}
|
||||||
|
|
||||||
|
void release_cpld_jtag_pins() {
|
||||||
|
scu_pinmux(SCU_PINMUX_CPLD_TDO, SCU_GPIO_NOPULL | SCU_CONF_FUNCTION4);
|
||||||
|
scu_pinmux(SCU_PINMUX_CPLD_TCK, SCU_GPIO_NOPULL | SCU_CONF_FUNCTION0);
|
||||||
|
scu_pinmux(SCU_PINMUX_CPLD_TMS, SCU_GPIO_NOPULL | SCU_CONF_FUNCTION0);
|
||||||
|
scu_pinmux(SCU_PINMUX_CPLD_TDI, SCU_GPIO_NOPULL | SCU_CONF_FUNCTION0);
|
||||||
|
|
||||||
|
GPIO_DIR(PORT_CPLD_TDO) &= ~PIN_CPLD_TDO;
|
||||||
|
GPIO_DIR(PORT_CPLD_TCK) &= ~PIN_CPLD_TCK;
|
||||||
|
GPIO_DIR(PORT_CPLD_TMS) &= ~PIN_CPLD_TMS;
|
||||||
|
GPIO_DIR(PORT_CPLD_TDI) &= ~PIN_CPLD_TDI;
|
||||||
|
}
|
||||||
|
|
||||||
|
void configure_sgpio_pin_functions() {
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO0, SCU_GPIO_FAST | SCU_CONF_FUNCTION3);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO1, SCU_GPIO_FAST | SCU_CONF_FUNCTION3);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO2, SCU_GPIO_FAST | SCU_CONF_FUNCTION2);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO3, SCU_GPIO_FAST | SCU_CONF_FUNCTION2);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO4, SCU_GPIO_FAST | SCU_CONF_FUNCTION2);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO5, SCU_GPIO_FAST | SCU_CONF_FUNCTION2);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO6, SCU_GPIO_FAST | SCU_CONF_FUNCTION0);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO7, SCU_GPIO_FAST | SCU_CONF_FUNCTION6);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO8, SCU_GPIO_FAST | SCU_CONF_FUNCTION6);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO9, SCU_GPIO_FAST | SCU_CONF_FUNCTION7);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO10, SCU_GPIO_FAST | SCU_CONF_FUNCTION6);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO11, SCU_GPIO_FAST | SCU_CONF_FUNCTION6);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO12, SCU_GPIO_FAST | SCU_CONF_FUNCTION6);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO13, SCU_GPIO_FAST | SCU_CONF_FUNCTION7);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO14, SCU_GPIO_FAST | SCU_CONF_FUNCTION7);
|
||||||
|
scu_pinmux(SCU_PINMUX_SGPIO15, SCU_GPIO_FAST | SCU_CONF_FUNCTION7);
|
||||||
|
}
|
||||||
|
|
||||||
|
void test_sgpio_sliceA_D(void)
|
||||||
|
{
|
||||||
|
SGPIO_GPIO_OENREG = 0; // All inputs for the moment.
|
||||||
|
|
||||||
|
// Disable all counters during configuration
|
||||||
|
SGPIO_CTRL_ENABLE = 0;
|
||||||
|
|
||||||
|
// Configure pin functions.
|
||||||
|
configure_sgpio_pin_functions();
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Enable SGPIO pin outputs. */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_GPIO_OENREG =
|
||||||
|
0xFFFF; // data: output for SGPIO0 to SGPIO15
|
||||||
|
|
||||||
|
/*******************************************************************************/
|
||||||
|
/* SGPIO pin 0 outputs slice A bit 0. (see Table 212. Output pin multiplexing) */
|
||||||
|
/*******************************************************************************/
|
||||||
|
SGPIO_OUT_MUX_CFG(0) =
|
||||||
|
(0L << 4) | // P_OE_CFG = X
|
||||||
|
(0L << 0); // P_OUT_CFG = 0, dout_doutm1 (1-bit mode)
|
||||||
|
|
||||||
|
// SGPIO pin 12 outputs slice D bit 0. (see Table 212. Output pin multiplexing)
|
||||||
|
SGPIO_OUT_MUX_CFG(12) =
|
||||||
|
(0L << 4) | // P_OE_CFG = X
|
||||||
|
(0L << 0); // P_OUT_CFG = 0, dout_doutm1 (1-bit mode)
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Slice A */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_MUX_CFG(SGPIO_SLICE_A) =
|
||||||
|
(0L << 12) | // CONCAT_ORDER = 0 (self-loop)
|
||||||
|
(1L << 11) | // CONCAT_ENABLE = 1 (concatenate data)
|
||||||
|
(0L << 9) | // QUALIFIER_SLICE_MODE = X
|
||||||
|
(0L << 7) | // QUALIFIER_PIN_MODE = X
|
||||||
|
(0L << 5) | // QUALIFIER_MODE = 0 (enable)
|
||||||
|
(0L << 3) | // CLK_SOURCE_SLICE_MODE = 0, slice D
|
||||||
|
(0L << 1) | // CLK_SOURCE_PIN_MODE = X
|
||||||
|
(0L << 0); // EXT_CLK_ENABLE = 0, internal clock signal (slice)
|
||||||
|
|
||||||
|
SGPIO_SLICE_MUX_CFG(SGPIO_SLICE_A) =
|
||||||
|
(0L << 8) | // INV_QUALIFIER = 0 (use normal qualifier)
|
||||||
|
(0L << 6) | // PARALLEL_MODE = 0 (shift 1 bit per clock)
|
||||||
|
(0L << 4) | // DATA_CAPTURE_MODE = 0 (detect rising edge)
|
||||||
|
(0L << 3) | // INV_OUT_CLK = 0 (normal clock)
|
||||||
|
(0L << 2) | // CLKGEN_MODE = 0 (use clock from COUNTER)
|
||||||
|
(0L << 1) | // CLK_CAPTURE_MODE = 0 (use rising clock edge)
|
||||||
|
(0L << 0); // MATCH_MODE = 0 (do not match data)
|
||||||
|
|
||||||
|
SGPIO_PRESET(SGPIO_SLICE_A) = 1;
|
||||||
|
SGPIO_COUNT(SGPIO_SLICE_A) = 0;
|
||||||
|
SGPIO_POS(SGPIO_SLICE_A) = (0x1FL << 8) | (0x1FL << 0);
|
||||||
|
SGPIO_REG(SGPIO_SLICE_A) = 0xAAAAAAAA; // Primary output data register
|
||||||
|
SGPIO_REG_SS(SGPIO_SLICE_A) = 0xAAAAAAAA; // Shadow output data register
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Slice D (clock for Slice A) */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_MUX_CFG(SGPIO_SLICE_D) =
|
||||||
|
(0L << 12) | // CONCAT_ORDER = 0 (self-loop)
|
||||||
|
(1L << 11) | // CONCAT_ENABLE = 1 (concatenate data)
|
||||||
|
(0L << 9) | // QUALIFIER_SLICE_MODE = X
|
||||||
|
(0L << 7) | // QUALIFIER_PIN_MODE = X
|
||||||
|
(0L << 5) | // QUALIFIER_MODE = 0 (enable)
|
||||||
|
(0L << 3) | // CLK_SOURCE_SLICE_MODE = 0, slice D
|
||||||
|
(0L << 1) | // CLK_SOURCE_PIN_MODE = X
|
||||||
|
(0L << 0); // EXT_CLK_ENABLE = 0, internal clock signal (slice)
|
||||||
|
|
||||||
|
SGPIO_SLICE_MUX_CFG(SGPIO_SLICE_D) =
|
||||||
|
(0L << 8) | // INV_QUALIFIER = 0 (use normal qualifier)
|
||||||
|
(0L << 6) | // PARALLEL_MODE = 0 (shift 1 bit per clock)
|
||||||
|
(0L << 4) | // DATA_CAPTURE_MODE = 0 (detect rising edge)
|
||||||
|
(0L << 3) | // INV_OUT_CLK = 0 (normal clock)
|
||||||
|
(0L << 2) | // CLKGEN_MODE = 0 (use clock from COUNTER)
|
||||||
|
(0L << 1) | // CLK_CAPTURE_MODE = 0 (use rising clock edge)
|
||||||
|
(0L << 0); // MATCH_MODE = 0 (do not match data)
|
||||||
|
|
||||||
|
SGPIO_PRESET(SGPIO_SLICE_D) = 0;
|
||||||
|
SGPIO_COUNT(SGPIO_SLICE_D) = 0;
|
||||||
|
SGPIO_POS(SGPIO_SLICE_D) = (0x1FL << 8) | (0x1FL << 0);
|
||||||
|
SGPIO_REG(SGPIO_SLICE_D) = 0xAAAAAAAA; // Primary output data register
|
||||||
|
SGPIO_REG_SS(SGPIO_SLICE_D) = 0xAAAAAAAA; // Shadow output data register
|
||||||
|
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Start SGPIO operation by enabling slice clocks. */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_CTRL_ENABLE =
|
||||||
|
(1L << SGPIO_SLICE_D) | // Slice D
|
||||||
|
(1L << SGPIO_SLICE_A); // Slice A
|
||||||
|
// Start SGPIO operation by enabling slice clocks.
|
||||||
|
|
||||||
|
/*
|
||||||
|
Expected:
|
||||||
|
SGPIO12 = MCU Freq/2
|
||||||
|
SGPIO0 = SGPIO12/2 MHz= 51MHz (SliceD/2)
|
||||||
|
*/
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************/
|
||||||
|
/* Output 1bit table (see Table 212. Output pin multiplexing) */
|
||||||
|
/* SGPIO pin 00 outputs slice A bit 0. */
|
||||||
|
/* SGPIO pin 01 outputs slice I bit 0. */
|
||||||
|
/* SGPIO pin 02 outputs slice E bit 0. */
|
||||||
|
/* SGPIO pin 03 outputs slice J bit 0. */
|
||||||
|
/* SGPIO pin 04 outputs slice C bit 0. */
|
||||||
|
/* SGPIO pin 05 outputs slice K bit 0. */
|
||||||
|
/* SGPIO pin 06 outputs slice F bit 0. */
|
||||||
|
/* SGPIO pin 07 outputs slice L bit 0. */
|
||||||
|
/* SGPIO pin 08 outputs slice B bit 0. */
|
||||||
|
/* SGPIO pin 09 outputs slice M bit 0. */
|
||||||
|
/* SGPIO pin 10 outputs slice G bit 0. */
|
||||||
|
/* SGPIO pin 11 outputs slice N bit 0. */
|
||||||
|
/* SGPIO pin 12 outputs slice D bit 0. */
|
||||||
|
/* SGPIO pin 13 outputs slice O bit 0. */
|
||||||
|
/* SGPIO pin 14 outputs slice H bit 0. */
|
||||||
|
/* SGPIO pin 15 outputs slice P bit 0. */
|
||||||
|
/*******************************************************************************/
|
||||||
|
const u8 slice_preset_tab[16] =
|
||||||
|
{
|
||||||
|
0, /* Idx00 = Slice A => SGPIO0 Freq Div by 1=0 */
|
||||||
|
8, /* Idx01 = Slice B => SGPIO8 Freq Div by 9=8 */
|
||||||
|
4, /* Idx02 = Slice C => SGPIO4 Freq Div by 5=4 */
|
||||||
|
12, /* Idx03 = Slice D => SGPIO12 Freq Div by 13=12 */
|
||||||
|
2, /* Idx04 = Slice E => SGPIO2 Freq Div by 3=2 */
|
||||||
|
6, /* Idx05 = Slice F => SGPIO6 Freq Div by 7=6 */
|
||||||
|
10, /* Idx06 = Slice G => SGPIO10 Freq Div by 11=10 */
|
||||||
|
14, /* Idx07 = Slice H => SGPIO14 Freq Div by 15=14 */
|
||||||
|
1, /* Idx08 = Slice I => SGPIO1 Freq Div by 2=1 */
|
||||||
|
3, /* Idx09 = Slice J => SGPIO3 Freq Div by 4=3 */
|
||||||
|
5, /* Idx10 = Slice K => SGPIO5 Freq Div by 6=5 */
|
||||||
|
7, /* Idx11 = Slice L => SGPIO7 Freq Div by 8=7 */
|
||||||
|
9, /* Idx12 = Slice M => SGPIO9 Freq Div by 10=9 */
|
||||||
|
11, /* Idx13 = Slice N => SGPIO11 Freq Div by 12=11 */
|
||||||
|
13, /* Idx14 = Slice O => SGPIO13 Freq Div by 14=13 */
|
||||||
|
15 /* Idx15 = Slice P => SGPIO15 Freq Div by 16=15 */
|
||||||
|
};
|
||||||
|
|
||||||
|
void test_sgpio_all_slices(void)
|
||||||
|
{
|
||||||
|
|
||||||
|
SGPIO_GPIO_OENREG = 0; // All inputs for the moment.
|
||||||
|
|
||||||
|
// Disable all counters during configuration
|
||||||
|
SGPIO_CTRL_ENABLE = 0;
|
||||||
|
|
||||||
|
// Configure pin functions.
|
||||||
|
configure_sgpio_pin_functions();
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Enable SGPIO pin outputs. */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_GPIO_OENREG =
|
||||||
|
0xFFFF; // data: output for SGPIO0 to SGPIO15
|
||||||
|
|
||||||
|
for(uint_fast8_t i=0; i<16; i++)
|
||||||
|
{
|
||||||
|
SGPIO_OUT_MUX_CFG(i) =
|
||||||
|
(0L << 4) | // P_OE_CFG = X
|
||||||
|
(0L << 0); // P_OUT_CFG = 0, dout_doutm1 (1-bit mode)
|
||||||
|
}
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Slice A to P */
|
||||||
|
/****************************************************/
|
||||||
|
for(uint_fast8_t i=0; i<16; i++)
|
||||||
|
{
|
||||||
|
SGPIO_MUX_CFG(i) =
|
||||||
|
(0L << 12) | // CONCAT_ORDER = 0 (self-loop)
|
||||||
|
(1L << 11) | // CONCAT_ENABLE = 1 (concatenate data)
|
||||||
|
(0L << 9) | // QUALIFIER_SLICE_MODE = X
|
||||||
|
(0L << 7) | // QUALIFIER_PIN_MODE = X
|
||||||
|
(0L << 5) | // QUALIFIER_MODE = 0 (enable)
|
||||||
|
(0L << 3) | // CLK_SOURCE_SLICE_MODE = 0, slice D
|
||||||
|
(0L << 1) | // CLK_SOURCE_PIN_MODE = X
|
||||||
|
(0L << 0); // EXT_CLK_ENABLE = 0, internal clock signal (slice)
|
||||||
|
|
||||||
|
SGPIO_SLICE_MUX_CFG(i) =
|
||||||
|
(0L << 8) | // INV_QUALIFIER = 0 (use normal qualifier)
|
||||||
|
(0L << 6) | // PARALLEL_MODE = 0 (shift 1 bit per clock)
|
||||||
|
(0L << 4) | // DATA_CAPTURE_MODE = 0 (detect rising edge)
|
||||||
|
(0L << 3) | // INV_OUT_CLK = 0 (normal clock)
|
||||||
|
(0L << 2) | // CLKGEN_MODE = 0 (use clock from COUNTER)
|
||||||
|
(0L << 1) | // CLK_CAPTURE_MODE = 0 (use rising clock edge)
|
||||||
|
(0L << 0); // MATCH_MODE = 0 (do not match data)
|
||||||
|
|
||||||
|
SGPIO_PRESET(i) = slice_preset_tab[i];
|
||||||
|
SGPIO_COUNT(i) = 0;
|
||||||
|
SGPIO_POS(i) = (0x1FL << 8) | (0x1FL << 0);
|
||||||
|
SGPIO_REG(i) = 0xAAAAAAAA; // Primary output data register
|
||||||
|
SGPIO_REG_SS(i) = 0xAAAAAAAA; // Shadow output data register
|
||||||
|
}
|
||||||
|
|
||||||
|
/****************************************************/
|
||||||
|
/* Start SGPIO operation by enabling slice clocks. */
|
||||||
|
/****************************************************/
|
||||||
|
SGPIO_CTRL_ENABLE = 0xFFFF; /* Start all slices A to P */
|
||||||
|
/*
|
||||||
|
(1L << SGPIO_SLICE_D) | // Slice D
|
||||||
|
(1L << SGPIO_SLICE_A); // Slice A
|
||||||
|
// Start SGPIO operation by enabling slice clocks.
|
||||||
|
*/
|
||||||
|
/*
|
||||||
|
Expected:
|
||||||
|
MCU Freq MHz = 204
|
||||||
|
SGPIO Theorical Freq MHz
|
||||||
|
SGPIO00 = 102,00000
|
||||||
|
SGPIO01 = 51,00000
|
||||||
|
SGPIO02 = 34,00000
|
||||||
|
SGPIO03 = 25,50000
|
||||||
|
SGPIO04 = 20,40000
|
||||||
|
SGPIO05 = 17,00000
|
||||||
|
SGPIO06 = 14,57143
|
||||||
|
SGPIO07 = 12,75000
|
||||||
|
SGPIO08 = 11,33333
|
||||||
|
SGPIO09 = 10,20000
|
||||||
|
SGPIO10 = 9,27273
|
||||||
|
SGPIO11 = 8,50000
|
||||||
|
SGPIO12 = 7,84615
|
||||||
|
SGPIO13 = 7,28571
|
||||||
|
SGPIO14 = 6,80000
|
||||||
|
SGPIO15 = 6,37500
|
||||||
|
TitanMKD: I have problems with my boards and this test see document Test_SGPIO0_to15.ods / Test_SGPIO0_to15.pdf
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
|
||||||
|
void test_sgpio_interface(void)
|
||||||
|
{
|
||||||
|
SGPIO_GPIO_OENREG = 0; // All inputs for the moment.
|
||||||
|
|
||||||
|
// Disable all counters during configuration
|
||||||
|
SGPIO_CTRL_ENABLE = 0;
|
||||||
|
|
||||||
|
configure_sgpio_pin_functions();
|
||||||
|
|
||||||
|
// Make all SGPIO controlled by SGPIO's "GPIO" registers
|
||||||
|
for (uint_fast8_t i = 0; i < 16; i++) {
|
||||||
|
SGPIO_OUT_MUX_CFG(i) = (0L << 4) | (4L << 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Enable SGPIO pin outputs (SGPIO0 to 15).
|
||||||
|
SGPIO_GPIO_OENREG = 0xFFFF;
|
||||||
|
|
||||||
|
/* Set values for SGPIO0 to 15 */
|
||||||
|
while (1)
|
||||||
|
{
|
||||||
|
// 750KHz => 272 cycles
|
||||||
|
/*
|
||||||
|
for (uint_fast8_t i = 0; i < 8; i++) {
|
||||||
|
SGPIO_GPIO_OUTREG ^= (1L << i);
|
||||||
|
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
|
// 3.923 MHz => 52 cycles
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG ^= 0x5555;
|
||||||
|
|
||||||
|
// 7.28 MHz => 28 cycles
|
||||||
|
/*
|
||||||
|
SGPIO_GPIO_OUTREG ^= 0x5555;
|
||||||
|
*/
|
||||||
|
|
||||||
|
// 17 MHz => 12 cycles
|
||||||
|
/*
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG = 0x5555;
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
__asm__(" nop");
|
||||||
|
SGPIO_GPIO_OUTREG = 0xAAAA;
|
||||||
|
*/
|
||||||
|
// 25.50 MHz => 8 cycles
|
||||||
|
/*
|
||||||
|
SGPIO_GPIO_OUTREG = 0x5555;
|
||||||
|
SGPIO_GPIO_OUTREG = 0xAAAA;
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
|
||||||
|
/* TitanMKD: I have problems with my board with this test (see test_sgpio_all_slices()) */
|
||||||
|
}
|
||||||
|
|
||||||
|
int main(void)
|
||||||
|
{
|
||||||
|
pin_setup();
|
||||||
|
enable_1v8_power();
|
||||||
|
cpu_clock_init();
|
||||||
|
ssp1_init();
|
||||||
|
|
||||||
|
CGU_BASE_PERIPH_CLK = (CGU_BASE_CLK_AUTOBLOCK
|
||||||
|
| (CGU_SRC_PLL1 << CGU_BASE_CLK_SEL_SHIFT));
|
||||||
|
|
||||||
|
CGU_BASE_APB1_CLK = (CGU_BASE_CLK_AUTOBLOCK
|
||||||
|
| (CGU_SRC_PLL1 << CGU_BASE_CLK_SEL_SHIFT));
|
||||||
|
|
||||||
|
gpio_set(PORT_LED1_3, PIN_LED1);
|
||||||
|
|
||||||
|
//test_sgpio_sliceA_D();
|
||||||
|
test_sgpio_interface();
|
||||||
|
//test_sgpio_all_slices();
|
||||||
|
|
||||||
|
while(1);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
BIN
hardware/jellybean/JellyBean_pins.png
Normal file
BIN
hardware/jellybean/JellyBean_pins.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 MiB |
BIN
hardware/jellybean/jellybean_board_PCB_layers.pdf
Normal file
BIN
hardware/jellybean/jellybean_board_PCB_layers.pdf
Normal file
Binary file not shown.
BIN
hardware/jellybean/jellybean_schematic.pdf
Normal file
BIN
hardware/jellybean/jellybean_schematic.pdf
Normal file
Binary file not shown.
33
hardware/jellybean/sgpio_if_passthrough/README.md
Normal file
33
hardware/jellybean/sgpio_if_passthrough/README.md
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
|
||||||
|
CPLD interface to expose LPC43xx microcontroller SGPIO peripheral, either
|
||||||
|
as all inputs or all outputs.
|
||||||
|
|
||||||
|
Requirements
|
||||||
|
============
|
||||||
|
|
||||||
|
To build this VHDL project and produce an SVF file for flashing the CPLD:
|
||||||
|
|
||||||
|
* Xilinx WebPACK 13.4 for Windows or Linux.
|
||||||
|
|
||||||
|
* BSDL model files for Xilinx CoolRunner-II XC264A, available at xilinx.com,
|
||||||
|
in the "Device Models" Support Resources section of the CoolRunner-II
|
||||||
|
Product Support & Documentation page. Only one file from the BSDL package is
|
||||||
|
required, and the "program" script below expects it to be at the relative
|
||||||
|
path "bsdl/xc2c/xc2c64.bsd".
|
||||||
|
|
||||||
|
To program the SVF file into the CPLD:
|
||||||
|
|
||||||
|
* Dangerous Prototypes Bus Blaster v2:
|
||||||
|
* Configured with JTAGKey buffers.
|
||||||
|
* Connected to CPLD JTAG signals on Jellybean.
|
||||||
|
|
||||||
|
* urJTAG built with libftdi support.
|
||||||
|
|
||||||
|
To Program
|
||||||
|
==========
|
||||||
|
|
||||||
|
./program
|
||||||
|
|
||||||
|
...which connects to the Bus Blaster interface 0, sets the BSDL directory,
|
||||||
|
detects devices on the JTAG chain, and writes the sgpio_if_passthrough.svf
|
||||||
|
file to the CPLD.
|
10
hardware/jellybean/sgpio_if_passthrough/program
Executable file
10
hardware/jellybean/sgpio_if_passthrough/program
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
echo Program Xilinx CoolRunner-II CPLD on Jellybean, using Bus Blaster v2
|
||||||
|
|
||||||
|
jtag <<COMMANDSEND
|
||||||
|
cable jtagkey vid=0x0403 pid=0x6010 interface=0 driver=ftdi-mpsse
|
||||||
|
bsdl path bsdl/xc2c
|
||||||
|
detect
|
||||||
|
svf sgpio_if_passthrough.svf progress stop
|
||||||
|
COMMANDSEND
|
2079
hardware/jellybean/sgpio_if_passthrough/sgpio_if_passthrough.svf
Executable file
2079
hardware/jellybean/sgpio_if_passthrough/sgpio_if_passthrough.svf
Executable file
File diff suppressed because it is too large
Load Diff
242
hardware/jellybean/sgpio_if_passthrough/sgpio_if_passthrough.xise
Executable file
242
hardware/jellybean/sgpio_if_passthrough/sgpio_if_passthrough.xise
Executable file
@ -0,0 +1,242 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
|
||||||
|
<project xmlns="http://www.xilinx.com/XMLSchema" xmlns:xil_pn="http://www.xilinx.com/XMLSchema">
|
||||||
|
|
||||||
|
<header>
|
||||||
|
<!-- ISE source project file created by Project Navigator. -->
|
||||||
|
<!-- -->
|
||||||
|
<!-- This file contains project source information including a list of -->
|
||||||
|
<!-- project source files, project and process properties. This file, -->
|
||||||
|
<!-- along with the project source files, is sufficient to open and -->
|
||||||
|
<!-- implement in ISE Project Navigator. -->
|
||||||
|
<!-- -->
|
||||||
|
<!-- Copyright (c) 1995-2011 Xilinx, Inc. All rights reserved. -->
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<version xil_pn:ise_version="13.4" xil_pn:schema_version="2"/>
|
||||||
|
|
||||||
|
<files>
|
||||||
|
<file xil_pn:name="top.vhd" xil_pn:type="FILE_VHDL">
|
||||||
|
<association xil_pn:name="BehavioralSimulation" xil_pn:seqID="1"/>
|
||||||
|
<association xil_pn:name="Implementation" xil_pn:seqID="1"/>
|
||||||
|
</file>
|
||||||
|
<file xil_pn:name="top.ucf" xil_pn:type="FILE_UCF">
|
||||||
|
<association xil_pn:name="Implementation" xil_pn:seqID="0"/>
|
||||||
|
</file>
|
||||||
|
</files>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<property xil_pn:name="Add I/O Buffers" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Allow Unmatched LOC Constraints" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Allow Unmatched Timing Group Constraints" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Analysis Effort Level" xil_pn:value="Standard" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Auto Implementation Compile Order" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Auto Implementation Top" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Automatically Insert glbl Module in the Netlist" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Bring Out Global Set/Reset Net as a Port" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Bring Out Global Tristate Net as a Port" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Bus Delimiter" xil_pn:value="<>" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Case" xil_pn:value="Maintain" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Case Implementation Style" xil_pn:value="None" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Clock Enable" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Collapsing Input Limit (4-40)" xil_pn:value="32" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Collapsing Pterm Limit (3-56)" xil_pn:value="28" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Compile CPLD Simulation Library" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Compile SIMPRIM (Timing) Simulation Library" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Compile UNISIM (Functional) Simulation Library" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Compile for HDL Debugging" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Compile uni9000 (Functional) Simulation Library" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Create IEEE 1532 Configuration File" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Custom Waveform Configuration File Behav" xil_pn:value="Default.wcfg" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Default Powerup Value of Registers" xil_pn:value="Low" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Delay Values To Be Read from SDF" xil_pn:value="Setup Time" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Device" xil_pn:value="xc2c64a" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Device Family" xil_pn:value="CoolRunner2 CPLDs" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Device Speed Grade/Select ABS Minimum" xil_pn:value="-7" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Do Not Escape Signal and Instance Names in Netlist" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Enable Hardware Co-Simulation" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Enable Message Filtering" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Equivalent Register Removal XST" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Evaluation Development Board" xil_pn:value="None Specified" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Exhaustive Fit Mode" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="FSM Encoding Algorithm" xil_pn:value="Auto" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Filter Files From Compile Order" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Function Block Input Limit (4-40)" xil_pn:value="38" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Functional Model Target Language ArchWiz" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Functional Model Target Language Coregen" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Functional Model Target Language Schematic" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate Architecture Only (No Entity Declaration)" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate Multiple Hierarchical Netlist Files" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate Post-Fit Power Data" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate Post-Fit Simulation Model" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate RTL Schematic" xil_pn:value="Yes" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate SAIF File for Power Optimization/Estimation Par" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generate Testbench File" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Generics, Parameters" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Global Set/Reset Port Name" xil_pn:value="GSR_PORT" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Global Tristate Port Name" xil_pn:value="GTS_PORT" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="HDL Equations Style" xil_pn:value="Source" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Hierarchy Separator" xil_pn:value="/" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="I/O Voltage Standard" xil_pn:value="LVCMOS18" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="ISim UUT Instance Name" xil_pn:value="UUT" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Implementation Template" xil_pn:value="Optimize Density" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Implementation Top" xil_pn:value="Architecture|top|Behavioral" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Implementation Top File" xil_pn:value="top.vhd" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Implementation Top Instance Path" xil_pn:value="/top" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Include 'uselib Directive in Verilog File" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Include SIMPRIM Models in Verilog File" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Include UNISIM Models in Verilog File" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Include sdf_annotate task in Verilog File" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Incremental Compilation" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Input and tristate I/O Termination Mode" xil_pn:value="Keeper" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Insert Buffers to Prevent Pulse Swallowing" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Instantiation Template Target Language Xps" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Keep Hierarchy" xil_pn:value="No" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Keep Hierarchy CPLD" xil_pn:value="Yes" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Language" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Last Applied Goal" xil_pn:value="Balanced" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Last Applied Strategy" xil_pn:value="Xilinx Default (unlocked)" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Last Unlock Status" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Launch SDK after Export" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Library for Verilog Sources" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Load glbl" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Logic Optimization" xil_pn:value="Density" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Macro Preserve" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Manual Implementation Compile Order" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Max Fanout" xil_pn:value="100000" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Maximum Number of Lines in Report" xil_pn:value="1000" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Maximum Signal Name Length" xil_pn:value="20" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Mux Extraction" xil_pn:value="Yes" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Netlist Hierarchy" xil_pn:value="As Optimized" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Number of Clock Buffers" xil_pn:value="4" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Optimization Effort" xil_pn:value="Normal" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Optimization Goal" xil_pn:value="Speed" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other CPLD Fitter Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compiler Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compiler Options Fit" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compiler Options Map" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compiler Options Par" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compiler Options Translate" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Compxlib Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other NETGEN Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Ngdbuild Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Programming Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Simulator Commands Behavioral" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Simulator Commands Fit" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other Timing Report Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other XPWR Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Other XST Command Line Options" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Output Extended Identifiers" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Output File Name" xil_pn:value="top" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Output Slew Rate" xil_pn:value="Fast" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Overwrite Compiled Libraries" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Package" xil_pn:value="VQ100" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Port to be used" xil_pn:value="Auto - default" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Post Map Simulation Model Name" xil_pn:value="top_map.vhd" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Post Place & Route Simulation Model Name" xil_pn:value="top_timesim.vhd" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Post Synthesis Simulation Model Name" xil_pn:value="top_synthesis.vhd" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Post Translate Simulation Model Name" xil_pn:value="top_translate.vhd" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Preferred Language" xil_pn:value="VHDL" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Preserve Unused Inputs" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Produce Verbose Report" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Project Description" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Property Specification in Project File" xil_pn:value="Store all values" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Regenerate Core" xil_pn:value="Under Current Project Setting" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Rename Design Instance in Testbench File to" xil_pn:value="UUT" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Rename Top Level Architecture To" xil_pn:value="Structure" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Rename Top Level Entity to" xil_pn:value="top" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Rename Top Level Module To" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Reset On Configuration Pulse Width" xil_pn:value="100" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Resource Sharing" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Retain Hierarchy" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Run for Specified Time" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Run for Specified Time Map" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Run for Specified Time Par" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Run for Specified Time Translate" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Safe Implementation" xil_pn:value="No" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Selected Module Instance Name" xil_pn:value="/top_tb" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Selected Simulation Root Source Node Behavioral" xil_pn:value="work.top_tb" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Selected Simulation Root Source Node Post-Map" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Selected Simulation Root Source Node Post-Route" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Selected Simulation Root Source Node Post-Translate" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Selected Simulation Source Node" xil_pn:value="UUT" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Show All Models" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulation Model Target" xil_pn:value="VHDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulation Run Time ISim" xil_pn:value="1000 ns" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulation Run Time Map" xil_pn:value="1000 ns" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulation Run Time Par" xil_pn:value="1000 ns" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulation Run Time Translate" xil_pn:value="1000 ns" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Simulator" xil_pn:value="ISim (VHDL/Verilog)" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Specify 'define Macro Name and Value" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Specify Top Level Instance Names Behavioral" xil_pn:value="work.top_tb" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Specify Top Level Instance Names Fit" xil_pn:value="Default" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Speed Grade" xil_pn:value="-7" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Synthesis Tool" xil_pn:value="XST (VHDL/Verilog)" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Target Simulator" xil_pn:value="Please Specify" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Target UCF File Name" xil_pn:value="top.ucf" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Timing Report Format" xil_pn:value="Summary" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Top-Level Source Type" xil_pn:value="HDL" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Tristate On Configuration Pulse Width" xil_pn:value="0" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Unused I/O Pad Termination Mode" xil_pn:value="Keeper" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use 64-bit PlanAhead on 64-bit Systems" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Project File Behavioral" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Project File Fit" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Simulation Command File Behavioral" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Simulation Command File Map" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Simulation Command File Par" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Simulation Command File Translate" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Waveform Configuration File Behav" xil_pn:value="true" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="Use Custom Waveform Configuration File Fit" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Waveform Configuration File Map" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Waveform Configuration File Par" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Custom Waveform Configuration File Translate" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Data Gate" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Direct Input for Input Registers" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Global Clocks" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Global Output Enables" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Global Set/Reset" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Location Constraints" xil_pn:value="Always" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Multi-level Logic Optimization" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Smart Guide" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Synthesis Constraints File" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Use Timing Constraints" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="User Browsed Strategy Files" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="VHDL Source Analysis Standard" xil_pn:value="VHDL-93" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Value Range Check" xil_pn:value="false" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Verilog 2001 Xst" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Verilog Macros" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="WYSIWYG" xil_pn:value="None" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="Working Directory" xil_pn:value="." xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="XOR Preserve" xil_pn:value="true" xil_pn:valueState="default"/>
|
||||||
|
<!-- -->
|
||||||
|
<!-- The following properties are for internal use only. These should not be modified.-->
|
||||||
|
<!-- -->
|
||||||
|
<property xil_pn:name="PROP_BehavioralSimTop" xil_pn:value="Architecture|top_tb|behavior" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="PROP_DesignName" xil_pn:value="sgpio_test" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="PROP_DevFamilyPMName" xil_pn:value="xbr" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_FPGAConfiguration" xil_pn:value="FPGAConfiguration" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PostFitSimTop" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PostMapSimTop" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PostParSimTop" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PostSynthSimTop" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PostXlateSimTop" xil_pn:value="" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_PreSynthesis" xil_pn:value="PreSynthesis" xil_pn:valueState="default"/>
|
||||||
|
<property xil_pn:name="PROP_intProjectCreationTimestamp" xil_pn:value="2012-04-29T12:49:49" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="PROP_intWbtProjectID" xil_pn:value="8998E598855F452AB5BAE34A005D4FD5" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="PROP_intWorkingDirLocWRTProjDir" xil_pn:value="Same" xil_pn:valueState="non-default"/>
|
||||||
|
<property xil_pn:name="PROP_intWorkingDirUsed" xil_pn:value="No" xil_pn:valueState="non-default"/>
|
||||||
|
</properties>
|
||||||
|
|
||||||
|
<bindings/>
|
||||||
|
|
||||||
|
<libraries/>
|
||||||
|
|
||||||
|
<autoManagedFiles>
|
||||||
|
<!-- The following files are identified by `include statements in verilog -->
|
||||||
|
<!-- source files and are automatically managed by Project Navigator. -->
|
||||||
|
<!-- -->
|
||||||
|
<!-- Do not hand-edit this section, as it will be overwritten when the -->
|
||||||
|
<!-- project is analyzed based on files automatically identified as -->
|
||||||
|
<!-- include files. -->
|
||||||
|
</autoManagedFiles>
|
||||||
|
|
||||||
|
</project>
|
89
hardware/jellybean/sgpio_if_passthrough/top.ucf
Executable file
89
hardware/jellybean/sgpio_if_passthrough/top.ucf
Executable file
@ -0,0 +1,89 @@
|
|||||||
|
#
|
||||||
|
# Copyright 2012 Jared Boone
|
||||||
|
#
|
||||||
|
# This file is part of HackRF.
|
||||||
|
#
|
||||||
|
# This program is free software; you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation; either version 2, or (at your option)
|
||||||
|
# any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; see the file COPYING. If not, write to
|
||||||
|
# the Free Software Foundation, Inc., 51 Franklin Street,
|
||||||
|
# Boston, MA 02110-1301, USA.
|
||||||
|
|
||||||
|
NET "CODEC_CLK" LOC="23" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "CODEC_X2_CLK" LOC="27" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
#NET "GCLK0" LOC="22" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
|
||||||
|
NET "CODEC_X2_CLK" TNM_NET = CODEC_X2_CLK;
|
||||||
|
TIMESPEC TS_codec_x2_data = PERIOD "CODEC_X2_CLK" 50 ns;
|
||||||
|
|
||||||
|
NET "DA<7>" LOC="35" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<6>" LOC="36" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<5>" LOC="37" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<4>" LOC="39" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<3>" LOC="40" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<2>" LOC="41" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<1>" LOC="42" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DA<0>" LOC="43" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
|
||||||
|
NET "DD<9>" LOC="17" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<8>" LOC="18" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<7>" LOC="19" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<6>" LOC="24" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<5>" LOC="28" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<4>" LOC="29" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<3>" LOC="30" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<2>" LOC="32" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<1>" LOC="33" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "DD<0>" LOC="34" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
|
||||||
|
NET "B1AUX<16>" LOC="60" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<15>" LOC="58" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<14>" LOC="56" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<13>" LOC="55" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<12>" LOC="53" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<11>" LOC="52" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<10>" LOC="50" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
NET "B1AUX<9>" LOC="49" |FAST |IOSTANDARD=LVCMOS18;
|
||||||
|
|
||||||
|
NET "SGPIO<15>" LOC="78" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<14>" LOC="81" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<13>" LOC="90" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<12>" LOC="70" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<11>" LOC="71" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<10>" LOC="76" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<9>" LOC="91" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<8>" LOC="68" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<7>" LOC="77" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<6>" LOC="61" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<5>" LOC="64" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<4>" LOC="67" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<3>" LOC="72" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<2>" LOC="74" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<1>" LOC="79" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "SGPIO<0>" LOC="89" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
|
||||||
|
NET "B2AUX<16>" LOC="92" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<15>" LOC="94" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<14>" LOC="97" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<13>" LOC="99" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<12>" LOC="1" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<11>" LOC="2" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<10>" LOC="3" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<9>" LOC="4" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<8>" LOC="6" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<7>" LOC="7" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<6>" LOC="8" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<5>" LOC="9" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<4>" LOC="10" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<3>" LOC="11" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<2>" LOC="12" |FAST |IOSTANDARD=LVCMOS33;
|
||||||
|
NET "B2AUX<1>" LOC="13" |FAST |IOSTANDARD=LVCMOS33;
|
60
hardware/jellybean/sgpio_if_passthrough/top.vhd
Executable file
60
hardware/jellybean/sgpio_if_passthrough/top.vhd
Executable file
@ -0,0 +1,60 @@
|
|||||||
|
--
|
||||||
|
-- Copyright 2012 Jared Boone
|
||||||
|
--
|
||||||
|
-- This file is part of HackRF.
|
||||||
|
--
|
||||||
|
-- This program is free software; you can redistribute it and/or modify
|
||||||
|
-- it under the terms of the GNU General Public License as published by
|
||||||
|
-- the Free Software Foundation; either version 2, or (at your option)
|
||||||
|
-- any later version.
|
||||||
|
--
|
||||||
|
-- This program is distributed in the hope that it will be useful,
|
||||||
|
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
-- GNU General Public License for more details.
|
||||||
|
--
|
||||||
|
-- You should have received a copy of the GNU General Public License
|
||||||
|
-- along with this program; see the file COPYING. If not, write to
|
||||||
|
-- the Free Software Foundation, Inc., 51 Franklin Street,
|
||||||
|
-- Boston, MA 02110-1301, USA.
|
||||||
|
|
||||||
|
library IEEE;
|
||||||
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
|
|
||||||
|
library UNISIM;
|
||||||
|
use UNISIM.vcomponents.all;
|
||||||
|
|
||||||
|
entity top is
|
||||||
|
Port(
|
||||||
|
SGPIO : inout std_logic_vector(15 downto 0);
|
||||||
|
|
||||||
|
DA : in std_logic_vector(7 downto 0);
|
||||||
|
DD : out std_logic_vector(9 downto 0);
|
||||||
|
|
||||||
|
CODEC_CLK : in std_logic;
|
||||||
|
CODEC_X2_CLK : in std_logic;
|
||||||
|
|
||||||
|
B1AUX : in std_logic_vector(16 downto 9);
|
||||||
|
B2AUX : inout std_logic_vector(16 downto 1)
|
||||||
|
);
|
||||||
|
|
||||||
|
end top;
|
||||||
|
|
||||||
|
architecture Behavioral of top is
|
||||||
|
type transfer_direction is (to_sgpio, from_sgpio);
|
||||||
|
signal transfer_direction_i : transfer_direction;
|
||||||
|
|
||||||
|
begin
|
||||||
|
|
||||||
|
transfer_direction_i <= to_sgpio when B1AUX(9) = '0'
|
||||||
|
else from_sgpio;
|
||||||
|
|
||||||
|
DD <= (DD'high => '1', others => '0');
|
||||||
|
|
||||||
|
B2AUX <= SGPIO when transfer_direction_i = from_sgpio
|
||||||
|
else (others => 'Z');
|
||||||
|
|
||||||
|
SGPIO <= B2AUX when transfer_direction_i = to_sgpio
|
||||||
|
else (others => 'Z');
|
||||||
|
|
||||||
|
end Behavioral;
|
Reference in New Issue
Block a user