|
Вопрос по XC95288, Не до конца понимаю в чем проблема. |
|
|
|
Feb 12 2012, 12:31
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
Есть XC95288, (15,10ns). Пробую написать прошивку для нее. Поведенческие тесты проходят, но Post-Fit обламывается. Есть сигнал на частоте 50MHz, он поступает на ПЛИС, но при такой частоте сигналы не устанавливаются. (переходят в состояние Х) даже на простом делителе. Вот как это выглядит. При чем тактовые импульсы выходят так как надо.  Понимаю что этот сигнал становится тактовым но вот почему он не устанавливается пока не понимаю. Спасибо. Проблема видимо в задержках...
Сообщение отредактировал h0t - Feb 12 2012, 12:50
|
|
|
|
|
Feb 15 2012, 11:27
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
Цитата(Kuzmi4 @ Feb 12 2012, 20:15)  2 h0t тут нужен как минимум UCF и временной репорт из ISE UCF'а нет, а кусок репорта: Цитата Timing Report Generator: version O.40d Copyright © 1995-2011 Xilinx, Inc. All rights reserved.
Design file: main_schematic Device,speed: XC95288,-15 (3.0) Report level: verbose report --------------------------------------------------------------------------------
Note: A default set of constraints using a delay of 0.000ns will be used for analysis.
================================================================================ Timing constraint: TS1000: PERIOD:PERIOD_SCK:0.000 nS
0 items analyzed, 0 timing errors detected. Maximum delay is 0.000ns. --------------------------------------------------------------------------------
================================================================================ Timing constraint: AUTO_TS_F2F: MAXDELAY:FROM:FFS(*):TO:FFS(*):0.000 nS
6060 items analyzed, 6060 timing errors detected. Maximum delay is 0.000ns. -------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<0>.Q Destination: XLXI_4/CntRX<1>.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<0>.Q to XLXI_4/CntRX<1>.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<0>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/CntRX<1>.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<0>.Q Destination: XLXI_4/current_bit.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<0>.Q to XLXI_4/current_bit.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<0>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/current_bit.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<0>.Q Destination: XLXI_4/prevRXD.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<0>.Q to XLXI_4/prevRXD.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<0>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/prevRXD.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<1>.Q Destination: XLXI_4/CntRX<1>.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<1>.Q to XLXI_4/CntRX<1>.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<1>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/CntRX<1>.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<1>.Q Destination: XLXI_4/current_bit.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<1>.Q to XLXI_4/current_bit.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<1>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/current_bit.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<1>.Q Destination: XLXI_4/prevRXD.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<1>.Q to XLXI_4/prevRXD.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<1>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/prevRXD.D ---------------------------- ---------------------------
-------------------------------------------------------------------------------- Slack: -10.500ns (requirement - data path) Source: XLXI_4/CntRX<2>.Q Destination: XLXI_4/current_bit.D Requirement: 0.000ns Data Path Delay: 10.500ns (Levels of Logic = 3)
Data Path: XLXI_4/CntRX<2>.Q to XLXI_4/current_bit.D Delay type Delay(ns) Logical Resource(s) ---------------------------- ------------------- tCOI 0.500 XLXI_4/CntRX<2>.FBK tLF + tLOGI + tSUI 10.000 XLXI_4/current_bit.D ---------------------------- ---------------------------
--------------------------------------------------------------------------------
|
|
|
|
|
Feb 15 2012, 16:36
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
и с UCF пробывал. Сделал следующие - некое подобие UART'a только с переменной длиной посылки (дали на реализацию, протокол - жуть). Длина посылки может быть вычислена из поля в пакете. Еще при сборке высыпается такое сообщение Цитата WARNING:Cpld:158 - We have detected that a large number of internal signals may be switching at the same time. To avoid potential simultaneous switching/ground bounce issues, please contact Xilinx customer support for more information. проблема вот в этом куске Цитата elsif (RxBitCnt=MaxDataBit) then .....
MaxDataBit <= to_integer(unsigned(to_stdLogicVector(RxBuf(11 downto 6))))+13+2; Т.е. если количество бит фиксировано то все хорошо, если нет то вылазит 3е состояние.
|
|
|
|
|
Feb 16 2012, 12:09
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
Смотрите есть модуль применик имеет такой код Код library IEEE; use IEEE.STD_LOGIC_1164.ALL; use ieee.numeric_std.all;
-- Uncomment the following library declaration if using -- arithmetic functions with Signed or Unsigned values --use IEEE.NUMERIC_STD.ALL;
-- Uncomment the following library declaration if instantiating -- any Xilinx primitives in this code. --library UNISIM; --use UNISIM.VComponents.all;
entity RS422_receiver is Port ( SCK : in STD_LOGIC; RXD : in STD_LOGIC; DATA : out STD_LOGIC_VECTOR (6 downto 0); RX_READY : out STD_LOGIC); end RS422_receiver;
architecture Behavioral of RS422_receiver is constant MAX_BIT_OUT : integer := 26; --максимальный размер посылки constant DATA_COUNT : integer := 5; constant DATA_SIZE : integer := 6;
signal RxBuf: bit_vector(DATA_SIZE downto 0); -- вектор для приема signal prevRXD: Std_Logic; -- предыдущие состояние RXD (необходимо, что-бы отлавливать стартовый бит) signal OutRxReady: Std_Logic; --внешний сигнал готовности приемника
signal CntRX : integer range 0 to DATA_COUNT; signal RxBitCnt: integer range 0 to MAX_BIT_OUT; signal RxReady: std_logic;
begin process(SCK) variable high_count: integer range 0 to DATA_COUNT; variable current_bit: bit :='0'; begin --внутренний сигнал готовности приемника if (rising_edge(SCK)) then if (RxReady = '1' or RxReady = 'U' ) then prevRXD <= RXD; if (RXD='0' and prevRXD='1') then -- Start bit, RxBitCnt <=0; -- RX Bit counter RxBuf<=(others=>'0'); CntRX <= 1; prevRXD <= '0'; RxReady <= '0'; -- Start receiving --OutRxReady <= '0'; end if; else if (RXD = '1') then high_count := high_count + 1; end if; CntRX <=CntRX+1; if CntRX=DATA_COUNT-1 then if (high_count<3) then current_bit := '0'; else current_bit := '1'; end if; high_count := 0; if (RxBitCnt = 0) then RX_READY<='0'; if (current_bit = '1') then RxBuf <= (others=>'0'); RxReady <= '1'; end if; elsif (RxBitCnt=MAX_BIT_OUT-1) then if (current_bit = '0') then RxBuf <= (others=>'0'); RxReady <= '1'; prevRXD <= RXD; else RxReady <= '1'; prevRXD <= RXD; --OutRxReady <= '1'; DATA(DATA_SIZE downto 0)<= to_stdlogicvector(RxBuf(DATA_SIZE downto 0)); RX_READY<='1'; end if; elsif (RxBitCnt=MAX_BIT_OUT-2 ) then if (current_bit = '1') then RxBuf <= (others=>'0'); RxReady <= '1'; prevRXD <= RXD; end if; else if (RxBitCnt<8) then RxBuf<= current_bit & RxBuf (DATA_SIZE downto 1) ;--- & RxBuf(MAX_BIT_OUT downto 1); end if; end if; CntRX<= 0; RxBitCnt <= RxBitCnt+1; end if; end if; end if; end process;
end Behavioral; Этот модуль подключается к такому модулю: Код library IEEE; use IEEE.STD_LOGIC_1164.ALL; use ieee.numeric_std.all; use IEEE.STD_LOGIC_ARITH.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; -- Uncomment the following library declaration if using -- arithmetic functions with Signed or Unsigned values --use IEEE.NUMERIC_STD.ALL;
-- Uncomment the following library declaration if instantiating -- any Xilinx primitives in this code. --library UNISIM; --use UNISIM.VComponents.all;
entity Control_radiation is Port ( DATA : in STD_LOGIC_VECTOR (6 downto 0); DATA_READY : in STD_LOGIC; signal_2 : out STD_LOGIC); end Control_radiation;
architecture Behavioral of Control_radiation is constant MAX_BIT_OUT : integer := 6; --максимальный размер посылки constant CHANNEL_SIZE : integer := 64;
signal signal2 : STD_LOGIC;
begin process (DATA_READY) variable read_data : bit_vector (MAX_BIT_OUT downto 0); variable channel : integer; variable i: integer; variable ChannelOn: bit_vector(CHANNEL_SIZE-1 downto 0):=(others=>'0'); -- вектор для приема begin if (rising_edge(DATA_READY)) then read_data := to_bitvector(DATA); channel := conv_integer(to_stdLogicVector(read_data(5 downto 0))); ChannelOn(channel) := read_data(6); if ( conv_integer(to_stdLogicVector(ChannelOn(31 downto 0))) = 0 and conv_integer(to_stdLogicVector(ChannelOn(63 downto 32))) = 0 ) then signal2 <= '0'; else signal2 <= '1'; end if; end if; end process; signal_2<='1' when signal2 = '1' else '0';
end Behavioral; И при post-fit'e второй модуль не устанавливает сигналы(
|
|
|
|
|
Feb 16 2012, 15:16
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
Цитата(Kuzmi4 @ Feb 16 2012, 18:59)  2 h0t собрал ваш RS422_receiver - после Fit выдало что Max. Clock Frequency около 45 MHz и выше никак. В принципе, страшного криминала Synplify не заметил в коде да и ISE повёл себе более менее адекватно. Так что, исходя из того что я понял, я думаю вам стоит попробовать в тестбенче попробовать опустить частоту с 50MHz до 40MHz и попробовать Post-Fit ещё раз. Да вот в том-то и дело что задание поставлено на 50MHz и не MHz ом меньше. Вы глобальные клоки устанавливали? А если попробовать что-нибудь с ucf придумать? Возможно ли выжать 50? Хоть копать в какую сторону? Цитата Minimum clock period is 68.000ns (14.706 MHz). Limited by Cycle Time for CLK. Maximum clock speed computed based upon tCYC assumes that all registers are rising-edge sensitive. У меня только min выводит, Вы где это смотрите? Спаибо большое за помощь! P.S. попробовал период в 40 ns все равно что-то не срабатывает... P.S.1. еще пробывал только только приемник тестить в post-fit'e и он на 50 MHz работает вроде как..
Сообщение отредактировал h0t - Feb 17 2012, 06:50
|
|
|
|
|
Feb 17 2012, 08:43
|
Гуру
     
Группа: Свой
Сообщений: 3 123
Регистрация: 7-04-07
Из: Химки
Пользователь №: 26 847

|
Цитата Хоть копать в какую сторону? В сторону изменения схемы. У вас там куча счетчиков и логики, надо уменьшать Цитата У меня только min выводит Это min период, оно же max частота - 14.706 MHz До 50 MHz одними ucf явно не поднять У вас SCK идет постоянно? Если да, то можно попробовать сделать регистр между приемником и Control_radiation (протактировать его SCK). Должно помочь
|
|
|
|
|
Feb 17 2012, 12:33
|
Участник

Группа: Участник
Сообщений: 51
Регистрация: 23-09-11
Пользователь №: 67 345

|
Имею в итоге следующие: Цитата -------------------------------------------------------------------------------- Timing Report Generator: version O.40d Copyright © 1995-2011 Xilinx, Inc. All rights reserved.
Design file: main_schematic Device,speed: XC95288,-15 (3.0) Report level: verbose report --------------------------------------------------------------------------------
All constraints were met.
Data Sheet report: ----------------- All values displayed in nanoseconds (ns)
Setup/Hold to clock CLK ------------+------------+------------+ Source |Setup to clk|Hold to clk | ------------+------------+------------+ D | 6.000| 0.500| ------------+------------+------------+
Clock CLK to Pad ---------------+------------+ Destination Pad| clk to PAD | ---------------+------------+ XLXN_234 | 18.500| ---------------+------------+
Clock to Setup on destination clock XLXN_249.Q ---------------+---------+---------+---------+---------+ | Src:Rise| Src:Fall| Src:Rise| Src:Fall| Source Clock |Dest:Rise|Dest:Rise|Dest:Fall|Dest:Fall| ---------------+---------+---------+---------+---------+ XLXI_1/read_data<0>.Q| 19.000| 19.000| 19.000| 19.000| ---------------+---------+---------+---------+---------+
Clock to Setup on destination clock CLK ---------------+---------+---------+---------+---------+ | Src:Rise| Src:Fall| Src:Rise| Src:Fall| Source Clock |Dest:Rise|Dest:Rise|Dest:Fall|Dest:Fall| ---------------+---------+---------+---------+---------+ XLXI_3/CntRX<0>.Q| 20.000| 20.000| 20.000| 20.000| ---------------+---------+---------+---------+---------+
Pad to Pad ---------------+---------------+---------+ Source Pad |Destination Pad| Delay | ---------------+---------------+---------+ ---------------+---------------+---------+ Minimum clock period is 20.000ns (50.000 MHz). Limited by Cycle Time for CLK. Maximum clock speed computed based upon tCYC assumes that all registers are rising-edge sensitive.
Timing summary: ---------------
Timing errors: 0 Score: 0
Analysis completed Fri Feb 17 16:33:03 2012
-------------------------------------------------------------------------------- но все равно при соединении не срабатывает схема (двух модулей). Я немогу понять в чем дело. Передатчик держит сигнал достаточно долго. А Control не может прочесть.
|
|
|
|
1 чел. читают эту тему (гостей: 1, скрытых пользователей: 0)
Пользователей: 0
|
|
|